Closed baoweili closed 1 week ago
You need HTTPS or localhost for randomUUID to be available. Is it possible you are doing that over an unsecured connection?
Alternatively, you can specify the user id directly :
const registration = await client.register({ user: {id:'some-anonymous-id', name:username}, challenge, hints: ['client-device'] });
Please note that the user "id" should be anonymous as it can be exposed by the authenticator without user verification. In plain english, if you find a security key laying on the ground, you might be able to list the user ids present on it (but not the names).
@baoweili solved?
When I use iPhone 13 iOS 14, an error occurs: crypto.randomUUID is not a function. The code is as follows:
const registration = await client.register({ user: username, challenge, hints: ['client-device'] });
@passwordless-id/webauthn version is 2.1.0