-
Notifications
You must be signed in to change notification settings - Fork 61
mod auth openidc setup authentication
MohitMaliFtechiz edited this page Dec 20, 2019
·
8 revisions
How to setup mod auth openidc setup authentication(https://github.com/zmartzone/mod_auth_openidc/wiki/Step-up-Authentication) with gluu server 4.0.
- Gluu Server 4.0.
- Web Server apache2.
- mod auth openidc
- Log in to oxtrust admin panel.
- navigate to open id connect
- on client section , click on add client.
- create a client by providing appropriate login redirect uri , scope , grant uri and response type.
- Note down client secret and client id.
- Login in to oxtrust admin panel.
- In Configuration section move to manage custom script.
- Enable and setup duo script by following the document (https://gluu.org/docs/ce/authn-guide/duo/)
Note Since we don't need duo as default authentication so don't enable under Configuration > Manage Authentication > Default Authentication Method.
We need to setup two authentication for two level of the site , suppose top level '/' only require password authentication while within site there is folder called '2fa' which required two factor authentication.
- vi /etc/apache2/sites-available/default-ssl.conf
OIDCProviderMetadataURL /.well-known/openid-configuration
OIDCClientID client id
OIDCClientSecret client secret
OIDCRedirectURI
OIDCResponseType code
OIDCScope "openid profile email"
OIDCSSLValidateServer Off
OIDCCryptoPassphrase test1
OIDCPassClaimsAs environment
OIDCClaimPrefix USERINFO_
OIDCPassIDTokenAs payload
<Location "/">
Require valid-user
AuthType openid-connect
</ Location>
<Location "/2fa/">
AuthType openid-connect
Require claim acr:duo
OIDCUnAutzAction auth
OIDCPathAuthRequestParams acr_values=duo
Require valid-user
</ Location>