OpenVPN / OpenVPN/openvpn

Another likely OpenVPN(UDP)+SOCKS5 bug, likely unrelated to previous (connection "stalls/stutters" occasionally, with very inconclusive logs)

Open
#381 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
14.6k
Forks
3.4k
PR merge metrics
No merged PRs in 30d

Description

Describe the bug
A clear and concise description of what the bug is.

So, suppose you have OpenVPN(UDP) and a localhost SOCKS5 proxy (I've only have witnessed this behavior on localhost SOCKS5 but because it's hard to reproduce it might be that simply I was not patient enough with remote one)

OpenVPN(UDP)=SOCKS5(localhost)=[Remote another machine]=[Remote OpenVPN Server]
OR
OpenVPN(UDP)=SOCKS5(localhost)=[another machine on same LAN]=[OpenVPN Server on same LAN]

Connection can run for a long time, and then suddenly staggers, but not long enough for it to timeout (think 4-15 seconds)

Nothing happens in the logs of both SOCKS and OpenVPN client at this point

Then suddenly connection resumes but the log of OpenVPN spews a bunch of errors about possible replay.

Happens when SOCKS5 is a shadowsocks sslocal + some sserver AND happens when SOCKS5 is a vanilla SOCKS5 (HEV used for this test)

To Reproduce
See above

Expected behavior
For connection to run without hiccups

Version information (please complete the following information):

  • OS: Debian 11 (VM)

  • OpenVPN version:
    OpenVPN 2.6.5 x86_64-pc-linux-gnu [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [PKCS11] [MH/PKTINFO] [AEAD] [DCO]
    library versions: OpenSSL 3.1.1 30 May 2023, LZO 2.10

Due to the fact that the bug takes a long while to reproduce and doesn't cause conclusive log evidence I've only tested it on one configuration (but with two different completely unrelated SOCKS5 server options)

Additional context
Add any other context about the problem here.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the OpenVPN(UDP)=SOCKS5 topologies described on Debian 11, using both the shadowsocks sslocal setup and HEV SOCKS5 server. Compare OpenVPN and SOCKS5 behavior during the 4–15 second stall, especially the subsequent possible-replay errors. Done means identifying a reproducible cause and a verified fix or a conclusive diagnosis.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
networking
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.