Healthstat SimpleSAML error: Unable to load certificate

Last updated: 2023-11-06 14:25

Symptoms

A user tries to log in to a Healthstat environment. During the login process they authenticate using Itsme, eID, pasword + MFA, ... and after doing so they get redirected to Healthstat to finish the authentication flow. However, Healthstat does not complete the authentication flow succesfully: instead it throws the following error.

SimpleSAML\Error\Error: UNHANDLEDEXCEPTION
[...]
Caused by: Exception: saml20-idp-remote/'https://sso-acc.healthdata.be/auth/realms/healthstat': Unable to load certificate/public key from file [...]
Healthstat SimpleSAML error: Unable to load certificate/public key from file

Root cause

During the authentication flow, Healthstat needs a certificate. The above error suggests that one of the following are not correct:

  • The path to that certificate file
  • The certificate file's permissions
  • The content of the file (it should be a valid public certificate, e.g. you can verify this by executing $ openssl x509 -in $PATHTOCERTIFICATE -noout -text;)

Solutions

Go into the pods of the Healthstat environment and verify the root cause. If that is indeed the root cause, then contact DevOps to deploy a fix.