diff options
author | Douwe Maan <douwe@gitlab.com> | 2018-02-08 14:26:18 +0000 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2018-02-08 14:26:18 +0000 |
commit | bbb3e58bc7143df31355baddc970670e1e64503d (patch) | |
tree | 712b159ad384f7c349416f7de8e8feb9afe9b43a /config | |
parent | 15eb0ab0f8ec1bef02065949cade065956c9d4d1 (diff) | |
parent | 583ef9458c5e5c32a14629f5754bc53ed0ad8a33 (diff) | |
download | gitlab-ce-bbb3e58bc7143df31355baddc970670e1e64503d.tar.gz |
Merge branch 'feature/oidc-groups-claim' into 'master'
Add groups to OpenID Connect claims
See merge request gitlab-org/gitlab-ce!16929
Diffstat (limited to 'config')
-rw-r--r-- | config/initializers/doorkeeper_openid_connect.rb | 1 | ||||
-rw-r--r-- | config/locales/doorkeeper.en.yml | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/config/initializers/doorkeeper_openid_connect.rb b/config/initializers/doorkeeper_openid_connect.rb index af174def047..98e1f6e830f 100644 --- a/config/initializers/doorkeeper_openid_connect.rb +++ b/config/initializers/doorkeeper_openid_connect.rb @@ -31,6 +31,7 @@ Doorkeeper::OpenidConnect.configure do o.claim(:website) { |user| user.full_website_url if user.website_url? } o.claim(:profile) { |user| Gitlab::Routing.url_helpers.user_url user } o.claim(:picture) { |user| user.avatar_url(only_path: false) } + o.claim(:groups) { |user| user.membership_groups.map(&:full_path) } end end end diff --git a/config/locales/doorkeeper.en.yml b/config/locales/doorkeeper.en.yml index b1c71095d4f..889111282ef 100644 --- a/config/locales/doorkeeper.en.yml +++ b/config/locales/doorkeeper.en.yml @@ -68,7 +68,7 @@ en: read_user: Read-only access to the user's profile information, like username, public email and full name openid: - The ability to authenticate using GitLab, and read-only access to the user's profile information + The ability to authenticate using GitLab, and read-only access to the user's profile information and group memberships sudo: Access to the Sudo feature, to perform API actions as any user in the system (only available for admins) flash: |