Posted by & filed under Docker.

SAML 2.0 Identity Provider (IdP) as plug and play Docker container for development and testing

I recently had to add SAML 2.0 authentication to a web application. I had to connect a web application which acted as SAML Service Provider (SP) with an external SAML Identity Provider (IdP). The topic SAML is not trivial and full of crypto terminology. Some time ago there were online test resources like the Feide OpenIdP. However there test IdP has been shut down and i could not find an equivalent.

After going down the path of setting up an SAML IdP i decided to put the know how into a Docker container. The container is based on the official PHP7 Apache image.

If you encounter a similar task, you are welcome to use my Docker container.

Run the container:

docker run --name=some-test-saml-idp \
-p 8080:80 \
-p 8443:443 \
-e SIMPLESAMLPHP_SP_ENTITY_ID=http://app.example.com \
-e SIMPLESAMLPHP_SP_ASSERTION_CONSUMER_SERVICE=http://localhost/simplesaml/module.php/saml/sp/saml2-acs.php/test-sp \
-e SIMPLESAMLPHP_SP_SINGLE_LOGOUT_SERVICE=http://localhost/simplesaml/module.php/saml/sp/saml2-logout.php/test-sp \
-d kristophjunge/test-saml-idp

Leave a Reply

  • (will not be published)