privacypass-ts icon indicating copy to clipboard operation
privacypass-ts copied to clipboard

header_to_token: base64 only once

Open hacklschorsch opened this issue 3 months ago • 0 comments

header_to_token() is a very nice high-level API for turning a WWW-Authenticate header (a Token Request) into an Authorization header (a Token).

Unfortunately, currently it's broken: It encodes the header that fetchToken() returns ready to use (especially already encoded as base64) another time as base64. That is one time too many.

hacklschorsch avatar Oct 11 '25 22:10 hacklschorsch