Comments (11)
- Which version of FoxyProxy Basic are you using?
- How are you accessing the localhost services?
Firefox should bypass proxy for localhost. 🤔
Firefox ☰ ➜ Settings ➜ General ➜ Network Settings ➜ Settings
Connections to localhost, 127.0.0.1/8, and ::1 are never proxied.
from browser-extension.
Edition: FoxyProxy Basic
Version: 7.5.1
I am typing localhost:8383 into the address bar and I see it doesn't connect. When I select "turn Foxyproxy off", then I can connect.
from browser-extension.
In that case, it appears that the Firefox proxy.onRequest bypasses the localhost restrictions.
FoxyProxy v8.0 already has Global Exclude feature which can be used (once it is released).
Please wait for FoxyProxy v8.0.
from browser-extension.
In that case, it appears that the Firefox proxy.onRequest bypasses the localhost restrictions.
that sounds like a bug in Firefox then, I suppose.
Do you think it's worth following up with them?
from browser-extension.
TBH, proxy.onRequest is an independent process. That is probably why it is not taking into account the settings set in Network settings which is a totally different process.
I am going to ask Mozilla engineers about it.
from browser-extension.
I don't think that's Firefox's bug.
In Foxy version 7.5.1,
If you set Foxy to "use patterns with enabled proxy by patterns and order" , the Option "Do not use for localhost and intranet/private IP addresses" is taken into consideration.
Ref: https://github.com/foxyproxy/firefox-extension/blob/master/src/scripts/matcher.js#L20-L40
If you set Foxy to use the specific proxy , then Foxy will always use the proxy.
Ref: https://github.com/foxyproxy/firefox-extension/blob/a3598e1c7f0237ee50e8a13a59dec265462c38a6/src/scripts/matcher.js#L65
from browser-extension.
@jackyzy823 Thank you for looking into the issue.
The query posted to matrix was a general one.
If a proxy is set in Firefox, localhost
will not be proxied.
Firefox ☰ ➜ Settings ➜ General ➜ Network Settings ➜ Connection Settings
Connections to localhost, 127.0.0.1/8, and ::1 are never proxied.
However, if a proxy is set via proxy.onRequest, it is reported that the localhost
is proxied. i.e.
Firefox -> Proxy-server -> localhost
I can not test that currently with my set-up but if that is the case, it would not only be undesirable, but also a security concern.
Can that be confirmed?
The query is about the Firefox process and the FoxyProxy code should be irrelevant. e.g.
Normal proxy connection: Firefox -> proxy -> target
For localhost: Firefox -> disregard-proxy -> localhost
// Don't use proxy for local hosts (plain hostname, no dots)
if (!isIpAddr && !host.Contains('.')) {
return true;
}
if (host.EqualsLiteral("127.0.0.1") || host.EqualsLiteral("::1")) {
return true;
}
https://searchfox.org/mozilla-central/source/netwerk/test/gtest/TestProtocolProxyService.cpp#26-37
auto CheckLoopbackURLs = [&](bool expected) {
// loopback IPs are always filtered
spec = "http://127.0.0.1/";
ASSERT_EQ(NS_NewURI(getter_AddRefs(url), spec), NS_OK);
ASSERT_EQ(pps->CanUseProxy(url, 80), expected);
spec = "http://[::1]/";
ASSERT_EQ(NS_NewURI(getter_AddRefs(url), spec), NS_OK);
ASSERT_EQ(pps->CanUseProxy(url, 80), expected);
spec = "http://localhost/";
ASSERT_EQ(NS_NewURI(getter_AddRefs(url), spec), NS_OK);
ASSERT_EQ(pps->CanUseProxy(url, 80), expected);
};
PS. FoxyProxy 8.0 is the most up-to-date, although not released yet.
from browser-extension.
I think if "proxy add-ons" take over control of Proxy settings, then the settings in Firefox config would not take effect (and also it shouldn't) .
from browser-extension.
@jackyzy823
There are 2 main proxying API in Firefox:
- proxy.settings which sets the values of browser Connection Settings (i.e. an interface for Connection Settings)
- proxy.onRequest which is based on webRequest API and intercepts net requests
Chrome only has proxy.settings.
localhost
proxy.settings
in both Firefox and Chrome implement a default bypass/pass-through forlocalhost
proxy.onRequest
does not appear to have the above default bypass
The question is, should proxy.onRequest
have a default bypass/pass-through for localhost
or not?
from browser-extension.
For the time being, a default bypass/past-through for localhost
is added to the FoxyProxy v8.0.
from browser-extension.
See also:
Bug 1854324: proxy.onRequest failure to bypass proxy for localhost
from browser-extension.
Related Issues (20)
- Incorrect import of a proxy with `socks` protocol HOT 15
- FoxyProxy is incompatible with the SpoofDPI proxy server HOT 3
- The tab bar is stuck on progress bar HOT 2
- didn't forward all traffic HOT 1
- QUIC (HTTP/3) connections do not work when using socks5 proxies HOT 8
- socks5 proxy (ssh -D) Firefox MAC not working anymore HOT 5
- Proxy by patterns does not work for https://www.tiktok.com/favicon.ico HOT 2
- [QUESTION] Combining proxies and their whitelist/blacklsit settings from two FoxyProxy generations HOT 15
- [Question] Restoring all foxyproxy settings after reinstall - Firefox HOT 1
- Proxy patterns ignored on tabs HOT 2
- feature request: easily move pattern from one proxy to the other HOT 3
- Allow (temporary) changing of managed settings HOT 3
- HTTPS proxies don't work HOT 19
- localhost bypass not working HOT 7
- Extension does not work any longer - message "Settings are controlled by other extensions" HOT 8
- HTTPS proxy on Chrome keeps prompting sign in HOT 12
- Feature Request: bulk delete HOT 3
- Cannot enable proxy when using firefox enterprise policies.json on NixOS HOT 5
- Doesn't work with LibreWolf HOT 3
- Localhost Inaccessible When Using FoxyProxy (SOCKS5) HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from browser-extension.