Where did you install Firefox from? Help Mozilla uncover 3rd party websites that offer problematic Firefox installation by taking part in our campaign. There will be swag, and you'll be featured in our blog if you manage to report at least 10 valid reports!

搜索 | 用户支持

防范以用户支持为名的诈骗。我们绝对不会要求您拨打电话或发送短信,及提供任何个人信息。请使用“举报滥用”选项报告涉及违规的行为。

Learn More

Difference between PAC reutrn "DIRECT" and Firefox' "no proxy for"?

  • 1 个回答
  • 1 人有此问题
  • 20 次查看
  • 最后回复者为 guigs

more options

I'm trying to run a local IPython Notebook [1] in Firefox with a proxy-auto-config (PAC). It opens under http://localhost:8888/ I get an error message just as stated in [2] about a websocket connection failing (also when changing to http://127.0.0.1:8888/). Changing the advanced network properties to manual proxy settings with "no proxy for localhost, 127.0.0.1", the error disappears. I think that means Firefox tries to use a proxy for localhost when the PAC file is the active setting. I looked into the file and found

function FindProxyForURL(url, host)

{

if (shExpMatch(url, "http*://localhost/*")) return "DIRECT";

if (shExpMatch(url, "http*://localhost:*/*")) return "DIRECT";

if (shExpMatch(url, "http*://127.*.*.*/*")) return "DIRECT";

}

So, if I understand this correctly, Firefox shouldn't be using a proxy for localhost, but I get a different behavior than if I use the manual setting ignoring localhost and 127.0.0.1 -- why is that? There is no other mention of localhost in the PAC file. The user of stackoverflow in [2] has noticed the same problem.

I also tried in safe mode, no difference.

[1] http://ipython.org/notebook.html

[2] http://stackoverflow.com/questions/19245200/ipython-notebook-websocket-connection-failed

Using Firefox ESR 31.5.3 with Windows 7

I'm trying to run a local IPython Notebook [1] in Firefox with a proxy-auto-config (PAC). It opens under http://localhost:8888/ I get an error message just as stated in [2] about a websocket connection failing (also when changing to http://127.0.0.1:8888/). Changing the advanced network properties to manual proxy settings with "no proxy for localhost, 127.0.0.1", the error disappears. I think that means Firefox tries to use a proxy for localhost when the PAC file is the active setting. I looked into the file and found function FindProxyForURL(url, host) { if (shExpMatch(url, "http*://localhost/*")) return "DIRECT"; if (shExpMatch(url, "http*://localhost:*/*")) return "DIRECT"; if (shExpMatch(url, "http*://127.*.*.*/*")) return "DIRECT"; } So, if I understand this correctly, Firefox shouldn't be using a proxy for localhost, but I get a different behavior than if I use the manual setting ignoring localhost and 127.0.0.1 -- why is that? There is no other mention of localhost in the PAC file. The user of stackoverflow in [2] has noticed the same problem. I also tried in safe mode, no difference. [1] http://ipython.org/notebook.html [2] http://stackoverflow.com/questions/19245200/ipython-notebook-websocket-connection-failed Using Firefox ESR 31.5.3 with Windows 7

由crunth于修改

所有回复 (1)

more options

Hi crunth , It might be helpful to direct this to the right audience: If you can reproduce it, please file a bug in bugzilla.mozilla.org under ESR and talk to the mailing list listed:

*https://www.mozilla.org/en-US/firefox.../releasenotes/