Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Bug#827186: links2: -http.fake-user-agent "UA" fails

42 views
Skip to first unread message

Fulano Diego Perez

unread,
Jun 13, 2016, 10:00:10 AM6/13/16
to

Package: links2
Version: 2.12-2
Severity: normal


try with these but not working from a few ip test sites like wtfismyip.com

-http.fake-user-agent 'UA'
-http.fake-user-agent "UA"

used with/without some other options still fails

which ever UA i try to use firefox 38 is reported

also the same when using fake.firefox 0/1



-- System Information:
Debian Release: stretch/sid
APT prefers testing
APT policy: (500, 'testing')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.5.0-2-amd64
Locale: LANG=en_AU.UTF-8, LC_CTYPE=en_AU.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages links2 depends on:
ii libbz2-1.0 1.0.6-8
ii libc6 2.22-7
ii libcairo2 1.14.6-1+b1
ii libdirectfb-1.2-9 1.2.10.0-5.2+b1
ii libevent-2.0-5 2.0.21-stable-2+b1
ii libgdk-pixbuf2.0-0 2.34.0-1
ii libglib2.0-0 2.48.1-1
ii libgomp1 6.1.1-4
ii libgpm2 1.20.4-6.2
ii libjpeg62-turbo 1:1.4.2-2
ii liblzma5 5.1.1alpha+20120614-2.1
ii libpng16-16 1.6.21-5
ii librsvg2-2 2.40.15-1
ii libssl1.0.2 1.0.2h-1
ii libtiff5 4.0.6-1
ii libx11-6 2:1.6.3-1
ii zlib1g 1:1.2.8.dfsg-2+b1

Versions of packages links2 recommends:
ii gnome-terminal [x-terminal-emulator] 3.20.2-1
ii stterm [x-terminal-emulator] 0.6-1
ii xterm [x-terminal-emulator] 324-2

links2 suggests no packages.

-- no debconf information

Axel Beckert

unread,
Jun 13, 2016, 10:40:02 AM6/13/16
to
Control: tag -1 unreproducible

Hi,

Fulano Diego Perez wrote:
> Package: links2
> Version: 2.12-2
> Severity: normal
>
>
> try with these but not working from a few ip test sites like wtfismyip.com
>
> -http.fake-user-agent 'UA'
> -http.fake-user-agent "UA"
>
> used with/without some other options still fails

I'm sorry, but I can't reproduce this issue:

Calling "links2 -http.fake-user-agent UA http://wtfismyip.com/headers"
gives me as expected:

host: wtfismyip.com
user-agent: UA
accept: */*
accept-language: en,*;q=0.1
accept-encoding: gzip,deflate,bzip2,lzma,lzma2
accept-charset:
us-ascii,ISO-8859-1,ISO-8859-2,ISO-8859-3,ISO-8859-4,ISO-8859-5,ISO-8859-6,[...]
connection: keep-alive

Switching to HTTPS does not make a difference either. Same for links2
on Debian Stable.

> also the same when using fake.firefox 0/1

Never heard of that option/setting and it's neither in the man page,
nor in the --help output nor listed in ~/.links2/links.cfg nor can
such a binary setting be seen in the menu under Setup -> Network options
-> HTTP options -> Headers options.

Regards, Axel
--
,''`. | Axel Beckert <a...@debian.org>, http://people.debian.org/~abe/
: :' : | Debian Developer, ftp.ch.debian.org Admin
`. `' | 4096R: 2517 B724 C5F6 CA99 5329 6E61 2FF9 CD59 6126 16B5
`- | 1024D: F067 EA27 26B9 C3FC 1486 202E C09E 1D89 9593 0EDE

Fulano Diego Perez

unread,
Jun 14, 2016, 6:10:03 AM6/14/16
to
which menu is that in stretch ?

$ links2 -h

-http.fake-firefox <0>/<1>
(default 0)
Fake Firefox in the HTTP header.


> ~/.links2/links.cfg

i have none



with all 3 below:

$ links2 -socks-proxy 127.0.0.1:9051 -only-proxies 1 -http.referer 0
-http.fake-user-agent "3 com" https://wtfismyip.com/headers/

$ links2 -socks-proxy 127.0.0.1:9051 -only-proxies 1 -http.referer 0
-http.fake-user-agent "Mozilla/5.0 (Windows NT 6.1; rv:45.0)
Gecko/20100101 Firefox/45.0" https://wtfismyip.com/headers/

$ links2 -socks-proxy 127.0.0.1:9051 -only-proxies 1 -http.referer 0
-http.fake-user-agent " " https://wtfismyip.com/headers/

host: wtfismyip.com
user-agent: Mozilla/5.0 (Windows NT 6.1; rv:38.0) Gecko/20100101
Firefox/38.0
accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
accept-language: en-US,en;q=0.5
accept-encoding: gzip, deflate
connection: keep-alive

this is in my man page:

-http.fake-firefox <0>/<1>
(default 0) Fake that the browser is Firefox in the HTTP
header.

dpkg --reconfigure

?

Axel Beckert

unread,
Jun 17, 2016, 2:00:02 PM6/17/16
to
Control: tag -1 - unreproducible + confirmed upstream
Control: retitle -1 links2: Setting "-only-proxies 1" also sets "-http.fake-firefox 1" unconditionally

Hi,

Fulano Diego Perez wrote:
> > I'm sorry, but I can't reproduce this issue:
> >
> > Calling "links2 -http.fake-user-agent UA http://wtfismyip.com/headers"
> > gives me as expected:
> >
> > host: wtfismyip.com
> > user-agent: UA
> > accept: */*
> > accept-language: en,*;q=0.1
> > accept-encoding: gzip,deflate,bzip2,lzma,lzma2
> > accept-charset:
> > us-ascii,ISO-8859-1,ISO-8859-2,ISO-8859-3,ISO-8859-4,ISO-8859-5,ISO-8859-6,[...]
> > connection: keep-alive
> >
> > Switching to HTTPS does not make a difference either. Same for links2
> > on Debian Stable.

This is still the case.

> >> also the same when using fake.firefox 0/1
> >
> > Never heard of that option/setting and it's neither in the man page,
> > nor in the --help output nor listed in ~/.links2/links.cfg nor can
> > such a binary setting be seen in the menu under Setup -> Network options
> > -> HTTP options -> Headers options.
>
> which menu is that in stretch ?

Indeed, I now see the option in Sid. For my previous mail I checked
both, Jessie and Sid in parallel and looked up the man-page and -h
output on Jessie instead of Sid. Sorry for that mistake.

On Sid you can find it under Setup -> Network options -> HTTP options
-> Header options -> Fake Firefox

> with all 3 below:
>
> $ links2 -socks-proxy 127.0.0.1:9051 -only-proxies 1 -http.referer 0
> -http.fake-user-agent "3 com" https://wtfismyip.com/headers/
>
> $ links2 -socks-proxy 127.0.0.1:9051 -only-proxies 1 -http.referer 0
> -http.fake-user-agent "Mozilla/5.0 (Windows NT 6.1; rv:45.0)
> Gecko/20100101 Firefox/45.0" https://wtfismyip.com/headers/
>
> $ links2 -socks-proxy 127.0.0.1:9051 -only-proxies 1 -http.referer 0
> -http.fake-user-agent " " https://wtfismyip.com/headers/

Thanks for these more detailed examples. That helped a lot to
understand where the issue is.

I can confirm that these combinations of options behave as if
-http.fake-firefox would have been set to 1.

Dropping the "-only-proxies 1" make the remainder work as expected.

Unfortunately I found no obvious reason in the source code why these
two options should be connected. Will forward the issue to upstream.

> dpkg --reconfigure

Nope. That has nothing to do with this issue.
0 new messages