Monday 1 November 2010

Enabling/disabling IE's proxy via the registry

The registry entry which needs to be modified when you want to enable or disable the proxy for IE is
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Connections\DefaultConnectionSettings

Byte 9 has to be modified such that if you wanted to enable it, bit 2 has to be set. Alternatively, if you wanted the proxy to be disabled, bit 2 has to be cleared.

Example 1
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Connections]
"DefaultConnectionSettings"=hex:46,00,00,00,a8,1e,00,00,03,00,00,00,6e,....

In the example above, bit 2 of byte 9 is set. This means that the proxy is enabled.

Example 2
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Connections]
"DefaultConnectionSettings"=hex:46,00,00,00,a8,1e,00,00,01,00,00,00,6e,....

In the example above, bit 2 of byte 9 is cleared. This means that the proxy is disabled.