This commit is contained in:
Jack Mechem 2026-05-01 16:21:50 -07:00
parent c991fe7b6d
commit e6b5fed399
8 changed files with 6647 additions and 6623 deletions

View file

@ -50,6 +50,14 @@ export default function EnrollPage() {
const opts = challenge.publicKey;
opts.challenge = b64uToBuf(opts.challenge);
opts.user.id = b64uToBuf(opts.user.id);
// Force security key UI — residentKey/UV discouraged so Android
// Chrome doesn't suppress the NFC option in favour of biometrics
opts.authenticatorSelection = {
authenticatorAttachment: "cross-platform",
residentKey: "discouraged",
requireResidentKey: false,
userVerification: "discouraged",
};
if (opts.excludeCredentials) {
opts.excludeCredentials = opts.excludeCredentials.map(
(c: { id: string; type: string; transports?: string[] }) => ({
@ -89,9 +97,7 @@ export default function EnrollPage() {
response: {
attestationObject: bufToB64u(attestation.attestationObject),
clientDataJSON: bufToB64u(attestation.clientDataJSON),
transports: attestation.getTransports
? attestation.getTransports()
: [],
transports: ["usb", "nfc", "ble", "hybrid"],
},
extensions: {},
},