I am given a task to eliminate the
<app> uses obsolete (PF_INET,SOCK_PACKET)
warning from a userspace client. If this type of use is obsolete; what is the correct, similar replacement for this task?
Edit: There was misleading information here.
I am given a task to eliminate the
<app> uses obsolete (PF_INET,SOCK_PACKET)
warning from a userspace client. If this type of use is obsolete; what is the correct, similar replacement for this task?
Edit: There was misleading information here.
Check man 7 packet
and man 7 ip
for more information, but it looks like what you need is
socket(PF_PACKET, SOCK_RAW, <protocol>)
"For compatibility with Linux 2.0, the obsolete socket(PF_INET,
SOCK_RAW, protocol) syntax is still supported to open a
packet(7) socket. This is deprecated and should be replaced by
socket(PF_PACKET, SOCK_RAW, protocol) instead. The main
difference is the new sockaddr_ll address structure for generic
link layer information instead of sockaddr_pkt." - ip(7)
Although I don't know what additional changes might be required.
The problem is a library function calling socket(AF_INET, SOCK_PACKET, htons(0x0806)), and not the application itself.