matamorphosis / Scrummage

A Holistic OSINT and Threat Hunting Platform
GNU General Public License v3.0
502 stars 81 forks source link

Request contains an invalid argument in Google search when limit is set #12

Closed Joukahainen123 closed 4 years ago

Joukahainen123 commented 4 years ago

Hi,

If I set the limit value to anything else than default, Google search will fail with following error:

WARNING:root:2020-07-07 14:25:43 - Google_Search - <HttpError 400 when requesting https://customsearch.googleapis.com/customsearch/v1?q=Kerava&cx=[REMOVED]=50&key=[REMOVED]=json returned "Request contains an invalid argument."> INFO:root:2020-07-07 14:25:43 Connectors Library - Loading Scrummage's Main Database configuration data.

matamorphosis commented 4 years ago

I'll keep this issue open for now, it appears any number up to 10 is fine. But it looks like it might be an issue with the Google API itself as the parameter used doesn't return more than 10 results at a time. Leave it with me and I'll investigate it further, I may be able to make a work-around for this.

matamorphosis commented 4 years ago

The issue has been resolved. The limit can only be up to 100 due to API restrictions, but under that, you should be fine.