-
Notifications
You must be signed in to change notification settings - Fork 167
LG-11433: FT unlock redirect to options page if eligible only #9835
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
Changes from all commits
3caace0
3470cbb
ba686e3
b4d68f8
1244e69
4f8b8a1
6880fc3
da26d72
2fff708
ccee0cd
0f388f5
d7ed538
d6a13bb
f428f03
2c79e27
d3a129e
86649ec
64371de
d7df22c
6cd7e83
ac3b3bf
de4541c
48e61df
c986489
d894294
4b12998
4920ed3
b0398e4
5207b09
4b7b486
46c2497
717f2da
5236b87
c29c71d
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Question: There are many ways that a user might be prompted for MFA, such as reauthentication. Can we always rely on the session value being present in those other scenarios? My thinking is yes since someone's session should always begin from the sign-in page, but I wanted to ask to double-check.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think it should for sure, but I dont know if in reauthenthication we want this? Maybe we can remove it when its directed. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| import { | ||
| isWebauthnPlatformAuthenticatorAvailable, | ||
| isWebauthnPasskeySupported, | ||
| } from '@18f/identity-webauthn'; | ||
|
|
||
| async function platformAuthenticatorAvailable() { | ||
| const platformAuthenticatorAvailableInput = document.getElementById( | ||
| 'platform_authenticator_available', | ||
| ) as HTMLInputElement; | ||
| if (!platformAuthenticatorAvailableInput) { | ||
| return; | ||
| } | ||
| if (isWebauthnPasskeySupported() && (await isWebauthnPlatformAuthenticatorAvailable())) { | ||
| platformAuthenticatorAvailableInput.value = 'true'; | ||
| } else { | ||
| platformAuthenticatorAvailableInput.value = 'false'; | ||
| } | ||
| } | ||
|
|
||
| platformAuthenticatorAvailable(); |
Uh oh!
There was an error while loading. Please reload this page.