windows: autoProxy keeps to its exclusions, and its listing to its scope
proxy.autoProxy.exclude is never probed or routed: learn and probe requests for an excluded host are refused, and a site learned whole (example.com) routes no excluded name under it (intranet.example.com): the learned rule skips them. Without the secrets scope, proxy-ctl proxy auto lists the sites routed and counts: the hosts probed, those left to zapret and the sites behind each strike are browsing history, as the logs are. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
5a89b8d11d
commit
694e176353
5 files changed
+82
-12
No files matched your search
@@ -581,7 +581,7 @@ pub async fn handle(req: Request, peer: &Peer, shared: &Shared) -> Response {
|
||||
Request::AutoList => {
|
||||
let s = shared.lock().await;
|
||||
let exits = crate::autoproxy::exits(&s);
|
||||
Response::ok(crate::autoproxy::listing(s.paths(), exits.as_ref(), &s.cfg().proxy.auto_proxy))
|
||||
Response::ok(crate::autoproxy::listing(s.paths(), exits.as_ref(), &s.cfg().proxy.auto_proxy, has_secrets(s.cfg(), peer)))
|
||||
}
|
||||
|
||||
Request::AutoProbe { target, exits, via, keep_going } => {
|
||||
@@ -604,6 +604,14 @@ pub async fn handle(req: Request, peer: &Peer, shared: &Shared) -> Response {
|
||||
if !bad.is_empty() {
|
||||
return Response::err(format!("not host names: {}", bad.iter().map(|h| h.as_str()).collect::<Vec<_>>().join(", ")));
|
||||
}
|
||||
let opts = &s.cfg().proxy.auto_proxy;
|
||||
let skipped: Vec<&String> = hosts.iter().filter(|h| crate::autoproxy::excluded(opts, &h.trim().to_ascii_lowercase())).collect();
|
||||
if !skipped.is_empty() {
|
||||
return Response::err(format!(
|
||||
"in proxy.autoProxy.exclude, never probed: {}",
|
||||
skipped.iter().map(|h| h.as_str()).collect::<Vec<_>>().join(", ")
|
||||
));
|
||||
}
|
||||
let queued = {
|
||||
let mut r = s.ap.requests.lock().unwrap();
|
||||
// Bounded: every request is a probe.
|
||||
|
||||
Reference in new issue
Block a user