oauth2/internal
Aeneas Rekkas (arekkas) 13449ad91c internal: urlencode client id and secret in header
As per https://tools.ietf.org/html/rfc6749#section-2.3.1 client IDs and secrets must be urlencoded in the authorization header. This patch addresses this by wrapping clientID and clientSecret with url.QueryEscape. A dedicated test for unsafe-url client IDs and secrets has been added as well.

Closes #237

Change-Id: I1f277b52caef4932e14147be8fb1712203da51d0
Reviewed-on: https://go-review.googlesource.com/46473
Reviewed-by: JBD <jbd@google.com>
2017-09-12 21:29:05 +00:00
..
oauth2.go internal: simplify map value literal 2017-02-14 23:18:24 +00:00
oauth2_test.go internal: simplify map value literal 2017-02-14 23:18:24 +00:00
token.go internal: urlencode client id and secret in header 2017-09-12 21:29:05 +00:00
token_test.go internal: Use provided context in subsequent request 2017-06-29 18:09:26 +00:00
transport.go internal: primarily use the HTTP client provided in the context 2015-12-04 19:36:38 +00:00
transport_test.go internal: fix transport_test use of nil Context 2016-05-04 21:42:46 +00:00