Skip to main content

SAML with CyberArk

Keycloak supports multiple authentication realms, so you must first select the appropriate realm for your organisation. Do not make any of the below changes in the Keycloak/master realm.

In this example our realm is called "Acme" and Keycloak is hosted at https://auth.example.com/.

Our Knocknoc instance is a cloud instance with URL https://keycloaktest.knoc.cloud. If you are using a cloud server, replace with your own URL, or if you are using an on-premise server, this is the base URL to your Knocknoc server.

Knocknoc SAML config

SamlMetadataFile the idp-metadata.xml downloaded in the Mellon package from Keycloak

SamlKeyFile and SamlCertFile are currently required fields in Knocknoc but unused once you turn off Keycloak > Client > Keys >  "Client signature required"

So if we do a "choose SAML" provider option for Keycloak maybe these could be omitted or not mandatory

Keycloak config

  • Change to your realm (e.g. Acme, not master)
  • Create client
  • Settings tab
  • Keys tab
    • Client signature required: off
    • Encrypt assertions: off
  • Roles tab: -
  • Client scopes tab:
    • realName
      • Mapper type: user attribute
      • name: realName
      • User attribute: select the user attribute containing their name
      • Friendly name: realName
      • SAML attribute name: realName
    • nameid
      • Mapper type: User attribute mapper for NameID
      • name: nameid
      • Name ID format: urn:oasis:names:tc:SAML:2.0:nameid-format:persistent
      • User attribute: email
    • sessionDuration
      • Mapper type: user attribute
      • Name: sessionDuration
      • User attribute: select the user attribute containing the Knocknoc session duration in seconds
  • Advanced tab
    • Browser flow: browser
    • Authentication flow overrides