Hello, I'm trying to send a copy of an intercepted packet through the network stack again using sockets. I'm currently trying to do this using a raw socket with Swift code calling a C function that does the following:
socket(AF_INET, SOCK_RAW, IPPROTO_RAW)
This results in an error:
Operation not permitted
I understand that raw sockets require root privileges. I'm calling this code from my network extension already. Is there anything else I have to do to get a raw socket working?
Is there a better way I should resend a packet that I've intercepted in my packet filter?
11
0
5.9k