felix
felix

Reputation: 11552

Regarding Google Safe Browsing API

Does anyone know how to use the Google safe browsing API.

I downloaded the entire the malware and phish update from the google safe browsing using the API key and tried comparing the hash of the suspicious site (md5_file method in php) but it did not work. I also tried comparing the hash of the suspicious site's url (md5 method in php).

Am I doing something wrong here?

Upvotes: 6

Views: 1757

Answers (2)

Brian
Brian

Reputation: 25834

You need to use a canonical version of the site url. The canonicalization algorithm is officially documented, along with examples, at https://developers.google.com/safe-browsing/v4/urls-hashing#canonicalization . Also, I think using the suffix or prefix of the url may be necessary depending on what you are doing with the url.

Upvotes: 4

Chris Harris
Chris Harris

Reputation: 4735

Also, check out the BrightCloud web filtering API. It's a bit more straightforward to use (a REST web interface). It's better, but does cost money (it's still quite affordable).

(FWIW - I am a founder of BrightCloud.)

Upvotes: -2

Related Questions