New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 620874 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Jun 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Chrome , Mac
Pri: 2
Type: Bug

Blocking:
issue 543161



Sign in to add a comment

Use WebSafe Base64 encoding when sending requests to PVer4 SafeBrowsing server.

Project Member Reported by vakh@chromium.org, Jun 16 2016

Issue description

Use WebSafe Base64 encoding when sending requests to PVer4 SafeBrowsing server. The web safe encoding is defined here:
https://tools.ietf.org/html/rfc3548#section-4

The server doesn't understand basic base64 encoding. Confirmed by awoz.

This hash fails:
GiIIARACGhoKDQgBEAYYASIDMDAxMAEQ00EaAhgKW+JBOSgB

This one works:
GiIIARACGhoKDQgBEAYYASIDMDAxMAEQ00EaAhgKW-JBOSgB
 

Comment 1 by vakh@chromium.org, Jun 16 2016

As far as I can tell, as long as we convert all the '+' to '-' and '/' to '_', we're fine so that's what I am going to do.

Comment 2 by awoz@chromium.org, Jun 16 2016

FYI, I think this is the latest RFC reference: https://tools.ietf.org/html/rfc4648#page-7

Comment 3 by mattm@chromium.org, Jun 16 2016

See base/base64url.h

Comment 4 by vakh@chromium.org, Jun 16 2016

Luckily, I don't need to solve this problem. It is available at: https://cs.chromium.org/chromium/src/base/base64url.h?sq=package:chromium&dr=CSs&rcl=1466090357&l=30

Comment 5 by vakh@chromium.org, Jun 16 2016

mattm@ -- you beat me by seconds. Thanks for pointing it out.

Comment 6 by vakh@chromium.org, Jun 17 2016

Labels: SafeBrowsing-Triaged

Comment 7 by vakh@chromium.org, Jun 21 2016

awoz@ -- can you please tell us which Base64UrlEncodePolicy to use?
https://cs.chromium.org/chromium/src/base/base64url.h?sq=package:chromium&dr=CSs&rcl=1466090357&l=17

FWIW: There are more instances of usage of INCLUDE_PADDING in Chromium than OMIT_PADDING.

Comment 8 by awoz@chromium.org, Jun 22 2016

Our server accepts payloads with padding.

Comment 10 by vakh@chromium.org, Jun 29 2016

Status: Fixed (was: Assigned)

Sign in to add a comment