dzamanakos

Well-Known Member
Feb 15, 2014
61
4
58
cPanel Access Level
Root Administrator
Hi, i've read about SecGsbLookupDb and mod_security and see that :
Note : Deprecated in 2.7.0 after Google dev team decided to not allow the database download anymore. After registering and obtaining a Safe Browsing API key, you can automatically download the GSB using a tool like wget (where KEY is your own API key):
wget sb.google.com/safebrowsing/update?client=api&apikey=KEY&version=goog-malware-hash:1:-1

i've read some articles in the internet (not mod_security specific), made an api key but cant find a way to download the database to my server. The url's mentioned in the posts return 404 error when wget url.

Is there anyone that found a way to download it?

Thank you,
 
Last edited by a moderator:

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,909
2,227
463
Hello :)

Did you register with Google and obtain a safe browsing API key?

Thank you.
 

dzamanakos

Well-Known Member
Feb 15, 2014
61
4
58
cPanel Access Level
Root Administrator
Yes i got an api key, but cant find a url that i can download a dat or something file with a wget... All the url's that i found in forums return an error and no data file is downloaded.
Thank you,
 

dzamanakos

Well-Known Member
Feb 15, 2014
61
4
58
cPanel Access Level
Root Administrator
I've read about it, but i can understand that you can no longer download the database with a cron and do local queries..
Just query for a single or multiple url's to google and get the results.
In the cpanel's mod security configuration it needs a local path to my server.
I didnt find a recent working guide in google or forums.. Posted here if anyone was able to make it working recently..
Thank you again..
 

dzamanakos

Well-Known Member
Feb 15, 2014
61
4
58
cPanel Access Level
Root Administrator
I see that in mod_security configuration there is an entry :
Google Safe Browsing Database SecGsbLookupDb
Specify a path for the Google Safe Browsing Database.

That needs a local path of a database file.
I've read that google no longer supports downloading their database and in mod_security they refer to a url that isnt working anymore. There are some old guides in the internet that trying to overide this, but the solutions dont work. I just wondered if someone has a way of make it work, either by local database file, or remote connections..
Thank you again..
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,909
2,227
463
Any update on this?
Hello :)

You will need to consult with Google if you have obtained an API key and there's no valid download location. The feature was deprecated in Mod_Security after Google began forcing the use of an API key to download the file.

Thank you.
 

cPanelLauren

Product Owner
Staff member
Nov 14, 2017
13,296
1,271
313
Houston
Because they include it with the installation. Information is noted in in the link to SecGsbLookupDb:

https://github.com/SpiderLabs/ModSecurity/wiki/Reference-Manual-%28v2.x%29#secgsblookupdb said:
SecGsbLookupDb
Description: Defines the path to the database that will be used for Google Safe Browsing (GSB) lookups.

Syntax: SecGsbLookupDb /path/to/db

Example Usage: SecGsbLookupDb /path/to/GsbMalware.dat

Scope: Any

Version: 2.6.0

Supported on libModSecurity: TBD

ModSecurity relies on the free Google Safe Browsing database that can be obtained from the Google GSB API http://code.google.com/apis/safebrowsing/.

Note : Deprecated in 2.7.0 after Google dev team decided to not allow the database download anymore. After registering and obtaining a Safe Browsing API key, you can automatically download the GSB using a tool like wget. For further information on how to proceed with the download, please visit Google's website: https://developers.google.com/safe-browsing/v3/update-guide