OAuth: feat: use OIDC claims on user creation (#9286)

Signed-off-by: Edouard Vanbelle <edouard@vanbelle.fr>
This commit is contained in:
Edouard Vanbelle
2023-12-29 19:10:37 +01:00
committed by GitHub
parent 14f092c7af
commit ffa298d41c
3 changed files with 158 additions and 0 deletions

View File

@@ -407,6 +407,17 @@ $config['oauth_cache'] = 'db';
// Optional: cache ttl
$config['oauth_cache_ttl'] = '8h';
// Optional: map OIDC claims to Roundcube keys during the account creation
// format: roundcube_key => array of claims (the first claim found and defined will be used)
// more informations on claims: https://openid.net/specs/openid-connect-core-1_0.html#StandardClaims
// roundcube_key can be: user_name, user_email, language
// default value:
$config['oauth_user_create_map'] = [
'user_name' => ['name'],
'user_email' => ['email'],
'language' => ['locale'],
];
///// Example config for Gmail
// Register your service at https://console.developers.google.com/