Before you can install mod_auth_openidc, you need to have an Apache HTTPD server running with SSL enabled.
It is assumed that all the hostnames will be dns resolvable. If not, then add the entries in /etc/hosts file on both the web server and Gluu Server.
The SSL Module is necessary for the Apache OpenID Connect Module. Please use the following commands to activate the ssl module.
The next step is to create a self-signed SSL Certificate.
At this point, its a good time to test to make sure SSL and CGI are working. Point your browser at https://www.mydomain.com/cgi-bin/printHeaders.cgi You should see a list of current environment variables.
You'll also need the mod_auth_openidc and libjose packages which can be downloaded from the Releases Page.
Make a note of the client_secret (you won't get to see it again)! You'll also need the client_id for the next step.
This cgi-script makes for a good test page!
You are almost done! You'll need to configure mod_auth_openidc to protect your server.
The most confusing part here is the OIDCRedirectURI--don't set this to a path used by your server. The apache-filter uses the redirect_uri to process the response from the OpenID Provider (Gluu Server).
We assume that all the hostnames will be dns resolvable. If not, then add the according entries in /etc/hosts, please.
Run the following command to Add EPEL Repo.
If the hiredis package is not found by the yum command, please download it manually from this page and install it.
This section will guide you to create SSL certificates. Use the following commands to crete a directory and generate the certificates.
The next step is to configure Apache to use the certificates and use the following command to edit the ssl.conf file.
The important part of the configuration is to enter the path to the created SSL certificates. The example is given below.
Note: Please make sure to use the correct server name in the configuration file.
Restart Apache Server and you are done configuring the SSL Module. Use the command below to restart the Apache Server.
The latest package for the apache module might have multiple dependencies which must be installed first.
try to update the package database of your system using the command below.
The test page is made using the cgi-script. Please use the following command to create the script.
The client_secret should be noted after creating the client in Gluu Server as it is used later.
Please remember to populate the OIDCRedirectURI with a value that is not used by the server. The apache-filter uses the redirect_uri to process the response from the OpenID Provider (Gluu Server).