Dokumentation

Sign in through your identity provider

People sign in through the customer's own identity provider, by OpenID Connect or SAML 2.0, directly and without a third party. SCIM 2.0 adds and removes them as the directory changes.

An installation connects to the customer's identity provider directly: Entra ID, Okta, ADFS, Keycloak, Google or any other that speaks OpenID Connect or SAML 2.0. Nothing sits in between, so sign-in also works when the identity provider is inside the customer's network.

Each organization has its own connection, set in the installation file under organizations[].sso. Apply the file again from Settings → Installation file after you change it.

OpenID Connect

In the identity provider, create a client for CoRoid:

  • Client type: confidential, with the authorization code flow.
  • Redirect URI: the portal address followed by /api/auth/sso/callback, for example https://coroid.example.com/api/auth/sso/callback.
  • Scopes: openid, email and profile.

Then add it to the organization in the installation file:

"sso": {
  "oidc": {
    "issuer": "https://sso.acme.example/realms/acme",
    "clientId": "coroid",
    "clientSecret": { "secret": "file:/etc/coroid/secrets/acme-oidc" },
    "mfaAcrValues": ["mfa"]
  },
  "domains": ["acme.example"],
  "required": true
}
  • issuer: exactly as the provider's tokens name it. For Keycloak, that is https://<host>/realms/<realm>.
  • domains: the email domains whose people sign in here. Each domain belongs to one organization.
  • required: those people may sign in only here, never with a password.
  • mfaAcrValues: the acr values with which the provider says the sign-in had a second factor.

SAML 2.0

In the identity provider, create a SAML client for CoRoid:

  • Assertion consumer service: the portal address followed by /api/auth/sso/saml/acs.
  • Signed assertions, carrying the email address as an email attribute or as the name id in the email format.

Then, in the installation file:

"sso": {
  "saml": {
    "entryPoint": "https://sso.acme.example/realms/acme/protocol/saml",
    "certificates": ["file:/etc/coroid/sso/acme-idp.pem"],
    "mfaAuthnContexts": []
  },
  "domains": ["acme.example"],
  "required": true
}
  • entryPoint: the provider's sign-in address (HTTP-Redirect binding).
  • certificates: the provider's signing certificates, as PEM files on the server.

CoRoid's own metadata, with its entity id, is at the portal address followed by /api/auth/sso/saml/metadata/<connection>. Applying the file creates the connection. A sign-in the identity provider starts on its own is refused: people start at CoRoid's sign-in page.

A second factor

With mfaRequired in the file, a sign-in through the identity provider counts as one with a second factor only when the provider says so: an acr value in mfaAcrValues, or an authentication context in mfaAuthnContexts. Otherwise CoRoid asks for its own second factor right after the sign-in.

SCIM 2.0: people who join and leave

With SCIM, the identity provider adds people to the organization and removes them when they leave. CoRoid dials out for none of it.

"sso": {
  "oidc": { "...": "as above" },
  "scim": {
    "token": { "secret": "file:/etc/coroid/secrets/acme-scim" },
    "authoritative": true
  },
  "domains": ["acme.example"],
  "required": true
}
  • token: a long random value, at least 32 characters. The identity provider sends it with each call. CoRoid keeps only its hash.
  • authoritative: only the people the directory pushed may sign in.

When you apply the file, it shows the SCIM address for the organization, in the form <API address>/scim/v2/<directory id>. Give that address and the token to the identity provider. People join as members; groups are not offered yet.

Check it

  1. Sign out, and sign in with an address in one of the domains: the portal sends you to the identity provider and back.
  2. With SCIM, add a test person in the directory and see them appear under the organization's members; remove them and see them lose access.

Next: Upgrades.