Skip to content

Commit 73f8833

Browse files
authored
Merge pull request #992 from minrk/oauth17
update oauthenticator to 17
2 parents 5834f14 + 3bd739e commit 73f8833

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

docs/howto/auth/awscognito.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -149,9 +149,10 @@ If it is not provided as array, there is an easy fix. Just add these lines to
149149
your `awscognito.py`:
150150

151151
```python
152-
def claim_groups_key_func(user_data_resp_json):
153-
return [user_data_resp_json['custom:department']]
152+
def groups_key_func(auth_state):
153+
return [auth_state['oauth_user']['custom:department']]
154154

155-
c.GenericOAuthenticator.claim_groups_key = claim_groups_key_func
155+
c.GenericOAuthenticator.manage_groups = True
156+
c.GenericOAuthenticator.auth_state_groups_key = groups_key_func
156157
c.GenericOAuthenticator.allowed_groups = ["AA BB CC", "AA BB DD"]
157158
```

tljh/requirements-hub-env.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jupyterhub-firstuseauthenticator>=1.0.0,<2
1414
jupyterhub-nativeauthenticator>=1.2.0,<2
1515
jupyterhub-ldapauthenticator>=1.3.2,<2
1616
jupyterhub-tmpauthenticator>=1.0.0,<2
17-
oauthenticator[azuread]>=16.0.4,<17
17+
oauthenticator>=17,<18
1818
jupyterhub-idle-culler>=1.2.1,<2
1919

2020
# pycurl is installed to improve reliability and performance for when JupyterHub

0 commit comments

Comments
 (0)