loud-car-47842
08/19/2025, 7:39 AMbrief-egg-61061
08/19/2025, 7:39 AMbrief-egg-61061
08/19/2025, 7:39 AMloud-car-47842
08/19/2025, 7:40 AMbrief-egg-61061
08/19/2025, 7:40 AMbrief-egg-61061
08/19/2025, 7:41 AMpassword
or oidc
, and each credential type has its own set of unique identifiers. For example, an identity might have a password credential with an email identifier and an OIDC credential with a provider-specific identifier. The type is distinguished by the credential type field in the identity object, such as password
or `oidc`: yaml credentials: password: id: password identifiers: - <mailto:john.doe@acme.com|john.doe@acme.com> oidc: id: oidc identifiers: - google:j8kf7a3... - facebook:83475891...
When a user logs in, Ory uses the identifier (such as an email or OIDC subject) and matches it against the identifiers stored under each credential type. The credential type that matches determines the authentication method and, by extension, the "type" of login being performed (password or OIDC) [Credentials](https://www.ory.sh/docs/kratos/concepts/credentials). Fixing an identifier to be only OIDC: You can control which identifiers are used for each credential type by configuring your identity schema and registration/login flows. If you want an identifier (such as an email or username) to be used only for OIDC and not for password authentication, you should not mark it as a password identifier in your JSON schema. For example, only add the "identifier": true
property under the OIDC credential, and not under the password credential in your schema. This way, the identifier will only be valid for OIDC authentication and not for password-based login [Customize identity schemas](https://www.ory.sh/docs/kratos/manage-identities/customize-identity-schema#password-login-identifier). If you do not enable the password method or do not mark any trait as a password identifier, then only OIDC authentication will be possible for that identifier. Summary: - Ory determines the identity type by matching the provided identifier to the credential type (password, OIDC, etc.). - You can restrict an identifier to be used only for OIDC by configuring your identity schema accordingly and not enabling it as a password identifier. If you need more specific configuration examples, let me know!loud-car-47842
08/19/2025, 7:47 AMbrief-egg-61061
08/19/2025, 7:47 AMbrief-egg-61061
08/19/2025, 7:47 AM<http://ory.sh/kratos|ory.sh/kratos>
extension in the identity schema, but does not mention OIDC identifiers in this context. OIDC credentials and their identifiers (such as the subject from an OIDC provider) are typically managed automatically by Ory Kratos when a user signs in via an OIDC provider. These identifiers are not set through the identity schema, but are instead associated with the identity during the OIDC authentication process [Credentials](https://www.ory.sh/docs/kratos/concepts/credentials). If you need to control or customize OIDC identifiers, you may need to look into Ory's OIDC provider configuration or use the API to manage identities after OIDC login, but this is not covered in the provided knowledge sources.loud-car-47842
08/20/2025, 4:25 PMbrief-egg-61061
08/20/2025, 4:25 PMbrief-egg-61061
08/20/2025, 4:26 PM<http://ory.sh/kratos|ory.sh/kratos>
JSON Schema extensions. The identity schema extensions documented are for password, WebAuthn, code, and other credential types, but there is no mention of an OIDC-specific identifier configuration in the schema. OIDC credentials and their identifiers (such as the OIDC subject) are managed by Ory Kratos during the OIDC authentication process, not through the identity schema itself [Customize identity schemas](https://www.ory.sh/docs/kratos/manage-identities/customize-identity-schema#identity-schema-extensions) [Credentials](https://www.ory.sh/docs/kratos/concepts/credentials). If you want an identity to be OIDC-only, you should not mark any trait as a password identifier in your schema and ensure that only OIDC authentication is enabled. However, the actual OIDC identifier (the subject from the OIDC provider) is not set in the identity schema but is handled by Ory during the OIDC login flow. Summary: - There is no way to set an OIDC-only identifier directly in the identity schema. - OIDC identifiers are managed by Ory during the OIDC authentication process, not via the schema. If you need to restrict authentication to OIDC only, configure your flows and schema to not support password or other credential types, but the identifier itself is not schema-configurable for OIDC.loud-car-47842
08/20/2025, 4:26 PMbrief-egg-61061
08/20/2025, 4:26 PMbrief-egg-61061
08/20/2025, 4:27 PMid
field). Every identity created in Ory Kratos is assigned a unique internal identifier (id
), which is a UUID generated by the system and cannot be changed or omitted. This internal identifier is always present and is used by Ory Kratos to reference and manage identities internally [Identity model](https://www.ory.sh/docs/kratos/manage-identities/overview). If you are referring to login identifiers (such as email, username, etc.), those are defined in your identity schema and can be customized, but the internal Kratos id
is always required and automatically set by the system.loud-car-47842
09/03/2025, 5:26 AMchilly-king-10285
09/03/2025, 5:26 AMchilly-king-10285
09/03/2025, 5:26 AMloud-car-47842
09/03/2025, 5:27 AMchilly-king-10285
09/03/2025, 5:27 AMchilly-king-10285
09/03/2025, 5:27 AMloud-car-47842
09/03/2025, 5:28 AMchilly-king-10285
09/03/2025, 5:28 AMchilly-king-10285
09/03/2025, 5:29 AMloud-car-47842
09/03/2025, 5:30 AMchilly-king-10285
09/03/2025, 5:30 AMchilly-king-10285
09/03/2025, 5:30 AMloud-car-47842
09/03/2025, 7:14 AMchilly-king-10285
09/03/2025, 7:14 AMchilly-king-10285
09/03/2025, 7:14 AMloud-car-47842
09/03/2025, 8:22 AMchilly-king-10285
09/03/2025, 8:22 AMchilly-king-10285
09/03/2025, 8:22 AMloud-car-47842
09/03/2025, 8:24 AMchilly-king-10285
09/03/2025, 8:24 AMchilly-king-10285
09/03/2025, 8:24 AMloud-car-47842
09/03/2025, 8:25 AMchilly-king-10285
09/03/2025, 8:25 AMchilly-king-10285
09/03/2025, 8:25 AMloud-car-47842
09/08/2025, 2:48 AMchilly-king-10285
09/08/2025, 2:49 AMchilly-king-10285
09/08/2025, 2:49 AM