Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    WPAD problem with lighttpd url.redirect

    Scheduled Pinned Locked Moved 2.1 Snapshot Feedback and Problems - RETIRED
    4 Posts 3 Posters 2.3k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • R
      redgolem
      last edited by

      I had problems with my wpad.dat file on my pfsense. There was always an redirect so it was ignored by the browser.
      So I changed in system.inc following code to make an exception for wpad subdomains.
      From:

      
      \$SERVER["socket"] == ":80" {
      	\$HTTP["host"] =~ "(.*)" {
      		url.redirect = ( "^/(.*)" => "https://%1{$redirectport}/$1" )
      	}
      }
      
      

      to

      
      \$SERVER["socket"] == ":80" {
      	\$HTTP["host"] !~ "^wpad\.(.*)$" {
      		\$HTTP["host"] !~ "wpad$" {
      			\$HTTP["host"] =~ "(.*)" {
      				url.redirect = ( "^/(.*)" => "https://%1{$redirectport}/$1" )
      			}
      		}
      	}
      }
      
      

      Is there another way to do this without changing system files?

      1 Reply Last reply Reply Quote 0
      • E
        eri--
        last edited by

        Just put your GUI on port 80?
        That redirect is just to have transparent ssl support for many people it was not meant to have special cases for WPAD.

        1 Reply Last reply Reply Quote 0
        • S
          sentkr
          last edited by

          Hi

          I tried suggestion from redgolem, it works fine for Firefox, but does not work for IE, I looked at the wireshark content , pfsense returns a http error 301
          . it is still looking for wpad in https location.

          I don't want to enable http access for webconfigurator for security reasons,

          I am running 2.1 version of pfsense

          1 Reply Last reply Reply Quote 0
          • R
            redgolem
            last edited by

            Which url is reqested from your Internet Explorer?
            It should be http://wpad/wpad.dat or http://wpad.some.domain/wpad.dat .

            1 Reply Last reply Reply Quote 0
            • First post
              Last post
            Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.