
Bonjour, Pour mieux comprendre mon problème, voici les informations à ma disposition : log Galette et configuration. J'ai un peu trafiqué les mots de passe et autres chaines de caractères d'identification. Merci pour votre aide, Pierre *Configuration plugin * global: password: sOlCzE88GJmMw5y galette_nc: title: 'nextcloud' redirect_logout: 'https://cloud.onzecplus.org' authorize: uptodate scopes: - member *Log d'une connexion* 10.0.20.101 - 2025-01-15 07:48:47 - DEBUG - Trying to set locale to fr_FR 10.0.20.101 - 2025-01-15 07:48:48 - DEBUG - Redirect to /webroot/plugins/oauth2/login?redirect_url=%2Fwebroot%2Fplugins%2Foauth2%2Fauthorize%3Fresponse_type%3Dcode%26client_id%3Dgalette_nc%26redirect_uri%3Dhttps%253A%252F%252Fcloud.onzecplus.org%252Findex.php%252Fapps%252Fsociallogin%252Fcustom_oauth2%252Fg%26scope%3D%26state%3DHA-W6B1D48IJTEKH0Z23PNV9YORL7C 10.0.20.101 - 2025-01-15 07:48:48 - DEBUG - login() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/login?redirect_url=%... GET dump: Array ( [redirect_url] => /webroot/plugins/oauth2/authorize?response_type=code&client_id=galette_nc&redirect_uri=https%3A%2F%2Fcloud.onzecplus.org%2Findex.php%2Fapps%2Fsociallogin%2Fcustom_oauth2%2Fg&scope=&state=HA-W6B1D48IJTEKH0Z23PNV9YORL7C ] 10.0.20.103 - 2025-01-15 07:48:53 - DEBUG - login() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/login POST dump: Array ( [login] => pattar [password] => HIDDEN [ident] => 1 [csrf_name] => csrf67876860334c4 [csrf_value] => cSp1kU7HOT3FIPenrLNxnDy+jr/rlk3ek8H8dtlWvQZFSECgev8JDvwUwJLNhkX6Xdu2i96mLL2m+ZoQ72OOMQ== ] 10.0.20.103 - 2025-01-15 07:48:53 - INFO - User `pattar` logged in. 10.0.20.103 - 2025-01-15 07:48:53 - DEBUG - Trying to set locale to fr_FR 10.0.20.103 - 2025-01-15 07:48:53 - DEBUG - UserHelper::login(pattar) return '2' 10.0.20.103 - 2025-01-15 07:48:53 - DEBUG - Scopes: member 10.0.20.103 - 2025-01-15 07:48:53 - DEBUG - Old Temporary passwords have been deleted. 10.0.20.105 - 2025-01-15 07:48:55 - DEBUG - authorization/authorize() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/authorize?response_t... GET dump: Array ( [response_type] => code [client_id] => galette_nc [scope] => [state] => HA-W6B1D48IJTEKH0Z23PNV9YORL7C [redirect_uri] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g ] 10.0.20.105 - 2025-01-15 07:48:55 - DEBUG - Auto add redirect_uri to cache oauth2_galette_nc.redirect_uri.txt: https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g 10.0.20.105 - 2025-01-15 07:48:55 - DEBUG - Auto add redirect_uri ok. 10.0.20.105 - 2025-01-15 07:48:55 - DEBUG - getClientEntity() GaletteOAuth2\Entities\ClientEntity Object ( [identifier:protected] => galette_nc [name:protected] => galette_nc [redirectUri:protected] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [isConfidential:protected] => 1 ] 10.0.20.105 - 2025-01-15 07:48:55 - DEBUG - Scopes: member 10.0.20.102 - 2025-01-15 07:49:02 - DEBUG - authorization/doAuthorize() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/authorize?response_t... GET dump: Array ( [response_type] => code [client_id] => galette_nc [scope] => [state] => HA-W6B1D48IJTEKH0Z23PNV9YORL7C [redirect_uri] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g ] POST dump: Array ( [csrf_name] => csrf67876860334c4 [csrf_value] => a4nxuGWX6adMYRXAk25Jh2vTO7ER7PsbEAAWBA809hBf68SJUa/ZlHVVIvXyW33hCrYDhSTcmnglOHBiOQHFJw== [approve] => ] 10.0.20.102 - 2025-01-15 07:49:02 - DEBUG - getClientEntity() GaletteOAuth2\Entities\ClientEntity Object ( [identifier:protected] => galette_nc [name:protected] => galette_nc [redirectUri:protected] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [isConfidential:protected] => 1 ] 10.0.20.102 - 2025-01-15 07:49:02 - DEBUG - Scopes: member 10.0.20.102 - 2025-01-15 07:49:02 - DEBUG - authorization/doAuthorize() exit ok 10.0.20.103 - 2025-01-15 07:49:06 - DEBUG - Trying to set locale to en_US 10.0.20.103 - 2025-01-15 07:49:07 - DEBUG - authorization/token() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/access_token POST dump: Array ( [client_id] => galette_nc [client_secret] => sOlCzE88GJmMw5y [grant_type] => authorization_code [redirect_uri] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [code] => def50200d5cff5019d4ddcbb651e580590a53347ced76c9f3c1125ad3252b49c1b459205522fd6b7f094670a53fc92e55fe4f1ff728b7f1b0ffc8ec423b59f330b77291efbec4689a7c89c7ccfbaec67ac3fd337d6932196a81e04609f031ee371635459feb104a153039177ab60f3cc5149287a6f7dec112c429c71f5260a04ea2c9743e589f9ae8eea371bf03b076c4653e6e09dd5c0862cbdbb707ce62405080243ad8cd693eadabd4c7981a56516f119f2aa8629c9b609d77eb72ae983c9025b70490143886731ca3c94e1bdf3da4a7a199bd1af3e75b3ef945be08426307a4334bc1ffee07814248bc146cb12479bdf296f9a8a011f72c447e193f2f9a1403a1e3a991e74275261c85efca1a8c569e07f30cf93e61309d51494456c9ea1c729094e3894057e9c03616a4fa78a05c56d627502576dc2f342137b8b0de9cfedad8ac19aa0b072b55d29e885bf0dde15539fecc183ae41007d35aee193f3442e7c160bd52d8f5a7bf2a55b4eb680525151669e8252bdd91e1bfe97272abf09c469a369f7cafa6c41883764650ba121df038c ] 10.0.20.103 - 2025-01-15 07:49:07 - DEBUG - getClientEntity() GaletteOAuth2\Entities\ClientEntity Object ( [identifier:protected] => galette_nc [name:protected] => galette_nc [redirectUri:protected] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [isConfidential:protected] => 1 ] 10.0.20.103 - 2025-01-15 07:49:07 - DEBUG - getClientEntity() GaletteOAuth2\Entities\ClientEntity Object ( [identifier:protected] => galette_nc [name:protected] => galette_nc [redirectUri:protected] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [isConfidential:protected] => 1 ] 10.0.20.103 - 2025-01-15 07:49:07 - DEBUG - authorization/token() exit ok 10.0.20.106 - 2025-01-15 07:49:08 - DEBUG - Trying to set locale to en_US 10.0.20.106 - 2025-01-15 07:49:08 - DEBUG - api/user() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/user Le 14/01/2025 à 14:04, Johan Cwiklinski a écrit :
Salut,
Le 14/01/2025 à 12:33, Pierre Attar a écrit :
Bonjour,
J'essaye de mettre en place le plugin oauth pour l'utiliser sur nextcloud.
Dans un premier temps, j'ai un truc étrange sous galette avec une approbation d'un scope vide. [...]
Je pense que c'est un problème de configuration, il faudrait voir comment est configuré le plugin.
Si je le déselectionne, il semble que galette soit content (pas de message d'erreur dans le log), mais je me retrouve avec ce message dans nextcloud qui semble dire que cela n'a pas fonctionné. [...]
Il devrait y avoir davantage d'informations dans les logs côté Galette.
PS: pour un nouveau sujet, merci de ne pas répondre à un sujet existant.
++

Salut, Le 15/01/2025 à 11:19, Pierre Attar a écrit :
Bonjour,
Pour mieux comprendre mon problème, voici les informations à ma disposition : log Galette et configuration. J'ai un peu trafiqué les mots de passe et autres chaines de caractères d'identification.
Merci pour votre aide,
Pierre
*Configuration plugin * [...]
Tout semble OK à première vue dans le fichier de configuration. Concernant l'erreur à l'authentification rien n'évoque une erreur fatale dans les logs transmis. N'ayant pas de nextcloud, je ne peux pas tester. Avec Flarum, ça fonctionnait lors de mon premier essai. En cherchant un peu, je me suis rendu compte que j'obtiens un scope vide si aucun n'est précisé du côté de la configuration de Flarum (OAuth scopes to request). Peut-être que le souci vient de là, le contournement consisterait juste à déclarer le(s) scope(s) attendu(s) du côté de la configuration Nexcloud en attendant que ce soit corrigé côté plugin. À voir si ça corrige tous les problèmes - ou pas. ++ -- Johan

Salut, Le 16/01/2025 à 20:24, Johan Cwiklinski a écrit :
Avec Flarum, ça fonctionnait lors de mon premier essai. En cherchant un peu, je me suis rendu compte que j'obtiens un scope vide si aucun n'est précisé du côté de la configuration de Flarum (OAuth scopes to request). [...]
Le correctif : https://github.com/galette-community/plugin-oauth2/pull/23/commits/b92dccf4b... ++ -- Johan

Hello Johan, J'ai installé le correctif et cela ne fonctionne toujours pas. Le message semble dire que l'erreur est du côté de "Slim" et donc on aurait une erreur non identifiée par le plugin Galette et qui retournerait directement et telle quelle à NextCloud. Signed API request to https://galette.onzecplus.org/webroot/plugins/oauth2/user has returned an error. HTTP error 500. Raw Provider API response: <!doctype html><html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>Slim Application Error</title> <style> body{margin:0;padding:30px;font:12px/1.5 Helvetica,Arial,Verdana,sans-serif} h1{margin:0;font-size:48px;font-weight:normal;line-height:48px} strong{display:inline-block;width:65px} </style> </head> <body> <h1>Slim Application Error</h1> <div><p>A website error has occurred. Sorry for the temporary inconvenience.</p></div> <a href="#" onclick="window.history.go(-1)">Go Back</a> </body></html>. Si nécessaire, on peut décider de trouver un temps pour tester cela ensemble. Je n'ai pas ailleurs pas trop de soucis pour paramétrer une instance nextcloud de façon limitée dans le temps pour qu'il utilise un de tes serveurs de tests et que tu puisses débugger. Merci pour ton aide, Pierre PS: ensuite, je me lance dans l'utilisation de ce plugin avec Wordpress ;) Le 16/01/2025 à 21:16, Johan Cwiklinski a écrit :
Salut,
Le 16/01/2025 à 20:24, Johan Cwiklinski a écrit :
Avec Flarum, ça fonctionnait lors de mon premier essai. En cherchant un peu, je me suis rendu compte que j'obtiens un scope vide si aucun n'est précisé du côté de la configuration de Flarum (OAuth scopes to request). [...]
Le correctif : https://github.com/galette-community/plugin-oauth2/pull/23/commits/b92dccf4b...
++

Salut, Le 17/01/2025 à 23:15, Pierre Attar a écrit :
[...] Signed API request to https://galette.onzecplus.org/webroot/plugins/ oauth2/user has returned an error. HTTP error 500. Raw Provider API response: <!doctype html><html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>Slim Application Error</title> <style> body{margin:0;padding:30px;font:12px/1.5 Helvetica,Arial,Verdana,sans- serif} h1{margin:0;font-size:48px;font-weight:normal;line-height:48px} strong{display:inline-block;width:65px} </style> </head> <body> <h1>Slim Application Error</h1> <div><p>A website error has occurred. Sorry for the temporary inconvenience.</p></div> <a href="#" onclick="window.history.go(-1)">Go Back</a> </body></html>.
Normalement, il devrait y avoir une entrée dans les logs pour cette erreur. Il faut peut-être activer le mode debug de Galette. ++ -- Johan

Hello, Je ne connaissais pas le mode debug. du coup, il est activé mais j'ai l'impression qu'il n'y a pas beaucoup plus d'info dans le log (voir ci-dessous). En revanche, le message de retour affiché dans nextcloud donne une trace qui pourrait peut-être t'aider : <!doctype html><html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>Slim Application Error</title> <style> body{margin:0;padding:30px;font:12px/1.5 Helvetica,Arial,Verdana,sans-serif} h1{margin:0;font-size:48px;font-weight:normal;line-height:48px} strong{display:inline-block;width:65px} </style> </head> <body> <h1>Slim Application Error</h1> <div><p>The application could not run because of the following error:</p><h2>Details</h2><div><strong>Type:</strong> League\OAuth2\Server\Exception\OAuthServerException</div><div><strong>Code:</strong> 9</div><div><strong>Message:</strong> The resource owner or authorization server denied the request.</div><div><strong>File:</strong> /var/www/vhosts/galette.onzecplus.org/httpdocs/plugins/oauth2/vendor/league/oauth2-server/src/Exception/OAuthServerException.php</div><div><strong>Line:</strong> 243</div><h2>Trace</h2><pre>#0 /var/www/vhosts/galette.onzecplus.org/httpdocs/plugins/oauth2/vendor/league/oauth2-server/src/AuthorizationValidators/BearerTokenValidator.php(101): League\OAuth2\Server\Exception\OAuthServerException::accessDenied() #1 /var/www/vhosts/galette.onzecplus.org/httpdocs/plugins/oauth2/vendor/league/oauth2-server/src/ResourceServer.php(84): League\OAuth2\Server\AuthorizationValidators\BearerTokenValidator->validateAuthorization() #2 /var/www/vhosts/galette.onzecplus.org/httpdocs/plugins/oauth2/lib/GaletteOAuth2/Controllers/ApiController.php(73): League\OAuth2\Server\ResourceServer->validateAuthenticatedRequest() #3 [internal function]: GaletteOAuth2\Controllers\ApiController->user() #4 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/php-di/invoker/src/Invoker.php(74): call_user_func_array() #5 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/php-di/slim-bridge/src/ControllerInvoker.php(45): Invoker\Invoker->call() #6 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Routing/Route.php(363): DI\Bridge\Slim\ControllerInvoker->__invoke() #7 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(73): Slim\Routing\Route->handle() #8 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(73): Slim\MiddlewareDispatcher->handle() #9 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Routing/Route.php(321): Slim\MiddlewareDispatcher->handle() #10 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Routing/RouteRunner.php(74): Slim\Routing\Route->run() #11 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/akrabat/rka-slim-session-middleware/RKA/SessionMiddleware.php(66): Slim\Routing\RouteRunner->handle() #12 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): RKA\SessionMiddleware->process() #13 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/csrf/src/Guard.php(482): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #14 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): Slim\Csrf\Guard->process() #15 /var/www/vhosts/galette.onzecplus.org/httpdocs/lib/Galette/Middleware/Language.php(68): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #16 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(177): Galette\Middleware\Language->__invoke() #17 /var/www/vhosts/galette.onzecplus.org/httpdocs/lib/Galette/Middleware/Telemetry.php(69): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #18 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(177): Galette\Middleware\Telemetry->__invoke() #19 /var/www/vhosts/galette.onzecplus.org/httpdocs/includes/main.inc.php(177): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #20 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(280): Closure->{closure}() #21 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Middleware/RoutingMiddleware.php(45): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #22 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): Slim\Middleware\RoutingMiddleware->process() #23 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Middleware/ErrorMiddleware.php(77): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #24 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): Slim\Middleware\ErrorMiddleware->process() #25 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/twig-view/src/TwigMiddleware.php(117): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #26 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): Slim\Views\TwigMiddleware->process() #27 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(73): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #28 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/App.php(209): Slim\MiddlewareDispatcher->handle() #29 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/App.php(193): Slim\App->handle() #30 /var/www/vhosts/galette.onzecplus.org/httpdocs/includes/main.inc.php(209): Slim\App->run() #31 /var/www/vhosts/galette.onzecplus.org/httpdocs/webroot/index.php(50): require_once('...') #32 {main}</pre></div> <a href="#" onclick="window.history.go(-1)">Go Back</a> </body></html>. Merci, Pierre Le log : 10.0.20.105 - 2025-01-18 08:21:44 - INFO - Database version not checked in DEV mode. 10.0.20.105 - 2025-01-18 08:21:44 - DEBUG - Redirect to /webroot/plugins/oauth2/login?redirect_url=%2Fwebroot%2Fplugins%2Foauth2%2Fauthorize%3Fresponse_type%3Dcode%26client_id%3Dgalette_nc%26redirect_uri%3Dhttps%253A%252F%252Fcloud.onzecplus.org%252Findex.php%252Fapps%252Fsociallogin%252Fcustom_oauth2%252Fg%26scope%3Dmember%26state%3DHA-6WLQAXT9UY0SBVZOG83H4IKCF1D25 10.0.20.106 - 2025-01-18 08:21:44 - INFO - Database version not checked in DEV mode. 10.0.20.106 - 2025-01-18 08:21:45 - DEBUG - login() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/login?redirect_url=%... GET dump: Array ( [redirect_url] => /webroot/plugins/oauth2/authorize?response_type=code&client_id=galette_nc&redirect_uri=https%3A%2F%2Fcloud.onzecplus.org%2Findex.php%2Fapps%2Fsociallogin%2Fcustom_oauth2%2Fg&scope=member&state=HA-6WLQAXT9UY0SBVZOG83H4IKCF1D25 ] 10.0.20.106 - 2025-01-18 08:21:45 - INFO - Database version not checked in DEV mode. 10.0.20.101 - 2025-01-18 08:21:45 - INFO - Database version not checked in DEV mode. 10.0.20.104 - 2025-01-18 08:22:08 - INFO - Database version not checked in DEV mode. 10.0.20.104 - 2025-01-18 08:22:09 - DEBUG - login() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/login POST dump: Array ( [login] => patttest [password] => HIDDEN [ident] => 1 [csrf_name] => csrf678b647fdc4e3 [csrf_value] => 8ehbaEM+4eYB9xfAyG2bl4CZdQZBTu23kbDe72YIFyFgDHBc/T6D66vsaAXP3J21I+ng7iMVB8AEQ== ] 10.0.20.104 - 2025-01-18 08:22:09 - INFO - User `patttest` logged in. 10.0.20.104 - 2025-01-18 08:22:09 - DEBUG - Trying to set locale to fr_FR 10.0.20.104 - 2025-01-18 08:22:09 - DEBUG - UserHelper::login(patttest) return '201' 10.0.20.104 - 2025-01-18 08:22:09 - DEBUG - Scopes: member 10.0.20.104 - 2025-01-18 08:22:09 - DEBUG - Old Temporary passwords have been deleted. 10.0.20.105 - 2025-01-18 08:22:09 - INFO - Database version not checked in DEV mode. 10.0.20.105 - 2025-01-18 08:22:09 - DEBUG - authorization/authorize() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/authorize?response_t... GET dump: Array ( [response_type] => code [client_id] => galette_nc [scope] => member [state] => HA-6WLQAXT9UY0SBVZOG83H4IKCF1D25 [redirect_uri] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g ] 10.0.20.105 - 2025-01-18 08:22:09 - DEBUG - Auto add redirect_uri to cache oauth2_galette_nc.redirect_uri.txt: https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g 10.0.20.105 - 2025-01-18 08:22:09 - DEBUG - Auto add redirect_uri ok. 10.0.20.105 - 2025-01-18 08:22:09 - DEBUG - getClientEntity() GaletteOAuth2\Entities\ClientEntity Object ( [identifier:protected] => galette_nc [name:protected] => galette_nc [redirectUri:protected] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [isConfidential:protected] => 1 ] 10.0.20.105 - 2025-01-18 08:22:09 - DEBUG - Scopes: member 10.0.20.102 - 2025-01-18 08:22:10 - INFO - Database version not checked in DEV mode. 10.0.20.101 - 2025-01-18 08:22:10 - INFO - Database version not checked in DEV mode. 10.0.20.101 - 2025-01-18 08:22:16 - INFO - Database version not checked in DEV mode. 10.0.20.101 - 2025-01-18 08:22:16 - DEBUG - authorization/doAuthorize() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/authorize?response_t... GET dump: Array ( [response_type] => code [client_id] => galette_nc [scope] => member [state] => HA-6WLQAXT9UY0SBVZOG83H4IKCF1D25 [redirect_uri] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g ] POST dump: Array ( [csrf_name] => csrf678b647fdc4e3 [csrf_value] => aTvvIvggUj0LHUHX1C8lFPTroGJN/StPfRQ+53ymyuzsrJePmTRAsxdLCW37FEndLJ1iETpbzgw== [approve] => ] 10.0.20.101 - 2025-01-18 08:22:16 - DEBUG - getClientEntity() GaletteOAuth2\Entities\ClientEntity Object ( [identifier:protected] => galette_nc [name:protected] => galette_nc [redirectUri:protected] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [isConfidential:protected] => 1 ] 10.0.20.101 - 2025-01-18 08:22:16 - DEBUG - Scopes: member 10.0.20.101 - 2025-01-18 08:22:16 - DEBUG - authorization/doAuthorize() exit ok 10.0.20.104 - 2025-01-18 08:22:17 - INFO - Database version not checked in DEV mode. 10.0.20.104 - 2025-01-18 08:22:17 - DEBUG - Trying to set locale to en_US 10.0.20.104 - 2025-01-18 08:22:17 - DEBUG - authorization/token() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/access_token POST dump: Array ( [client_id] => galette_nc [client_secret] => 23tqDsOlCzE88GJmMw5y [grant_type] => authorization_code [redirect_uri] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [code] => def502008c21c3b1b0143e7c45219442c5c9cb4d52f9b77c4657e2e0f793505716d82bcac5285c6f54af4dc06f4a9b9c5ca0245ed22a698ec73f8669994cce837ea5531cdc55be721b56eb428a14fb263c53f4c77c359fcf15ae34c4fba755ce1e875ac725a35e19cd3c3617d2b4da26f861279fdf3b337ee4e58431d83257689a7ab790294f3ebed03304fc4b5aba7783cbd7438c077f5a4ec00fbf69adc960b783a1eb515f1ceee6c2e86d93597866ae58c648b81cfab2fd166a0c3c07feaf87b7ce176bd7bfdc80ec9ec49be270a5a0fb5f0ec00a654ea974166f95e8a89d54f0015f58a962d9687e58b783b015c20ac12bcd422f98ce76d83b713577be66ff2d8e1796b511839c08775bab5fd69b5fdf30b2f472561316bc18826c28c11eb7e0c90d93f43ca57baece47a8d1ecb304b3df730844a49d2ac56acb2bc65e182080e6122f224bcb36b3b197f45eba1dbde8c320a934f02efbd817ad91ebe9035fd35cf612942db2731a0fb32fcea0b0e1a3d40ca079140d1e41c414d2b830514b1a7aeca1df9c6e40d82b03b32af7c4faa367ab ] 10.0.20.104 - 2025-01-18 08:22:17 - DEBUG - getClientEntity() GaletteOAuth2\Entities\ClientEntity Object ( [identifier:protected] => galette_nc [name:protected] => galette_nc [redirectUri:protected] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [isConfidential:protected] => 1 ] 10.0.20.104 - 2025-01-18 08:22:18 - DEBUG - getClientEntity() GaletteOAuth2\Entities\ClientEntity Object ( [identifier:protected] => galette_nc [name:protected] => galette_nc [redirectUri:protected] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [isConfidential:protected] => 1 ] 10.0.20.104 - 2025-01-18 08:22:18 - DEBUG - authorization/token() exit ok 10.0.20.106 - 2025-01-18 08:22:18 - INFO - Database version not checked in DEV mode. 10.0.20.106 - 2025-01-18 08:22:18 - DEBUG - Trying to set locale to en_US 10.0.20.106 - 2025-01-18 08:22:18 - DEBUG - api/user() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/user Le 18/01/2025 à 00:13, Johan Cwiklinski a écrit :
Salut,
Le 17/01/2025 à 23:15, Pierre Attar a écrit :
[...] Signed API request to https://galette.onzecplus.org/webroot/plugins/ oauth2/user has returned an error. HTTP error 500. Raw Provider API response: <!doctype html><html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>Slim Application Error</title> <style> body{margin:0;padding:30px;font:12px/1.5 Helvetica,Arial,Verdana,sans- serif} h1{margin:0;font-size:48px;font-weight:normal;line-height:48px} strong{display:inline-block;width:65px} </style> </head> <body> <h1>Slim Application Error</h1> <div><p>A website error has occurred. Sorry for the temporary inconvenience.</p></div> <a href="#" onclick="window.history.go(-1)">Go Back</a> </body></html>.
Normalement, il devrait y avoir une entrée dans les logs pour cette erreur. Il faut peut-être activer le mode debug de Galette.
++

Si cela peut aider, on remarquera que j'ai à peu près exactement le même problème avec Wordpress... la même réponse. A propos et pour aider de futurs utilisateurs qui souhaitent faire cette opération. Sur nextcloud, j'ai installé le plugin "*Social Login*". Sur Wordpress, le plugin "*OAuth Single Sign On - SSO (OAuth Client)"* Pierre Réponse WP : <!doctype html><html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>Slim Application Error</title> <style> body{margin:0;padding:30px;font:12px/1.5 Helvetica,Arial,Verdana,sans-serif} h1{margin:0;font-size:48px;font-weight:normal;line-height:48px} strong{display:inline-block;width:65px} </style> </head> <body> <h1>Slim Application Error</h1> <div><p>The application could not run because of the following error:</p><h2>Details</h2><div><strong>Type:</strong> League\\OAuth2\\Server\\Exception\\OAuthServerException</div><div><strong>Code:</strong> 9</div><div><strong>Message:</strong> The resource owner or authorization server denied the request.</div><div><strong>File:</strong> /var/www/vhosts/galette.onzecplus.org/httpdocs/plugins/oauth2/vendor/league/oauth2-server/src/Exception/OAuthServerException.php</div><div><strong>Line:</strong> 243</div><h2>Trace</h2><pre>#0 /var/www/vhosts/galette.onzecplus.org/httpdocs/plugins/oauth2/vendor/league/oauth2-server/src/AuthorizationValidators/BearerTokenValidator.php(101): League\\OAuth2\\Server\\Exception\\OAuthServerException::accessDenied() #1 /var/www/vhosts/galette.onzecplus.org/httpdocs/plugins/oauth2/vendor/league/oauth2-server/src/ResourceServer.php(84): League\\OAuth2\\Server\\AuthorizationValidators\\BearerTokenValidator->validateAuthorization() #2 /var/www/vhosts/galette.onzecplus.org/httpdocs/plugins/oauth2/lib/GaletteOAuth2/Controllers/ApiController.php(73): League\\OAuth2\\Server\\ResourceServer->validateAuthenticatedRequest() #3 [internal function]: GaletteOAuth2\\Controllers\\ApiController->user() #4 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/php-di/invoker/src/Invoker.php(74): call_user_func_array() #5 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/php-di/slim-bridge/src/ControllerInvoker.php(45): Invoker\\Invoker->call() #6 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Routing/Route.php(363): DI\\Bridge\\Slim\\ControllerInvoker->__invoke() #7 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(73): Slim\\Routing\\Route->handle() #8 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(73): Slim\\MiddlewareDispatcher->handle() #9 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Routing/Route.php(321): Slim\\MiddlewareDispatcher->handle() #10 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Routing/RouteRunner.php(74): Slim\\Routing\\Route->run() #11 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/akrabat/rka-slim-session-middleware/RKA/SessionMiddleware.php(66): Slim\\Routing\\RouteRunner->handle() #12 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): RKA\\SessionMiddleware->process() #13 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/csrf/src/Guard.php(482): Psr\\Http\\Server\\RequestHandlerInterface@anonymous->handle() #14 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): Slim\\Csrf\\Guard->process() #15 /var/www/vhosts/galette.onzecplus.org/httpdocs/lib/Galette/Middleware/Language.php(68): Psr\\Http\\Server\\RequestHandlerInterface@anonymous->handle() #16 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(177): Galette\\Middleware\\Language->__invoke() #17 /var/www/vhosts/galette.onzecplus.org/httpdocs/lib/Galette/Middleware/Telemetry.php(69): Psr\\Http\\Server\\RequestHandlerInterface@anonymous->handle() #18 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(177): Galette\\Middleware\\Telemetry->__invoke() #19 /var/www/vhosts/galette.onzecplus.org/httpdocs/includes/main.inc.php(177): Psr\\Http\\Server\\RequestHandlerInterface@anonymous->handle() #20 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(280): Closure->{closure}() #21 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Middleware/RoutingMiddleware.php(45): Psr\\Http\\Server\\RequestHandlerInterface@anonymous->handle() #22 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): Slim\\Middleware\\RoutingMiddleware->process() #23 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Middleware/ErrorMiddleware.php(77): Psr\\Http\\Server\\RequestHandlerInterface@anonymous->handle() #24 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): Slim\\Middleware\\ErrorMiddleware->process() #25 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/twig-view/src/TwigMiddleware.php(117): Psr\\Http\\Server\\RequestHandlerInterface@anonymous->handle() #26 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): Slim\\Views\\TwigMiddleware->process() #27 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(73): Psr\\Http\\Server\\RequestHandlerInterface@anonymous->handle() #28 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/App.php(209): Slim\\MiddlewareDispatcher->handle() #29 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/App.php(193): Slim\\App->handle() #30 /var/www/vhosts/galette.onzecplus.org/httpdocs/includes/main.inc.php(209): Slim\\App->run() #31 /var/www/vhosts/galette.onzecplus.org/httpdocs/webroot/index.php(50): require_once('...') #32 {main}</pre></div> <a href="#" onclick="window.history.go(-1)">Go Back</a> </body></html> Le 18/01/2025 à 09:28, Pierre Attar a écrit :
Hello,
Je ne connaissais pas le mode debug. du coup, il est activé mais j'ai l'impression qu'il n'y a pas beaucoup plus d'info dans le log (voir ci-dessous).
En revanche, le message de retour affiché dans nextcloud donne une trace qui pourrait peut-être t'aider :
<!doctype html><html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>Slim Application Error</title> <style> body{margin:0;padding:30px;font:12px/1.5 Helvetica,Arial,Verdana,sans-serif} h1{margin:0;font-size:48px;font-weight:normal;line-height:48px} strong{display:inline-block;width:65px} </style> </head> <body> <h1>Slim Application Error</h1> <div><p>The application could not run because of the following error:</p><h2>Details</h2><div><strong>Type:</strong> League\OAuth2\Server\Exception\OAuthServerException</div><div><strong>Code:</strong> 9</div><div><strong>Message:</strong> The resource owner or authorization server denied the request.</div><div><strong>File:</strong> /var/www/vhosts/galette.onzecplus.org/httpdocs/plugins/oauth2/vendor/league/oauth2-server/src/Exception/OAuthServerException.php</div><div><strong>Line:</strong> 243</div><h2>Trace</h2><pre>#0 /var/www/vhosts/galette.onzecplus.org/httpdocs/plugins/oauth2/vendor/league/oauth2-server/src/AuthorizationValidators/BearerTokenValidator.php(101): League\OAuth2\Server\Exception\OAuthServerException::accessDenied() #1 /var/www/vhosts/galette.onzecplus.org/httpdocs/plugins/oauth2/vendor/league/oauth2-server/src/ResourceServer.php(84): League\OAuth2\Server\AuthorizationValidators\BearerTokenValidator->validateAuthorization() #2 /var/www/vhosts/galette.onzecplus.org/httpdocs/plugins/oauth2/lib/GaletteOAuth2/Controllers/ApiController.php(73): League\OAuth2\Server\ResourceServer->validateAuthenticatedRequest() #3 [internal function]: GaletteOAuth2\Controllers\ApiController->user() #4 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/php-di/invoker/src/Invoker.php(74): call_user_func_array() #5 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/php-di/slim-bridge/src/ControllerInvoker.php(45): Invoker\Invoker->call() #6 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Routing/Route.php(363): DI\Bridge\Slim\ControllerInvoker->__invoke() #7 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(73): Slim\Routing\Route->handle() #8 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(73): Slim\MiddlewareDispatcher->handle() #9 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Routing/Route.php(321): Slim\MiddlewareDispatcher->handle() #10 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Routing/RouteRunner.php(74): Slim\Routing\Route->run() #11 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/akrabat/rka-slim-session-middleware/RKA/SessionMiddleware.php(66): Slim\Routing\RouteRunner->handle() #12 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): RKA\SessionMiddleware->process() #13 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/csrf/src/Guard.php(482): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #14 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): Slim\Csrf\Guard->process() #15 /var/www/vhosts/galette.onzecplus.org/httpdocs/lib/Galette/Middleware/Language.php(68): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #16 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(177): Galette\Middleware\Language->__invoke() #17 /var/www/vhosts/galette.onzecplus.org/httpdocs/lib/Galette/Middleware/Telemetry.php(69): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #18 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(177): Galette\Middleware\Telemetry->__invoke() #19 /var/www/vhosts/galette.onzecplus.org/httpdocs/includes/main.inc.php(177): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #20 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(280): Closure->{closure}() #21 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Middleware/RoutingMiddleware.php(45): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #22 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): Slim\Middleware\RoutingMiddleware->process() #23 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/Middleware/ErrorMiddleware.php(77): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #24 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): Slim\Middleware\ErrorMiddleware->process() #25 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/twig-view/src/TwigMiddleware.php(117): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #26 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): Slim\Views\TwigMiddleware->process() #27 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/MiddlewareDispatcher.php(73): Psr\Http\Server\RequestHandlerInterface@anonymous->handle() #28 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/App.php(209): Slim\MiddlewareDispatcher->handle() #29 /var/www/vhosts/galette.onzecplus.org/httpdocs/vendor/slim/slim/Slim/App.php(193): Slim\App->handle() #30 /var/www/vhosts/galette.onzecplus.org/httpdocs/includes/main.inc.php(209): Slim\App->run() #31 /var/www/vhosts/galette.onzecplus.org/httpdocs/webroot/index.php(50): require_once('...') #32 {main}</pre></div> <a href="#" onclick="window.history.go(-1)">Go Back</a> </body></html>.
Merci, Pierre
Le log :
10.0.20.105 - 2025-01-18 08:21:44 - INFO - Database version not checked in DEV mode. 10.0.20.105 - 2025-01-18 08:21:44 - DEBUG - Redirect to /webroot/plugins/oauth2/login?redirect_url=%2Fwebroot%2Fplugins%2Foauth2%2Fauthorize%3Fresponse_type%3Dcode%26client_id%3Dgalette_nc%26redirect_uri%3Dhttps%253A%252F%252Fcloud.onzecplus.org%252Findex.php%252Fapps%252Fsociallogin%252Fcustom_oauth2%252Fg%26scope%3Dmember%26state%3DHA-6WLQAXT9UY0SBVZOG83H4IKCF1D25 10.0.20.106 - 2025-01-18 08:21:44 - INFO - Database version not checked in DEV mode. 10.0.20.106 - 2025-01-18 08:21:45 - DEBUG - login() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/login?redirect_url=%... GET dump: Array ( [redirect_url] => /webroot/plugins/oauth2/authorize?response_type=code&client_id=galette_nc&redirect_uri=https%3A%2F%2Fcloud.onzecplus.org%2Findex.php%2Fapps%2Fsociallogin%2Fcustom_oauth2%2Fg&scope=member&state=HA-6WLQAXT9UY0SBVZOG83H4IKCF1D25 ]
10.0.20.106 - 2025-01-18 08:21:45 - INFO - Database version not checked in DEV mode. 10.0.20.101 - 2025-01-18 08:21:45 - INFO - Database version not checked in DEV mode. 10.0.20.104 - 2025-01-18 08:22:08 - INFO - Database version not checked in DEV mode. 10.0.20.104 - 2025-01-18 08:22:09 - DEBUG - login() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/login POST dump: Array ( [login] => patttest [password] => HIDDEN [ident] => 1 [csrf_name] => csrf678b647fdc4e3 [csrf_value] => 8ehbaEM+4eYB9xfAyG2bl4CZdQZBTu23kbDe72YIFyFgDHBc/T6D66vsaAXP3J21I+ng7iMVB8AEQ== ]
10.0.20.104 - 2025-01-18 08:22:09 - INFO - User `patttest` logged in. 10.0.20.104 - 2025-01-18 08:22:09 - DEBUG - Trying to set locale to fr_FR 10.0.20.104 - 2025-01-18 08:22:09 - DEBUG - UserHelper::login(patttest) return '201' 10.0.20.104 - 2025-01-18 08:22:09 - DEBUG - Scopes: member 10.0.20.104 - 2025-01-18 08:22:09 - DEBUG - Old Temporary passwords have been deleted. 10.0.20.105 - 2025-01-18 08:22:09 - INFO - Database version not checked in DEV mode. 10.0.20.105 - 2025-01-18 08:22:09 - DEBUG - authorization/authorize() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/authorize?response_t... GET dump: Array ( [response_type] => code [client_id] => galette_nc [scope] => member [state] => HA-6WLQAXT9UY0SBVZOG83H4IKCF1D25 [redirect_uri] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g ]
10.0.20.105 - 2025-01-18 08:22:09 - DEBUG - Auto add redirect_uri to cache oauth2_galette_nc.redirect_uri.txt: https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g 10.0.20.105 - 2025-01-18 08:22:09 - DEBUG - Auto add redirect_uri ok. 10.0.20.105 - 2025-01-18 08:22:09 - DEBUG - getClientEntity() GaletteOAuth2\Entities\ClientEntity Object ( [identifier:protected] => galette_nc [name:protected] => galette_nc [redirectUri:protected] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [isConfidential:protected] => 1 ]
10.0.20.105 - 2025-01-18 08:22:09 - DEBUG - Scopes: member 10.0.20.102 - 2025-01-18 08:22:10 - INFO - Database version not checked in DEV mode. 10.0.20.101 - 2025-01-18 08:22:10 - INFO - Database version not checked in DEV mode. 10.0.20.101 - 2025-01-18 08:22:16 - INFO - Database version not checked in DEV mode. 10.0.20.101 - 2025-01-18 08:22:16 - DEBUG - authorization/doAuthorize() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/authorize?response_t... GET dump: Array ( [response_type] => code [client_id] => galette_nc [scope] => member [state] => HA-6WLQAXT9UY0SBVZOG83H4IKCF1D25 [redirect_uri] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g ]
POST dump: Array ( [csrf_name] => csrf678b647fdc4e3 [csrf_value] => aTvvIvggUj0LHUHX1C8lFPTroGJN/StPfRQ+53ymyuzsrJePmTRAsxdLCW37FEndLJ1iETpbzgw== [approve] => ]
10.0.20.101 - 2025-01-18 08:22:16 - DEBUG - getClientEntity() GaletteOAuth2\Entities\ClientEntity Object ( [identifier:protected] => galette_nc [name:protected] => galette_nc [redirectUri:protected] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [isConfidential:protected] => 1 ]
10.0.20.101 - 2025-01-18 08:22:16 - DEBUG - Scopes: member 10.0.20.101 - 2025-01-18 08:22:16 - DEBUG - authorization/doAuthorize() exit ok 10.0.20.104 - 2025-01-18 08:22:17 - INFO - Database version not checked in DEV mode. 10.0.20.104 - 2025-01-18 08:22:17 - DEBUG - Trying to set locale to en_US 10.0.20.104 - 2025-01-18 08:22:17 - DEBUG - authorization/token() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/access_token POST dump: Array ( [client_id] => galette_nc [client_secret] => 23tqDsOlCzE88GJmMw5y [grant_type] => authorization_code [redirect_uri] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [code] => def502008c21c3b1b0143e7c45219442c5c9cb4d52f9b77c4657e2e0f793505716d82bcac5285c6f54af4dc06f4a9b9c5ca0245ed22a698ec73f8669994cce837ea5531cdc55be721b56eb428a14fb263c53f4c77c359fcf15ae34c4fba755ce1e875ac725a35e19cd3c3617d2b4da26f861279fdf3b337ee4e58431d83257689a7ab790294f3ebed03304fc4b5aba7783cbd7438c077f5a4ec00fbf69adc960b783a1eb515f1ceee6c2e86d93597866ae58c648b81cfab2fd166a0c3c07feaf87b7ce176bd7bfdc80ec9ec49be270a5a0fb5f0ec00a654ea974166f95e8a89d54f0015f58a962d9687e58b783b015c20ac12bcd422f98ce76d83b713577be66ff2d8e1796b511839c08775bab5fd69b5fdf30b2f472561316bc18826c28c11eb7e0c90d93f43ca57baece47a8d1ecb304b3df730844a49d2ac56acb2bc65e182080e6122f224bcb36b3b197f45eba1dbde8c320a934f02efbd817ad91ebe9035fd35cf612942db2731a0fb32fcea0b0e1a3d40ca079140d1e41c414d2b830514b1a7aeca1df9c6e40d82b03b32af7c4faa367ab ]
10.0.20.104 - 2025-01-18 08:22:17 - DEBUG - getClientEntity() GaletteOAuth2\Entities\ClientEntity Object ( [identifier:protected] => galette_nc [name:protected] => galette_nc [redirectUri:protected] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [isConfidential:protected] => 1 ]
10.0.20.104 - 2025-01-18 08:22:18 - DEBUG - getClientEntity() GaletteOAuth2\Entities\ClientEntity Object ( [identifier:protected] => galette_nc [name:protected] => galette_nc [redirectUri:protected] => https://cloud.onzecplus.org/index.php/apps/sociallogin/custom_oauth2/g [isConfidential:protected] => 1 ]
10.0.20.104 - 2025-01-18 08:22:18 - DEBUG - authorization/token() exit ok 10.0.20.106 - 2025-01-18 08:22:18 - INFO - Database version not checked in DEV mode. 10.0.20.106 - 2025-01-18 08:22:18 - DEBUG - Trying to set locale to en_US 10.0.20.106 - 2025-01-18 08:22:18 - DEBUG - api/user() - URI: https://galette.onzecplus.org:80/webroot/plugins/oauth2/user
Le 18/01/2025 à 00:13, Johan Cwiklinski a écrit :
Salut,
Le 17/01/2025 à 23:15, Pierre Attar a écrit :
[...] Signed API request to https://galette.onzecplus.org/webroot/plugins/ oauth2/user has returned an error. HTTP error 500. Raw Provider API response: <!doctype html><html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>Slim Application Error</title> <style> body{margin:0;padding:30px;font:12px/1.5 Helvetica,Arial,Verdana,sans- serif} h1{margin:0;font-size:48px;font-weight:normal;line-height:48px} strong{display:inline-block;width:65px} </style> </head> <body> <h1>Slim Application Error</h1> <div><p>A website error has occurred. Sorry for the temporary inconvenience.</p></div> <a href="#" onclick="window.history.go(-1)">Go Back</a> </body></html>.
Normalement, il devrait y avoir une entrée dans les logs pour cette erreur. Il faut peut-être activer le mode debug de Galette.
++

Salut, Le 18/01/2025 à 09:28, Pierre Attar a écrit :
En revanche, le message de retour affiché dans nextcloud donne une trace qui pourrait peut-être t'aider :
Le souci est le suivant : «The resource owner or authorization server denied the request.» L'erreur est la même dans ton autre test. Ce n'est pas un bug, d'après ce que j'en comprends "jsute" une erreur au niveau du fonctionnement de oauth. C'est mal pris en charge, tu peux ouvrir une issue là : https://github.com/galette-community/plugin-oauth2/issues En revanche, aucune idée pourquoi... Vérifie le setup du plugin (notamment les histoires de clés). ++ -- Johan

OK, j'ai tenté de regénérer l'encryptionKey mais cela n'a pas plus fonctionné. Du coup, j'ai mis le problème sur github. https://github.com/galette-community/plugin-oauth2/issues/24 Merci pour l'aide, Pierre Le 18/01/2025 à 12:11, Johan Cwiklinski a écrit :
Salut,
Le 18/01/2025 à 09:28, Pierre Attar a écrit :
En revanche, le message de retour affiché dans nextcloud donne une trace qui pourrait peut-être t'aider :
Le souci est le suivant : «The resource owner or authorization server denied the request.»
L'erreur est la même dans ton autre test.
Ce n'est pas un bug, d'après ce que j'en comprends "jsute" une erreur au niveau du fonctionnement de oauth. C'est mal pris en charge, tu peux ouvrir une issue là : https://github.com/galette-community/plugin-oauth2/issues
En revanche, aucune idée pourquoi... Vérifie le setup du plugin (notamment les histoires de clés).
++
participants (2)
-
Johan Cwiklinski
-
Pierre Attar