Any volunteer Windows devs to change OpenVPN proxying code to use "new" InternetQueryOption API?
Hi all,
A while back a user noticed that OpenVPN still uses old IE4 API to detect proxy settings (e.g. in proxy.c and ieproxy.c). This apparently causes problems with IE's proxy detection on some Windows installations. A "new" InternetQueryOption API was introduced in IE5, so this part of OpenVPN would benefit from an upgrade anyways. Would somebody be interested in taking up this task? We seem to have a shortage of Windows devs, so any help would be most welcome!
For more information about this issue can be found from here:
* http://thread.gmane.org/gmane.network.openvpn.devel/3446
* http://support.microsoft.com/kb/226473
If I've misunderstood the problem, please send clarifications - proxy usage in OpenVPN is still pretty vague to me :)
Signature · 5 lines
Samuli Seppänen Community Manager OpenVPN Technologies, Inc irc freenode net: mattock
Hi Samuli,
Very interesting timing! Just last night I was poking about about this a bit, and I'm not so sure that the proxy approach noted so far is the best / right way to do this. Rather, to be able to handle dynamic (not just static) proxy configurations the WinHTTP API looks to me to be the way to do this (see http://msdn.microsoft.com/en-us/library/aa384097(v=VS.85).aspx for an example).
I hope this helps!
... Russell
Quoted 1 line · Samuli Seppänen
Hi all,
Quoted 31 lines
A while back a user noticed that OpenVPN still uses old IE4 API to detect proxy settings (e.g. in
proxy.candieproxy.c). This apparently causes problems with IE's proxy detection on some Windows installations. A "new" InternetQueryOption API was introduced in IE5, so this part of OpenVPN would benefit from an upgrade anyways. Would somebody be interested in taking up this task? We seem to have a shortage of Windows devs, so any help would be most welcome!For more information about this issue can be found from here:
* http://thread.gmane.org/gmane.network.openvpn.devel/3446
* http://support.microsoft.com/kb/226473If I've misunderstood the problem, please send clarifications - proxy usage in OpenVPN is still pretty vague to me :)
--
Samuli Seppänen
Community Manager
OpenVPN Technologies, Incirc freenode net: mattock
------------------------------------------------------------------------------
_______________________________________________
Openvpn-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openvpn-devel
The IE API is user specific.
As OpenVPN runs as a service using own user or system account, IE API is not suitable.
Using WinHTTP indeed looks better.
2010/4/28 <[email protected]...>:
Quoted 65 lines
Hi Samuli,
Very interesting timing! Just last night I was poking about about this a bit, and I'm not so sure that the proxy approach noted so far is the best / right way to do this. Rather, to be able to handle dynamic (not just static) proxy configurations the WinHTTP API looks to me to be the way to do this (see http://msdn.microsoft.com/en-us/library/aa384097(v=VS.85).aspx for an example).
I hope this helps!
... Russell
On Wed, Apr 28, 2010 09:01 AM, Samuli Seppänen <[email protected]...> wrote:
Hi all,
A while back a user noticed that OpenVPN still uses old IE4 API to detect proxy settings (e.g. in
proxy.candieproxy.c). This apparently causes problems with IE's proxy detection on some Windows installations. A "new" InternetQueryOption API was introduced in IE5, so this part of OpenVPN would benefit from an upgrade anyways. Would somebody be interested in taking up this task? We seem to have a shortage of Windows devs, so any help would be most welcome!For more information about this issue can be found from here:
* http://thread.gmane.org/gmane.network.openvpn.devel/3446
* http://support.microsoft.com/kb/226473If I've misunderstood the problem, please send clarifications - proxy usage in OpenVPN is still pretty vague to me :)
--
Samuli Seppänen
Community Manager
OpenVPN Technologies, Incirc freenode net: mattock
------------------------------------------------------------------------------
_______________________________________________
Openvpn-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openvpn-devel------------------------------------------------------------------------------
_______________________________________________
Openvpn-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openvpn-devel
Quoted 3 lines · On Wednesday 28 April 2010 16:24:31 Alon Bar-Lev wrote:
The IE API is user specific.
As OpenVPN runs as a service using own user or system account, IE API is not suitable.
Sadly I haven't found the WinHttpGetProxyForUrl API in MinGW W32API. So, use of this might rather be a long-term goal as it takes a while to get it included.
If the service is started by the GUI it still makes sense to use user specific proxy settings, doesn't it? One could consider auto-proxy for auto-started VPNs a misconfiguration, as well. Or am I mislead?
Heiko
Signature · 7 lines
Heiko Hund | Software Engineer | Phone +49-721-25516-237 | Fax -200 Astaro AG | An der RaumFabrik 33a | 76227 Karlsruhe | Germany Executive Board: Markus Hennig, Jan Hichert, Günter Junk, Dr. Frank Nellissen Chairman of the Supervisory Board: Stanley J. Krasnow Headquarter Location: Karlsruhe Commercial Register: Mannheim HRB 108997
Quoted 8 lines · Heiko Hund
Quoted 3 lines · On Wednesday 28 April 2010 16:24:31 Alon Bar-Lev wrote:
The IE API is user specific.
As OpenVPN runs as a service using own user or system account, IE API is not suitable.Sadly I haven't found the WinHttpGetProxyForUrl API in MinGW W32API. So, use of this might rather be a long-term goal as it takes a while to get it included.
No problem to add simple prototypes and perform GetProcAddress().
Quoted 3 lines
If the service is started by the GUI it still makes sense to use user specific proxy settings, doesn't it? One could consider auto-proxy for auto-started VPNs a misconfiguration, as well. Or am I mislead?
If this is a service that is started, it cannot access your proxy without more tweaks.
If the GUI runs the OpenVPN.exe in the user context (user with administrative permission) it is fine.
Alon.
Quoted 4 lines · Heiko Hund
If the service is started by the GUI it still makes sense to use user specific proxy settings, doesn't it? One could consider auto-proxy for auto-started VPNs a misconfiguration, as well. Or am I mislead?
I think it's critical. Most enterprise networks have egress filtering (ie default to blocking outbound with business-exceptions) and web access via proxies. They will use WPAD (via HTTP or DHCP) or perhaps they are a Windows shop and use Active Directory policies to "tell" MSIE how to operate on a particular network. Don't forget enterprise networks tend to span continents and so static entries are not appropriate - different proxies for different sites within the same company are common.
Anyway, all this means it's too hard for users to remember what-to-use-where and so things like WPAD were born. They also fail open, so when you take your laptop home, it does a WPAD lookup, doesn't get an answer and so assumes it's open Internet. i.e. automatic proxy detection is all good and no bad (I'm ignoring the fundamental issue that plugging into random networks and using the proxy "the network" told you to use is safe - but https and openvpn over untrusted networks should still be safe)
If openvpn had good automagic proxy detection, and a single config could contain a mixture of udp and tcp and tcp-over-proxy [connection] profiles, then openvpn would work on every network in the world - with only some high-security exceptions. I think that's a goal worth reaching for :-)
BTW, from what I've read, Microsoft's DirectAccess does exactly this (ipv6Direct-else-udpToredo-else-ipv6overTCP-else-ipv6overTCPoverProxy)...
Jason
Signature · 6 lines
Cheers Jason Haar Information Security Manager, Trimble Navigation Ltd. Phone: +64 3 9635 377 Fax: +64 3 9635 417 PGP Fingerprint: 7A2E 0407 C9A6 CAF6 2B9F 8422 C063 5EBB FE1D 66D1
Quoted 11 lines · On Wednesday 28 April 2010 16:45:47 Alon Bar-Lev wrote:
Quoted 8 lines · Heiko Hund
Quoted 3 lines · On Wednesday 28 April 2010 16:24:31 Alon Bar-Lev wrote:
The IE API is user specific.
As OpenVPN runs as a service using own user or system account, IE API is not suitable.Sadly I haven't found the WinHttpGetProxyForUrl API in MinGW W32API. So, use of this might rather be a long-term goal as it takes a while to get it included.
No problem to add simple prototypes and perform
GetProcAddress().
Not pretty, but yes.
Quoted 6 lines
Quoted 3 lines
If the service is started by the GUI it still makes sense to use user specific proxy settings, doesn't it? One could consider auto-proxy for auto-started VPNs a misconfiguration, as well. Or am I mislead?
If this is a service that is started, it cannot access your proxy without more tweaks.
Currently not that's true, but the service interface needs to be extended to pass data between the GUI and openvpn in the future anyways.
Heiko
Signature · 12 lines
Heiko Hund | Software Engineer | Phone +49-721-25516-237 | Fax -200 Astaro GmbH & Co. KG | An der RaumFabrik 33a | 76227 Karlsruhe | Germany Astaro GmbH & Co. KG 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
Quoted 5 lines · On Thursday 29 April 2010 03:44:37 Jason Haar wrote:
Quoted 3 lines · Heiko Hund
If the service is started by the GUI it still makes sense to use user specific proxy settings, doesn't it? One could consider auto-proxy for auto-started VPNs a misconfiguration, as well. Or am I mislead?
Quoted 7 lines
I think it's critical. Most enterprise networks have egress filtering (ie default to blocking outbound with business-exceptions) and web access via proxies. They will use WPAD (via HTTP or DHCP) or perhaps they are a Windows shop and use Active Directory policies to "tell" MSIE how to operate on a particular network. Don't forget enterprise networks tend to span continents and so static entries are not appropriate - different proxies for different sites within the same company are common.
I agree. Had assumed that WinHttpGetIEProxyConfigForCurrentUser and InternetQueryOption are returning the proxy from WPAD if IE is set to automatic mode. Do you know if they do?
Heiko
Signature · 12 lines
Heiko Hund | Software Engineer | Phone +49-721-25516-237 | Fax -200 Astaro GmbH & Co. KG | An der RaumFabrik 33a | 76227 Karlsruhe | Germany Astaro GmbH & Co. KG 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
Quoted 9 lines · Heiko Hund
Quoted 6 lines
Quoted 3 lines
If the service is started by the GUI it still makes sense to use user specific proxy settings, doesn't it? One could consider auto-proxy for auto-started VPNs a misconfiguration, as well. Or am I mislead?
If this is a service that is started, it cannot access your proxy without more tweaks.
Currently not that's true, but the service interface needs to be extended to pass data between the GUI and openvpn in the future anyways.
True.
The proxy should be provided via the management interface.
The OpenVPN GUI should be rewritten in order to use the management interface and only the management interface.
This will solve a lot of issues especially in Windows environment. In Linux it is not that important, as OpenVPN can run in none privileged mode.