Android NAT-T keepalive offload bypasses VPN lockdown
https://mullvad.net/en/blog/another-way-to-leak-traffic-on-a... Comments URL: https://news.ycombinator.com/item?id=49665502 Points: 176 # Comments: 44
Android's Always-on VPN and "Block connections without VPN" settings create the expectation that covered applications' traffic will remain within the VPN path. However, Android's NAT-T socket-keepalive API can bypass this boundary, allowing clear UDP/4500 packets to reach the physical router outside the VPN path. This issue has been observed on Pixel 8 Pro, Samsung SM-F966B, and Nothing A059 devices running Android 16.
The problem stems from the Android framework's handling of the public Android-managed IpSecManager.UdpEncapsulationSocket, which allows applications to declare themselves as the VPN and circumvents the VPN lockdown policy. The Android framework routes the request through startNattKeepaliveWithFd(), and packets are emitted without enforcing the caller UID's effective VPN-lockdown policy.
This results in repeated packets that disclose the physical network's source address and timing to destinations outside the VPN tunnel, violating the lockdown's identity-confinement property. The issue affects most Android 12+ devices, with 8.76% of devices remaining unresolved.
Written by urgent.news from Hacker News Best's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.