@@ -14,7 +14,7 @@ First you need to install apache and composer
1414
1515``` shell
1616sudo apt-get update
17- sudo apt-get install apache2 curl php-cli git
17+ sudo apt-get install apache2 curl php-cli php-json php-xml git
1818php -r " copy('https://getcomposer.org/installer', '/tmp/composer-setup.php');"
1919sudo php /tmp/composer-setup.php --install-dir=/usr/local/bin --filename=composer
2020```
@@ -55,18 +55,26 @@ tar -zxvf simple-oidc-client-php-X.Y.Z.tar.gz
5555
5656## Simple OIDC Client - authentication
5757
58- Now that we have everything we need, we can configure our login settings in
58+ Now that you have everything you need, you can configure your login settings in
5959` config.php ` .
60+ First, copy the configuration file, using the command:
61+
62+ ``` shell
63+ cp example-config.php config.php
64+ ```
65+
66+ Then open the file and configure the portal.
6067
6168``` php
6269<?php
6370
6471// index.php interface configuration
6572$title = "Generate Tokens";
66- $img = "https://clickhelp.co/images/feeds/blog/2016.05/keys.jpg ";
73+ $img = "https://www.pngkey.com/png/detail/233-2332677_image-500580-placeholder-transparent.png ";
6774$scopeInfo = "This service requires the following permissions for your account:";
75+
6876// Client configuration
69- $issuer = "https://example.com/oidc/ ";
77+ $issuer = "https://example.com/auth/realms/rciam ";
7078$clientId = "some-client-id";
7179$clientSecret = "some-client-secret"; // comment if you are using PKCE
7280// $pkceCodeChallengeMethod = "S256"; // uncomment to use PKCE
@@ -82,11 +90,15 @@ $scopesDefine = array(
8290$refreshTokenNote = "NOTE: New refresh tokens expire in 12 months.";
8391$accessTokenNote = "NOTE: New access tokens expire in 1 hour.";
8492$manageTokenNote = "You can manage your refresh tokens in the following link: ";
85- $manageTokens = $issuer . "manage/user/services ";
86- $sessionName = "oidc-client";
93+ $manageTokens = $issuer . "/account/#/applications ";
94+ $sessionName = "simple- oidc-client-php"; // This value must be the same with the name of the parent directory
8795$sessionLifetime = 60 * 60; // must be equal to access token validation time in seconds
96+ $bannerText = "";
97+ $bannerType = "info"; // Select one of "info", "warning", "error" or "success"
8898$allowIntrospection = false;
89- $enableActiveTokensTable = false;
99+ $enableActiveTokensTable = false; // This option works only for MITREid Connect based OPs
100+ $showIdToken = false;
101+
90102```
91103
92104Let’s go quickly through the settings:
@@ -95,9 +107,10 @@ Let’s go quickly through the settings:
95107- ` img ` required, is the source of the logo
96108- ` scopeInfo ` optional, is a message that informs the user for the application
97109 requirements
98- - ` issuer ` required, is the base URL of our IdentityServer instance. This will
99- allow oidc-client to query the metadata endpoint so it can validate the tokens
100- - ` clientId ` required, is the id of the client we want to use when hitting the
110+ - ` issuer ` required, is the base URL of your OpenID Provider instance. This
111+ will allow oidc-client to query the metadata endpoint so it can validate the
112+ tokens
113+ - ` clientId ` required, is the id of the client you want to use when hitting the
101114 authorization endpoint
102115- ` clientSecret ` optional, a value the offers better security to the message
103116 flow
@@ -117,7 +130,8 @@ Let’s go quickly through the settings:
117130- ` manageTokenNote ` optional, message the informs the user where can manage
118131 his tokens
119132- ` manageTokens ` optional, URL of the manage tokens service
120- - ` sessionName ` required, define the name of the cookie session
133+ - ` sessionName ` required, define the name of the cookie session. The value must
134+ be the same with the name of the parent directory
121135- ` sessionLifetime ` required, define the duration of the session. This must be
122136 equal to the validity time of the access token.
123137- ` bannerText ` optional, the text that the banner will contain.
@@ -129,4 +143,7 @@ Let’s go quickly through the settings:
129143 - ` warning `
130144- ` allowIntrospection ` required, define to show/hide the introspection command
131145- ` enableActiveTokensTable ` required, define to show/hide the Active Refresh
132- Token table in ` refreshtoken.php `
146+ Token table in ` refreshtoken.php ` . Important note: This option works only for
147+ [ MITREid Connect] ( https://github.com/mitreid-connect/OpenID-Connect-Java-Spring-Server )
148+ based OPs!
149+ - ` showIdToken ` required, define to show/hide the ID Token from the dashboard
0 commit comments