Abyss — Identity Provider Federation

Abyss connects FerrisKey to external identity providers. Users can authenticate through Google, GitHub, Discord, or any custom OAuth2/OIDC provider — and FerrisKey handles the token exchange, user provisioning, account linking, and attribute mapping.

Why Federation?

Federation lets you meet users where they already have an identity. Instead of forcing users to create yet another account, let them sign in with their existing Google or corporate credentials. FerrisKey becomes the identity broker — normalizing different provider formats into a consistent internal model.

Supported Provider Types

TypeStatusExamples
OAuth2SupportedGoogle, GitHub, Discord, any OAuth2 provider
OIDCSupportedAny OpenID Connect compliant provider
SAMLPlannedEnterprise IdPs (Okta, Azure AD via SAML)
LDAPPlannedActive Directory, OpenLDAP

Provider Configuration

Each provider is registered per realm with full OAuth2/OIDC configuration:

FieldDescription
nameDisplay name shown on the login page
provider_typeoauth2 or oidc
client_idOAuth2 client ID from the external provider
client_secretOAuth2 client secret (encrypted in storage)
authorization_urlProvider’s authorization endpoint
token_urlProvider’s token endpoint
userinfo_urlProvider’s UserInfo endpoint (optional)
scopesOAuth2 scopes to request (e.g., openid, email, profile)
enabledToggle the provider on/off without deleting it
configurationProvider-specific JSON config (e.g., tenant ID for Azure AD)

Secret encryption

Client secrets are encrypted before storage. They are never exposed through the admin API in plaintext.

Provider Mappings

Provider mappings define how external attributes map to internal FerrisKey user fields:

External FieldInternal FieldRequired
emailemailYes
sub— (used for linking)Yes
preferred_usernameusernameNo
given_namefirstnameNo
family_namelastnameNo

Each mapping specifies whether it’s required — if a required mapping is missing from the provider’s response, the federation flow fails.

Real-World Patterns

”Sign in with Google” for a SaaS Product

Configure a Google OAuth2 provider with scopes openid email profile. Users click “Sign in with Google”, authenticate at Google, and are redirected back to your app with FerrisKey tokens. New users are automatically provisioned.

Corporate SSO with Azure AD

Configure an OIDC provider pointing to your Azure AD tenant’s endpoints. Employees authenticate through their corporate identity and get FerrisKey tokens scoped to the correct realm.

Multi-Provider Login

Configure Google, GitHub, and Discord as providers on the same realm. Users choose their preferred provider on the login page. All three paths converge into the same FerrisKey user model with unified roles and permissions.

Account Linking

A user who first authenticated with Google can later link their GitHub account. Both external identities map to the same FerrisKey user, each tracked by a separate federated credential.