i0datamonster / metagoofil

Automatically exported from code.google.com/p/metagoofil
GNU General Public License v2.0
0 stars 0 forks source link

Google now answers with HTTP 302 which metagoofil 2.2 does not follow yet #14

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. default run of metagoofil taken from help screen

What is the expected output? What do you see instead?
expected:  lots of results from apple.com
instead:   0 results, due to HTTP 302 from google

What version of the product are you using? On what operating system?
2.2

Please provide any additional information below.

I solved it by inserting following code in line 28 of discovery/googlesearch.py:

                if returncode == 302:
                        h = httplib.HTTP(self.server)
                        h.putrequest('GET', headers.getheader('Location')[20:])
                        h.putheader('Host', self.hostname)
                        h.putheader('User-agent', self.userAgent)
                        h.endheaders()
                        returncode, returnmsg, headers = h.getreply()

best regards &

many thanks to author for this great piece of software!

Original issue reported on code.google.com by rn13...@gmail.com on 15 Apr 2015 at 10:18

Attachments:

GoogleCodeExporter commented 8 years ago
This didn't worked in my case. Can you recheck if your fix is still working?

Thanks in advance.

Original comment by Krish.Pa...@gmail.com on 26 May 2015 at 8:39

GoogleCodeExporter commented 8 years ago
The fix doesn't work anymore because they shifted the redirection from HTTP 
header to javascript logic. Seems that they don't like to be queried this way :(

Original comment by rn13...@gmail.com on 30 Jun 2015 at 6:59