Lack of UDP Support and Game Compatibility
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 25/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Active
- Domain
- mobile, networking
Research direction
Start by reading the Android VPN service and HTTP/2 tunnel implementation; the issue does not name their files or tests. Check how the current tunnel handles UDP, then determine which proposed approach fits the project. Done means UDP traffic and online games work through a documented routing or tunneling path; the issue proposes several substantial alternatives without choosing one.
Written by the indexing model from the issue text.
Description
I am using FoxyVPN (v1.0.7) and I've noticed a critical issue with online gaming. While TCP traffic (like web browsing) works perfectly, online games fail to connect. I understand this is because the current HTTP/2 tunnel architecture primarily supports TCP and is not properly routing or encapsulating UDP packets.
To fix this and make the app suitable for gaming, please consider the following technical implementations:
- Implement UDP-over-TCP/HTTP2 Encapsulation (UDP Relay)
· Issue: The current tunnel drops UDP traffic, which is essential for online games (VoIP, multiplayer sessions).
· Solution: Please implement a mechanism to encapsulate UDP packets inside TCP/HTTP2 streams. (Similar to how udp2raw or V2Ray's mKCP/TCP transport handles UDP). If the edge server (Fastly) supports it, enable UDP Associate over SOCKS5.
- Add a Robust TUN Stack (tun2socks / gVisor)
· Issue: The current VPN interface (VpnService) does not properly capture and forward UDP packets to the proxy.
· Solution: Integrate a proper userspace network stack for Android like gVisor or tun2socks (using smoltcp or lwip). This ensures that UDP packets from the OS are correctly converted to SOCKS5 UDP datagrams or encapsulated into the HTTP/2 tunnel.
- Add "Routing Rules" (Bypass UDP or Specific IPs)
· Issue: When a game sends UDP packets, the app either drops them or sends them through a tunnel that doesn't support them, causing the game to hang or timeout.
· Solution: Add a routing engine (like the one in v2rayNG or NekoBox). Add an option to route all UDP traffic to direct (bypassing the VPN) by default, or allow users to add specific game server IP ranges to the direct routing table while TCP remains proxied.
- Fix MTU and Fragmentation Issues
· Issue: HTTP/2 tunneling adds overhead (headers, framing) to packets. The default MTU of 1480 might be too high for UDP, leading to packet fragmentation and dropping by the edge network (Fastly).
· Solution: Allow dynamic MTU adjustments or implement internal fragmentation for UDP packets before they enter the HTTP/2 tunnel.
- Granular Split Tunneling (Protocol-based)
· Issue: The current "Excluded apps" (Split Tunneling) completely removes the app from the VPN.
· Solution: Enhance split tunneling to allow protocol-based routing. For example, allow TCP traffic of a specific app to go through the VPN, but route its UDP traffic directly.
- Consider Core Replacement (sing-box / Xray-core)
· Suggestion: Instead of maintaining a custom HTTP/2 client, consider wrapping the app around sing-box or Xray-core. These cores have native, highly optimized support for UDP (via Full-Cone NAT), TUN mode, and complex routing rules out of the box.
Thank you for your hard work on this open-source project. I look forward to seeing these networking features implemented.
- Dominant language
- Kotlin
- Stars
- 242
- Forks
- 51
- Avg merge
- 21m
- Merged PRs (30d)
- 3
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from Vauth/FoxyVPN
-
Difficulty 1/5 Under an hour Newbie friendliness 72/100
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 30/100
-
VPN DisconnectsOpen
Difficulty 4/5 3-5 days Newbie friendliness 45/100
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 35/100
-
Difficulty 4/5 3-5 days Newbie friendliness 48/100
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
lugassawan/swe-workbench#823 ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 80/100
Droid-Deck/DroidDeck#1355 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
IronCoreLabs/ironcore-alloy#351 ·
-
Lovelace refine Taak
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
MinBZK/MijnOverheidZakelijk#1383 ·