OpenVPN GUI and ntlm Proxy password
Hello Mathias,
I would like to use you OpenVPN GUI for Windows to authenticate over an NTLM proxy in Windows and wonder if you're thinking about asking and supplying the password for NTLM-proxy authentication or planing on doing so.
The very recent versions of (2.2.x) of OpenVPN support not only basic authentcation but in addition NTLM authentication which is necessary to connect via an ISA proxy, when creating a config file for Windows GUI it was possible to specify the proxy password but it tried to authentication using basic authentication which was disabled in the ISA proxy for security reasons.
Example config:
client
dev tun
proto tcp
nobind
remote edge1.glanzmann.de 443
resolv-retry infinite
persist-key
persist-tun
ca edge1ca.crt
ns-cert-type server
comp-lzo
verb 3
mute 20
auth-user-pass
tun-mtu 1400
http-proxy 192.168.1.211 8080 credentials.txt ntlm
In the last line you see the changes. There is an ntlm at the end and a file (I think you already have that with username and password in it).
From the OpenVPN Man page:
-http-proxy server port [authfile|'auto'|'auto-nct'] [auth-method] Connect to remote host through an HTTP proxy at address server and port port. If HTTP Proxy-Authenticate is required, authfile is a file containing a username and password on 2 lines, or "stdin" to prompt from console.
auth-method should be one of "none", "basic", or "ntlm".
HTTP Digest authentication is supported as well, but only via the auto or auto-nct flags (below).
The auto flag causes OpenVPN to automatically determine the auth-method and query stdin or the management interface for username/password credentials, if required. This flag exists on OpenVPN 2.1 or higher.
The auto-nct flag (no clear-text auth) instructs OpenVPN to automatically determine the authentication method, but to reject weak authentication protocols such as HTTP Basic Authentication.
Source: http://www.openvpn.net/index.php/open-source/documentation/manuals/427-openvpn-22.html
Maybe you could add a checkbox which lets a user choose between none, basic, ntlm, auto, or auto-nct authentication.
Cheers,
Thomas
Hi Thomas,
Quoted 1 line · On Thursday 17 March 2011 06:41:55 Thomas Glanzmann wrote:
Hello Mathias,
I fear Mathias is not involved with the OpenVPN GUI since five years or so. There's a project on SourceForge now where I forked the GUI and try to improve
it: https://sourceforge.net/projects/openvpn-gui/
Quoted 4 lines
I would like to use you OpenVPN GUI for Windows to authenticate over an NTLM proxy in Windows and wonder if you're thinking about asking and supplying the password for NTLM-proxy authentication or planing on doing so.
Maybe you want to check out the latest snapshot and see if it works for you. The GUI uses the OpenVPN management interface for communication and monitoring since a while now. So, there's a fair chance it'll work right away or won't be much work to make it work. =)
Regards
Heiko
Signature · 8 lines
Heiko Hund | Software Engineer | Phone +49-721-25516-237 | Fax -200 Astaro GmbH & Co. KG | An der RaumFabrik 33a | 76227 Karlsruhe | Germany Commercial Register: Mannheim HRA 702710 | Headquarter Location: Karlsruhe Represented by the General Partner Astaro Verwaltungs GmbH An der RaumFabrik 33a | 76227 Karlsruhe | Germany Commercial Register: Mannheim HRB 708248 | Executive Board: Gert Hansen, Markus Hennig, Jan Hichert, Günter Junk, Dr. Frank Nellissen
Hello Heiko,
Quoted 3 lines
I fear Mathias is not involved with the OpenVPN GUI since five years or so. There's a project on SourceForge now where I forked the GUI and try to improve
it: https://sourceforge.net/projects/openvpn-gui/
I see. Thanks for putting in the effort.
Quoted 4 lines
Maybe you want to check out the latest snapshot and see if it works for you. The GUI uses the OpenVPN management interface for communication and monitoring since a while now. So, there's a fair chance it'll work right away or won't be much work to make it work. =)
It did not work, because it couldn't read or write the file
Fri Mar 18 13:56:53 2011 Error opening 'HTTP Proxy' auth file: C:\DOCUME~1\adglth0\LOCALS~1\Temp\openvpn_authfile.: Das System kann die angegebene Datei nicht finden. (errno=2)
containing the credentials. But the directory exists.
I also saw a few other things that are confusing:
- The 'About' button mentions GUI version 1.3
- When using 'Intenet Explorer' to determine the proxy, it doesn't work with proxy pac but doesn't mention it (the OpenVPN Gui 1.3 did mention that it doesn't work with proxy pacs).
Any ideas to track the problem down. My configuration file is:
client
dev tun
proto tcp
nobind
remote full.qualified.hostname.de 443
resolv-retry infinite
persist-key
persist-tun
ca edge1ca.crt
ns-cert-type server
comp-lzo
verb 3
mute 20
auth-user-pass
tun-mtu 1400
# http-proxy 192.168.1.211 8080 paaf.txt ntlm
Cheers,
Thomas
Hi Thomas,
Quoted 5 lines · On Friday 18 March 2011 14:02:26 Thomas Glanzmann wrote:
Quoted 4 lines
Maybe you want to check out the latest snapshot and see if it works for you. The GUI uses the OpenVPN management interface for communication and monitoring since a while now. So, there's a fair chance it'll work right away or won't be much work to make it work. =)
Quoted 7 lines
It did not work, because it couldn't read or write the file
Fri Mar 18 13:56:53 2011 Error opening 'HTTP Proxy' auth file:
C:\DOCUME~1\adglth0\LOCALS~1\Temp\openvpn_authfile.: Das System kann die
angegebene Datei nicht finden. (errno=2)containing the credentials. But the directory exists.
That's a openvpn error message not one of the GUI. Did you see the dot (.) at the end of the filename? How does openvpn know about it? I don't see it mentioned in your configuration.
Quoted 3 lines
I also saw a few other things that are confusing:
- The 'About' button mentions GUI version 1.3
Yes, it's just a snapshot of the current standing in the repository not a new released version. There'll be some time passing until it gets a new version.
Quoted 4 lines
- When using 'Intenet Explorer' to determine the proxy, it doesn't work with proxy pac but doesn't mention it (the OpenVPN Gui 1.3 did mention that it doesn't work with proxy pacs).
How or where did it mention this? I can't recall removing anything like it.
Regards
Heiko
Signature · 8 lines
Heiko Hund | Software Engineer | Phone +49-721-25516-237 | Fax -200 Astaro GmbH & Co. KG | An der RaumFabrik 33a | 76227 Karlsruhe | Germany Commercial Register: Mannheim HRA 702710 | Headquarter Location: Karlsruhe Represented by the General Partner Astaro Verwaltungs GmbH An der RaumFabrik 33a | 76227 Karlsruhe | Germany Commercial Register: Mannheim HRB 708248 | Executive Board: Gert Hansen, Markus Hennig, Jan Hichert, Günter Junk, Dr. Frank Nellissen
Hello Heiko,
Quoted 7 lines
Quoted 3 lines
Fri Mar 18 13:56:53 2011 Error opening 'HTTP Proxy' auth file:
C:\DOCUME~1\adglth0\LOCALS~1\Temp\openvpn_authfile.: Das System kann die
angegebene Datei nicht finden. (errno=2)That's a openvpn error message not one of the GUI. Did you see the dot (.) at the end of the filename? How does openvpn know about it? I don't see it mentioned in your configuration.
I used the configuration I sent, but configured in your version of the GUI the following:
Right Click => Settings => Proxy
[x] Manual Configuration
[x] HTTP Proxy
Address: proxy.corp.com Port: 8080
[x] Prompt for username/password when connection.
I thought that the GUI now adds a line to the openvpn command line when starting the config and writing out the above file, but it doesn't seem to do that. Am I mistaken?
See proxy configuration: http://thomas.glanzmann.de/tmp/guifork.png
When I try to connect I'm first asked by the gui for proxy login and password and than for username and password for OpenVPN. After that I get the message that it can't find the authentication files that I thought the GUI would create containing login and password.
Quoted 6 lines
Quoted 4 lines
- When using 'Intenet Explorer' to determine the proxy, it doesn't work with proxy pac but doesn't mention it (the OpenVPN Gui 1.3 did mention that it doesn't work with proxy pacs).
How or where did it mention this? I can't recall removing anything like it.
When I install openvpn 2.2 RC from the openvpn community website[1] it says 'Use Internet Explorer Settings (manually configured)'. Your version says 'Use Internet Explorer Settings'.
Gui that ships with 2.2 RC: http://thomas.glanzmann.de/tmp/legacy.png
Your Gui fork: http://thomas.glanzmann.de/tmp/guifork.png
[1] http://swupdate.openvpn.net/community/releases/openvpn-2.2-RC-install.exe
Cheers,
Thomas
Hi Thomas.
Quoted 11 lines · On Friday 18 March 2011 15:43:25 Thomas Glanzmann wrote:
Quoted 7 lines
Quoted 3 lines
Fri Mar 18 13:56:53 2011 Error opening 'HTTP Proxy' auth file:
C:\DOCUME~1\adglth0\LOCALS~1\Temp\openvpn_authfile.: Das System kann
die angegebene Datei nicht finden. (errno=2)That's a openvpn error message not one of the GUI. Did you see the dot (.) at the end of the filename? How does openvpn know about it? I don't see it mentioned in your configuration.
I thought that the GUI now adds a line to the openvpn command line when starting the config and writing out the above file, but it doesn't seem to do that. Am I mistaken?
I checked and you are right. I blindly believed the proxy credentials are also queried from the user via the management interface but that's not the case currently. Haven't look too much at the proxy code obviously. =) The GUI could use the auto flag with the --http-proxy option in the future, I'll give it a try next week.
The incomplete filename is caused by a too small buffer in the GUI. You must be using a hostname for the proxy and it's somewhere close to 30 characters long, right? I'll add a bug to the tracker for this then. In the meantime, could you please try if it works for you using the proxy IP address.
Quoted 6 lines
Quoted 2 lines
How or where did it mention this? I can't recall removing anything like it.
When I install openvpn 2.2 RC from the openvpn community website[1] it says 'Use Internet Explorer Settings (manually configured)'. Your version says 'Use Internet Explorer Settings'.
Yes, I remember removing this. Thought it had no additional information. Maybe a better solution would be to query the system for the right proxy. Pointers anyone?
Heiko
Signature · 8 lines
Heiko Hund | Software Engineer | Phone +49-721-25516-237 | Fax -200 Astaro GmbH & Co. KG | An der RaumFabrik 33a | 76227 Karlsruhe | Germany Commercial Register: Mannheim HRA 702710 | Headquarter Location: Karlsruhe Represented by the General Partner Astaro Verwaltungs GmbH An der RaumFabrik 33a | 76227 Karlsruhe | Germany Commercial Register: Mannheim HRB 708248 | Executive Board: Gert Hansen, Markus Hennig, Jan Hichert, Günter Junk, Dr. Frank Nellissen
Hello Heiko,
Quoted 5 lines
The incomplete filename is caused by a too small buffer in the GUI. You must be using a hostname for the proxy and it's somewhere close to 30 characters long, right? I'll add a bug to the tracker for this then. In the meantime, could you please try if it works for you using the proxy IP address.
that's correct. The hostname has 29 chars.
Cheers,
Thomas