+ Post New Thread
Results 1 to 12 of 12
Windows 7 Thread, Proxy vs. Home Use in Technical; Hi folks, We've recently installed a new firewall/web filter, and are pointing all staff through it using a proxy server ...
  1. #1
    Gongalong's Avatar
    Join Date
    Oct 2011
    Location
    United Kingdom
    Posts
    921
    Thank Post
    837
    Thanked 20 Times in 18 Posts
    Rep Power
    11

    Question Proxy vs. Home Use

    Hi folks,

    We've recently installed a new firewall/web filter, and are pointing all staff through it using a proxy server via group policy. The problem is for home use that no-one can access the Internet, as the PC is looking for the proxy.

    I'm hoping there's an easy answer to this. I note you can select both Automatically Detect Settings *and* the proxy server in IE. Would this work so that they would use the proxy if found, but failing that then connect directly, or is there another answer?

    I'm hoping someone has found a solution to this!

    TIA

  2. #2


    tom_newton's Avatar
    Join Date
    Sep 2006
    Location
    Leeds
    Posts
    4,485
    Thank Post
    867
    Thanked 854 Times in 675 Posts
    Rep Power
    197
    If you set "auto-detect", and use an auto-detection method (wpad, dhcp 252) in school, that should work ok.

  3. Thanks to tom_newton from:

    Gongalong (21st June 2012)

  4. #3
    Gongalong's Avatar
    Join Date
    Oct 2011
    Location
    United Kingdom
    Posts
    921
    Thank Post
    837
    Thanked 20 Times in 18 Posts
    Rep Power
    11
    Thanks Tom. I'm not familiar with wpad or setting this via DHCP. Is it easy to do? (Ironically it's a Smoothwall we've now got!)

  5. #4
    carvjo's Avatar
    Join Date
    Mar 2010
    Location
    Oxford
    Posts
    195
    Thank Post
    12
    Thanked 39 Times in 34 Posts
    Rep Power
    22
    I agree - use WPAD.DAT or PROXY.PAC - I'm sure clever people here will give step-by-step how to do that with your smoothwall and what adpatations to make to DHCP..

    or you could just put a vbs script in the startup:

    save this as proxy.vbs

    Code:
    ' proxy.vbs
    ' VBScript to set proxy
    ' ----------------------------------------------------------------------
    ' 13-08-08 hacked by JC - if the user is in the 172.16 subnet do nothing 
    ' otherwise set the proxy to blank
    ' ----------------------------------------------------------------------
    ' If the computer is in the subnet sIPSubnet then the proxy in sProxyUrl will be set
    ' otherwise it will use the default setting (which should be blanK) and proxy off
    ' 
    ' 
    ' 
    On Error Resume Next
    Dim refWMI,sIPAddress,colNetworkAdapters,oNetworkAdapter,sIPSubnet,WshShell,sProxyPort
    
    sIPSubnet = "172.16."
    sProxyURL = "http://172.16.0.246"
    sProxyPort = "8881"
    'Get IP Address and store it in sIPAddress
    Set refWMI = GetObject("WinMgmts:\\.\root\cimv2")
    Set colNetworkAdapters = refWMI.ExecQuery("Select * From Win32_NetworkAdapterConfiguration Where IPEnabled=True")
    Set WshShell = CreateObject("Wscript.Shell")
    
    For Each oNetworkAdapter in colNetworkAdapters
          If oNetworkAdapter.IPAddress(0) <> "0.0.0.0" Then
                sIPAddress = oNetworkAdapter.IPAddress(0)
                Exit For
          End If
    Next
    
    'Check to see if the IP address is in the affected subnet
    If InStr(sIPAddress,sIPSubnet) Then
          'Set autoconfig URL
         ' WshShell.RegWrite "HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ProxyServer",sProxyURL & ":" & sProxyPort,"REG_SZ"
         ' WshShell.RegWrite "HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ProxyEnable",1,"REG_DWORD"
    Else
          'Clear autoconfig url
          WshShell.RegDelete "HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ProxyServer"
          WshShell.RegWrite "HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ProxyEnable",0,"REG_DWORD"
    End If
    ' ------------------------------
    ' note - uncomment the line below to setup the default route
    ' do this if setting sIPSubnet to a random value to turn off the proxy in our domain
    ' set objShell=CreateObject("Wscript.Shell") 
    ' objShell.Run ("route add 0.0.0.0 mask 0.0.0.0  172.16.0.254")
    ' ------------------------------
    'Cleanup
    Set refWMI = Nothing
    Set colNetworkAdapters = Nothing
    Set WshShell = Nothing

  6. 3 Thanks to carvjo:

    FabIT (26th June 2012), Gongalong (21st June 2012), wagnerk (20th June 2012)

  7. #5
    wagnerk's Avatar
    Join Date
    Jun 2007
    Location
    Northants
    Posts
    817
    Thank Post
    64
    Thanked 169 Times in 137 Posts
    Rep Power
    47
    However where would you put proxy exceptions?

  8. Thanks to wagnerk from:

    Gongalong (21st June 2012)

  9. #6
    carvjo's Avatar
    Join Date
    Mar 2010
    Location
    Oxford
    Posts
    195
    Thank Post
    12
    Thanked 39 Times in 34 Posts
    Rep Power
    22
    I suppose a line a bit like this?

    Code:
    WshShell.RegWrite "HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ProxyOverride",10.0.*;moodle.xxxxxxxxx.org.uk;mail.xxxxxxxxxx.org.uk;intranet.xxxxxxxxxxx.org.uk;server-xs-*;<local>,"REG_SZ"

  10. Thanks to carvjo from:

    Gongalong (21st June 2012)

  11. #7

    AngryTechnician's Avatar
    Join Date
    Oct 2008
    Posts
    3,730
    Thank Post
    698
    Thanked 1,212 Times in 761 Posts
    Rep Power
    395
    Quote Originally Posted by Gongalong View Post
    Thanks Tom. I'm not familiar with wpad or setting this via DHCP. Is it easy to do? (Ironically it's a Smoothwall we've now got!)
    If you have a Smoothwall there are settings on the device that can help with it, without the need to write your own scripts if I'm not mistaken. Give Smoothwall support a ring and they should be able to walk you through it.

  12. 2 Thanks to AngryTechnician:

    Gongalong (21st June 2012), tom_newton (20th June 2012)

  13. #8


    tom_newton's Avatar
    Join Date
    Sep 2006
    Location
    Leeds
    Posts
    4,485
    Thank Post
    867
    Thanked 854 Times in 675 Posts
    Rep Power
    197
    Proxy exceptions can go in the pac file. Pacific file is produced automatically by smoothwall device. A dns entry for wpad.yourdomain pointing at the smoothwall should work.

  14. Thanks to tom_newton from:

    Gongalong (21st June 2012)

  15. #9

    Join Date
    Sep 2010
    Posts
    609
    Thank Post
    26
    Thanked 69 Times in 64 Posts
    Rep Power
    21
    For laptops which roam between home and school, we have a couple of shortcuts which apply some registry changes which the use can run depending on the location.
    not the most advanced method but works well enough (PAC setup would be more useful for changes to settings)

  16. Thanks to SHimmer45 from:

    Gongalong (21st June 2012)

  17. #10
    Gongalong's Avatar
    Join Date
    Oct 2011
    Location
    United Kingdom
    Posts
    921
    Thank Post
    837
    Thanked 20 Times in 18 Posts
    Rep Power
    11
    Thanks all.

    If it's set by DHCP that sounds ideal, as I can then use automatic settings. It's surprising in a way there isn't a simpler way of achieving this, as it must be a common requirement.

    I'll back this up with Smoothwall support if need be.

  18. #11
    pooley's Avatar
    Join Date
    Sep 2005
    Location
    S Wales
    Posts
    1,166
    Thank Post
    83
    Thanked 130 Times in 107 Posts
    Rep Power
    69
    Use IE in school and give them firefox for home use

  19. #12
    Gongalong's Avatar
    Join Date
    Oct 2011
    Location
    United Kingdom
    Posts
    921
    Thank Post
    837
    Thanked 20 Times in 18 Posts
    Rep Power
    11
    WPAD seems to have worked FWIW. Even if group policy doesn't...

SHARE:
+ Post New Thread

Similar Threads

  1. Replies: 3
    Last Post: 21st June 2010, 03:45 PM
  2. Settign up router for PC and MAC (Home Use)
    By tosca925 in forum Wireless Networks
    Replies: 4
    Last Post: 6th December 2008, 06:55 AM
  3. ISP for home use needed
    By _Bat_ in forum Recommended Suppliers
    Replies: 9
    Last Post: 1st August 2006, 02:45 PM
  4. K9 free parental internet blocking software for home use
    By beeswax in forum Comments and Suggestions
    Replies: 1
    Last Post: 29th June 2006, 08:03 PM
  5. Low budget laptop for home use
    By ajbritton in forum Hardware
    Replies: 5
    Last Post: 23rd February 2006, 02:51 PM

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •