From 82e3bde392a79e276b9ac4e220c006eb1cc83e3a Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Fri, 6 May 2011 11:00:59 +0200 Subject: Fake Useragent (pretend to be Firefox) --- bin/comirror | 1 + bin/comirror-setup | 1 + 2 files changed, 2 insertions(+) (limited to 'bin') diff --git a/bin/comirror b/bin/comirror index 453a46b..98353a6 100755 --- a/bin/comirror +++ b/bin/comirror @@ -8,6 +8,7 @@ use WWW::Mechanize; my $mech = WWW::Mechanize->new( stack_depth => 2, ); +$mech->agent_alias('Linux Mozilla'); our $VERSION = '0.1'; diff --git a/bin/comirror-setup b/bin/comirror-setup index 6bdbbe9..b9e1198 100755 --- a/bin/comirror-setup +++ b/bin/comirror-setup @@ -90,6 +90,7 @@ print 'Fetching pages'; for my $url (@ARGV) { push(@mechs, WWW::Mechanize->new( stackdepth => 0 )); + $mechs[-1]->agent_alias('Linux Mozilla'); $mechs[-1]->get($url); print q{.}; } -- cgit v1.2.3