[Privoxy-users] Configure privoxy to proxy all requests to the same web page

Steven Smith steve.t.smith at gmail.com
Mon Sep 27 17:51:16 UTC 2021


I’ve set match-all.action to:

> { \                                                                             
> +redirect{http://localhost:8119/} \                                             
> }                                                                               
> / # Match all URLs                                                              



This works as expected for HTTP:

> curl -I -L --proxy http://localhost:8118 http://whatever.com/


This problem is with HTTPS:

> curl -I -L --proxy-insecure --proxy http://localhost:8118 <http://localhost:8118/> https://google.com/?q=foobar
> HTTP/1.1 302 Local Redirect from Privoxy
> Location: http://localhost:8119/
> Content-Length: 0
> Date: Mon, 27 Sep 2021 17:47:49 GMT
> Connection: close
> 
> curl: (56) Received HTTP code 302 from proxy after CONNECT





> On Sep 26, 2021, at 8:17 AM, Steven Smith <steve.t.smith at gmail.com> wrote:
> 
> I’d like to configure privoxy to proxy all requests to the same web page, say http://localhost:8119/default.html <http://localhost:8119/default.html>, or perhaps simply return 200 with a blank page.
> 
> Both http GET and https CONNECT requests should always return the same page and same 200 return code:
> 
> curl -I --proxy http://localhost:8118 <http://localhost:8118/> http://whatever.com/ <http://whatever.com/>
> curl -I --proxy http://localhost:8118 <http://localhost:8118/> https://google.com?q=foobar <https://google.com/?q=foobar>
> 
> What’s the simple way to do this with privoxy?
> 
> The context is that I’d like to blackhole specific connections determined within a proxy.pac file.



More information about the Privoxy-users mailing list