My NEPacketTunnelProvider uses NSURLSession for certain communication with my server. It seems to ignore the /etc/hosts file, though.
I created a hosts entry for "vpn.example.com". This entry works great with Safari and with NSURLSession in my app, which are both able to access the server. But NSURLSession in my tunnel provider just times out. I can access the same server by its real hostname (not the /etc/hosts entry) or IP from the tunnel provider without issue.
Is this known/expected behavior?
Thanks
Mike
Edit: This behavior is on macOS 10.12.6.