Ensure client secret is encoded properly in Authorization header (#20000)

Closes #19879
This commit is contained in:
Mica Hallin 2023-05-16 13:18:43 +02:00 committed by GitHub
parent edb292664c
commit 7502a31421
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -79,7 +79,7 @@ export const getToken = async (settings: Settings): Promise<TokenResponse> => {
if (credentials.clientSecret) {
headers.set(
"Authorization",
atob(credentials.clientId + ":" + credentials.clientSecret)
`Basic ${btoa(`${credentials.clientId}:${credentials.clientSecret}`)}`
);
}