Windows 10 does not read a PAC file referenced by a file protocol
This article provides the resolution to solve the issue that a PAC file referenced by a file protocol cannot be read by Internet Explorer or Microsoft Edge.
Original product version: Windows 10, Microsoft Edge, Internet Explorer 11
Original KB number: 4025058
Consider the following scenario:
You configured Microsoft Internet Explorer 11 or Microsoft Edge on Windows 10 to use the Use Automatic Configuration script option.
You are testing or deploying a proxy auto-configuration (PAC) file. You are storing the file in a local location, such as C:\temp\proxy.pac.
You specified the file location in the Use Automatic Configuration script option in Internet Setting by using the file protocol.
You created the following registry subkey:
HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\CurrentVersion\Internet Settings\ Value: EnableLegacyAutoProxyFeature Type:REG_DWORD Data:1
In this scenario, the PAC file is not read by Internet Explorer or Microsoft Edge.
This issue occurs because Internet Explorer and Microsoft Edge on Windows 10-based computers use the WinHttp proxy service to retrieve proxy server information. The WinHttp Proxy service does not support using the
file:// protocol for a PAC file.
To resolve this issue, host the PAC file on a web server, then refer to it by using the http protocol.
The application/x-ns-proxy-autoconfig MIME type has to be specified for the PAC file on the web server in order for the WinHttp proxy service to consume the PAC file.
If not, the extension of the PAC file has to be .dat, .js, .pac, or .jvs.