Hey everyone, I have a question around passkey sig...
# ory-selfhosting
g
Hey everyone, I have a question around passkey sign ups. I want to make the passkey identifier unique, but we don't have this option in the identity schema. We have
webauthn.identifier: true
, which will use the nickname trait as its unique identifier. This creates two
identity_credential_identifier
for each sign up, one for passkey with a random hash as identifier and one for webauthn using the nickname input from the user. My only auth method will be passkey and nothing else. Is it correct to use "webauthn" only as a way to validate uniqueness?
Copy code
identity.schema.json

{
  "$schema": "<http://json-schema.org/draft-07/schema#>",
  "title": "Person",
  "type": "object",
  "properties": {
    "traits": {
      "type": "object",
      "properties": {
        "nickname": {
          "type": "string",
          "title": "Nickname",
          "<http://ory.sh/kratos|ory.sh/kratos>": {
            "credentials": {
              "passkey": {
                "display_name": true
              },
              "webauthn": {
                "identifier": true
              }
            }
          }
        }
      },
      "required": ["nickname"],
      "additionalProperties": false
    }
  }
}