Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improves login experience when no localhost is available. #4147

Merged
merged 13 commits into from
Feb 10, 2022
Prev Previous commit
Next Next commit
Fix lint error
  • Loading branch information
mbleigh committed Dec 8, 2021
commit bab40ab29e272b88c0ce0bd8211013b9ff952f9e
2 changes: 1 addition & 1 deletion src/auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,7 @@ async function loginRemotely(userHint?: string): Promise<UserCredentials> {
const sessionId = uuidv4();
const codeVerifier = randomBytes(32).toString("hex");
// urlsafe base64 is required for code_challenge in OAuth PKCE
let codeChallenge = urlsafeBase64(createHash("sha256").update(codeVerifier).digest("base64"));
const codeChallenge = urlsafeBase64(createHash("sha256").update(codeVerifier).digest("base64"));

const attestToken = (
await authProxyClient.post<{ session_id: string }, { token: string }>("/attest", {
Expand Down