decoded plaintext credentials before params get re-encoded in ssApiClient

This commit is contained in:
Penelope Gwen 2024-11-26 19:02:46 -08:00
parent be0ebac362
commit b348b36ecc

View file

@ -295,12 +295,12 @@ export const ssApiClient = (args: {
const token = server.credential; const token = server.credential;
const params = token.split(/&?\w=/gm); const params = token.split(/&?\w=/gm);
authParams.u = server.username; authParams.u = decodeURIComponent(server.username);
if (params?.length === 4) { if (params?.length === 4) {
authParams.s = params[2]; authParams.s = params[2];
authParams.t = params[3]; authParams.t = params[3];
} else if (params?.length === 3) { } else if (params?.length === 3) {
authParams.p = params[2]; authParams.p = decodeURIComponent(params[2]);
} }
} else { } else {
baseUrl = url; baseUrl = url;