You are not logged in.
Hello Dear,
I am in the process of configuring GLPI authentication with Azure AD via the OAuth 2 plugin.
Azure AD is well linked to GLPi, OAuth2 configurations are also OK (client Id, client secret, callback, tenant id).
The problem is in the configuration of authorizations on Oauth. When I want to create a new authorization, I am redirected to Azure AD asking me to authenticate (email, password). Except that just after, instead of creating the authorization, I get an error on the GLPI side: Unable to save the authorization code.
and in the log here is what I find:
glpiphplog.WARNING: *** PHP User Warning (512): Unable to get user email in \ opt \ glpi \ plugins \ oauthimap \ inc \ authorization.class.php at line 222
Backtrace:
plugins / oauthimap / inc / authorization.class.php: 222 trigger_error ()
... s / oauthimap / front / authorization.callback.php: 50 PluginOauthimapAuthorization-> createFromCode ()
So impossible to finish configuring the plugin ...
Do you have a clue for me to correct this? or set it correctly?
For info: Ubuntu for OS and GLPI 9.5.3, Oauth IMAP plugin
HELP .. Thank you
Last edited by faycalO (2021-09-21 17:11:44)
Offline
Please Help
Offline
Hi,
I have the exact same error, did you solve your problem?
Thanks in advance
Offline
Hello Dear,
I am in the process of configuring GLPI authentication with Azure AD via the OAuth 2 plugin.
Azure AD is well linked to GLPi, OAuth2 configurations are also OK (client Id, client secret, callback, tenant id).
The problem is in the configuration of authorizations on Oauth. When I want to create a new authorization, I am redirected to Azure AD asking me to authenticate (email, password). Except that just after, instead of creating the authorization, I get an error on the GLPI side: Unable to save the authorization code.and in the log here is what I find:
glpiphplog.WARNING: *** PHP User Warning (512): Unable to get user email in \ opt \ glpi \ plugins \ oauthimap \ inc \ authorization.class.php at line 222
Backtrace:
plugins / oauthimap / inc / authorization.class.php: 222 trigger_error ()
... s / oauthimap / front / authorization.callback.php: 50 PluginOauthimapAuthorization-> createFromCode ()So impossible to finish configuring the plugin ...
Do you have a clue for me to correct this? or set it correctly?
For info: Ubuntu for OS and GLPI 9.5.3, Oauth IMAP pluginHELP .. Thank you
In GLPI when configuring the plugin (Oauth IMAP application) put the (customer value) that is informed in the Microsoft365 portal in the GLPI (customer secret) field, so you will be able to add authorization without worries.
We are available.
Offline
I'm having the same problem when using the plugin Oauth IMAP.
I have already entered Tenant ID, Client ID, Client Secret.
I also tried to enter the Client ID in Secret but the message below is still displayed.
Unable to save authorization code
Did you have any progress on this personal issue?
I would like our users to authenticate using Office 365 accounts
Last edited by mauricioasj (2022-06-29 23:45:13)
Offline
I solved this error changing the way the authentication of the application was registered at Azure AD.
Choose Web and paste the Redirect URL, given by GLPI Oauth plugin.
Offline
I'm a newbie and also have that similar issue but just have solved by myself. I'd recommend you to see the 'php-errors.log' file under '/var/www/glpi/files/_log' first. Then you would get a clue of which error might came from. Mostly my error cause from application registration settings on Azure side.
Offline
Tenant ID
Client ID
Client Secret
Everything perfect on the Azure side, this is simple as driving a bike, but after all , on the glpi side we always get the same bug error " Unable to save authorization code"
Offline
Hi, I have problems to use SMTP. I have installed the plugin Oauth for pop and IMap, but how to apply that to smtp too? Any idea?
Thank you!
Offline
I had the same issue, the client secret is really the secret value from app registration secret, now the authorization code was saved.
Offline