blob: e70d085c71026badbd464d3c2c92ea49100b97d6 [file] [log] [blame]
<input type="text" id="input">
<script>
if (window.internals) {
internals.setMockWebAuthenticationConfiguration({ local: { userVerification: "no", acceptAttestation: false } });
internals.withUserGesture(() => { input.focus(); });
}
const options = {
publicKey: {
rp: {
name: "localhost",
},
user: {
name: "John Appleseed",
id: new Uint8Array(16),
displayName: "Appleseed",
},
challenge: new Uint8Array(16),
pubKeyCredParams: [{ type: "public-key", alg: -35 }, { type: "public-key", alg: -257 }], // ES384, RS256
timeout: 100,
}
};
navigator.credentials.create(options);
</script>