Security/Safe Browsing/V4 Implementation: Difference between revisions

Jump to navigation Jump to search
Reorganize the headings
(→‎Try Google Safe Browsing v4!: improve the instructions on how to enable V4)
(Reorganize the headings)
Line 1: Line 1:
= Quick Links =
* [[Security/Safe_Browsing/V4_Implementation/Dashboard|Dashboard]]
* [[Security/Safe_Browsing/V4_Implementation/Dashboard|Dashboard]]
* [https://bugzilla.mozilla.org/showdependencytree.cgi?id=1167038&hide_resolved=1 Bug Dependency Tree]
* [https://bugzilla.mozilla.org/showdependencytree.cgi?id=1167038&hide_resolved=1 Bug Dependency Tree]
= Introduction =
Safe Browsing v4 is designed to reduce network bandwidth and disk storage (mainly for mobile devices). The usage of partial URL hashes (aka prefixes) and complete hashes remains the same but the way we get those prefixes and complete hashes is changed. The update and hash completion API will be based on protobuf and content compression (in additional to HTTP compression) is introduced. For further information, see https://developers.google.com/safe-browsing/v4 (The public specification is not complete. For example, the protobuf is not mentioned.)


= Timeline =
= Timeline =
Line 14: Line 17:
* Firefox 58 (Desktop): merge on 2017-09-20, release on 2018-01-16
* Firefox 58 (Desktop): merge on 2017-09-20, release on 2018-01-16
* Firefox 60 (Android): merge on 2018-01-15, release on 2018-05-01
* Firefox 60 (Android): merge on 2018-01-15, release on 2018-05-01
= Introduction =
Safe Browsing v4 is designed to reduce network bandwidth and disk storage (mainly for mobile devices). The usage of partial URL hashes (aka prefixes) and complete hashes remains the same but the way we get those prefixes and complete hashes is changed. The update and hash completion API will be based on protobuf and content compression (in additional to HTTP compression) is introduced. For further information, see https://developers.google.com/safe-browsing/v4 (The public specification is not complete. For example, the protobuf is not mentioned.)


= Design and Implementation =
= Design and Implementation =
Line 23: Line 23:
When '''ListManager''' and '''HashCompleter''' (and any other related components like ProtocolParser) sees table names suffixed by "-proto", they would behave differently. For example, in '''listmanager.js''', while making update request for table '''goog-phish-proto''', ''nsIUrlClassifier.makeUpdateRequestV4'' will be called to build a v4 specific request. (See {{Bug|1264885}} and {{Bug|1275507}} for more information.)
When '''ListManager''' and '''HashCompleter''' (and any other related components like ProtocolParser) sees table names suffixed by "-proto", they would behave differently. For example, in '''listmanager.js''', while making update request for table '''goog-phish-proto''', ''nsIUrlClassifier.makeUpdateRequestV4'' will be called to build a v4 specific request. (See {{Bug|1264885}} and {{Bug|1275507}} for more information.)


= Using custom API key =
== Using custom API key ==
We are required to have a API key to access Google services like geolocation and Safe Browsing. The nightly/beta/aurora/release Firefox builds will have a proper API key associated with Mozilla. However, if you build your own Firefox, the API key will be substituted with the string <tt>"no-google-api-key"</tt>, which is not a valid key.
We are required to have a API key to access Google services like geolocation and Safe Browsing. The nightly/beta/aurora/release Firefox builds will have a proper API key associated with Mozilla. However, if you build your own Firefox, the API key will be substituted with the string <tt>"no-google-api-key"</tt>, which is not a valid key.


Line 32: Line 32:
# Rebuild and check if <tt>config.status</tt> has something like <tt>'MOZ_GOOGLE_API_KEY': b'AIzaSooxxxxoxoxoxoxooxx'</tt>
# Rebuild and check if <tt>config.status</tt> has something like <tt>'MOZ_GOOGLE_API_KEY': b'AIzaSooxxxxoxoxoxoxooxx'</tt>


= Try Google Safe Browsing V4! =
== Try Google Safe Browsing V4! ==


To use Google Safe Browsing V4, set the following preferences:
To use Google Safe Browsing V4, set the following preferences:
Confirmed users
908

edits

Navigation menu