Page 1 of 1

OpenVPN SOCKS5 username and password authentication

Posted: Sat Jul 14, 2018 7:08 am
by g4lvanix
Hello!

I am trying to set up OpenVPN in conjunction with obfs4proxy to obfuscate the traffic between the OpenVPN clients and the server.

obfs4proxy exposes a SOCKS5 proxy and requires username and password authentication, i.e. the OpenVPN client connects through the obfs4proxy SOCKS proxy to the OpenVPN server.
In order to do this I need to use a single ASCII NUL character as the password.

I have already tried to use the URL escaped NUL character %00 on the second line of the auth file --> did not work

Code: Select all

$ hexdump -C socks_auth
00000000  75 73 65 72 6e 61 6d 65  0a 25 30 30 0a           |username.%00.|
0000000d
After that I tried manually appending a 0 byte to the text file instead --> again this did not work

Code: Select all

$ hexdump -C socks_auth
00000000  75 73 65 72 6e 61 6d 65  0a 00                    |username..|
0000000a
Is there a way to tell OpenVPN to use a single NUL character as the password to authenticate to a SOCKS5 proxy?

Thank you!

Re: OpenVPN SOCKS5 username and password authentication

Posted: Sun Jul 15, 2018 7:10 am
by g4lvanix
For future reference:

I have found that using a simple ASCII 0 character works just as well, i.e. a file like this

Code: Select all

username
0