I'm using NETransparentProxyProvider to intercept udp sockets using the method handleNewUDPFlow. An application may create a UDP socket and set the DONTFRAG using setsockopt method
setsockopt(s, IPPROTO_IP, IP_DONTFRAG, &val, sizeof(val))
In this case, do I have option in this case, to get the connection settings inside the callback
- (void)handleNewUDPFlow:(NEAppProxyUDPFlow *)flow initialRemoteEndpoint:(NWEndpoint *)remoteEndpoint;
So in this case, I would be able to create the outgoing socket with the exact same characteristics, after the original app socket got intercepted by my proxy provider ?
I don’t think there’s a way to do this. Transparent proxies work at the transport level, above the IP layer, and thus don’t see IP-level info.
That seems like a reasonable ‘ask’, so I encourage you to file an enhancement request that describes the problem you’re trying to solve.
Please post your bug number, just for the record.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"