[Privoxy-users] forward-override based on user-agent tag does opposite of what it should

Fabian Keil fk at fabiankeil.de
Wed Oct 18 15:37:39 CEST 2023


Synan B <rsbernt at gmail.com> wrote on 2023-10-18 at 11:30:07:

> 1. Enabled debug 128 & 65536 in privoxy/config
> 2. # privoxy --no-daemon  (to see headers output)

You could also enable logging:
https://www.privoxy.org/user-manual/config.html#LOGFILE

> 3. In privoxy/user.action
> 	{+client-header-tagger{user-agent}}
> 	/
> 
> 	{+forward-override{forward-socks5t 127.0.0.1:9050 .} }
> 	TAG:^User-Agent: FreeBSD
> 
> 4. Switch the user-agent of browser to custom testing entry: FreeBSD
> http://config.privoxy.org/show-request confirms: User-Agent: FreeBSD
> 
> PROBLEM:
> * Traffic from browser is NOT redirected to Tor proxy
> * Traffic from browser to http://config.privoxy.org shows correct header
> +forward-override{forward-socks5t 127.0.0.1:9050 .}

It would help to see a Privoxy log excerpt.

If you add:
debug     4 # show tagging-related message

You should get lines similar to this:

15:22:20.583 034 Tagging: Tagger 'user-agent' added tag 'User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:109.0) Gecko/20100101 Firefox/115.0'. Action bits updated accordingly.

or:

15:26:02.603 013 Tagging: Tagger 'user-agent' added tag 'User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:109.0) Gecko/20100101 Firefox/115.0'. No action bits update necessary.

The last sentence is relevant here.

If Privoxy claims "No action bits update necessary."
it means the tag didn't affect the action settings.

If you modify the debug settings anyway you could
enable the other debug settings suggested at:
https://www.privoxy.org/user-manual/contact.html
as well.

> So packets to External are not redirected, but packets to Internal are?

As an HTTP(S) proxy Privoxy only deals with connections
not individual packets.

Fabian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <https://lists.privoxy.org/pipermail/privoxy-users/attachments/20231018/17021261/attachment.bin>


More information about the Privoxy-users mailing list