|
| 1 | +# OIDC groups authorization |
| 2 | + |
| 3 | +Livebook Teams allows you to control access to your app servers and Livebook apps based on group membership in your OIDC identity provider (IdP). |
| 4 | + |
| 5 | + |
| 6 | + |
| 7 | +> #### Livebook version requirement {: .info} |
| 8 | +> Requires Livebook v0.16 or newer. |
| 9 | +
|
| 10 | +## Overview |
| 11 | + |
| 12 | +OIDC groups authorization enables you to: |
| 13 | + |
| 14 | +- Restrict access to your Livebook apps and app servers based on group membership |
| 15 | +- Control which users can access specific apps using slug prefix filtering |
| 16 | +- Integrate seamlessly with your existing OIDC SSO provider (Okta, Microsoft Entra, etc.) |
| 17 | + |
| 18 | +## Prerequisites |
| 19 | + |
| 20 | +Before configuring OIDC groups authorization, ensure you have: |
| 21 | + |
| 22 | +1. **Configured an OIDC provider** in your Livebook Teams organization. If you haven't done this yet, follow the instructions in our [OIDC SSO documentation](oidc_sso.md). |
| 23 | + |
| 24 | +2. **Configured your OIDC identity provider** to include group information in the ID tokens: |
| 25 | + - **Okta**: [Customize tokens with a groups claim](https://developer.okta.com/docs/guides/customize-tokens-groups-claim/main/) |
| 26 | + |
| 27 | +## Configuration |
| 28 | + |
| 29 | +### 1. Enable authorization via OIDC SSO groups |
| 30 | + |
| 31 | +To enable authorization via OIDC SSO groups for a deployment group: |
| 32 | + |
| 33 | +1. Log in to Livebook Teams |
| 34 | +2. Navigate to the **Deployments** panel |
| 35 | +3. Click **Edit** on the deployment group where you want to enable authorization |
| 36 | +4. Go to the **IAM** section (requires "admin" role in the organization) |
| 37 | +5. Ensure that **Authenticate via Livebook Teams** is enabled |
| 38 | +6. Enable **Authorize via OIDC SSO groups** |
| 39 | + |
| 40 | +### 2. Add group authorization |
| 41 | + |
| 42 | +Once authorization is enabled, you can add group access rules: |
| 43 | + |
| 44 | +1. Click the **Add group** button |
| 45 | +2. Select one of your configured OIDC identity providers |
| 46 | +3. Enter the name of a group from your identity provider |
| 47 | +4. Choose the **Access type**: |
| 48 | + - Full access |
| 49 | + - Slug prefix access |
| 50 | +5. Click the **Add group** button to save the rule |
| 51 | + |
| 52 | +You can add multiple groups with different access types to configure your authorization strategy. |
| 53 | + |
| 54 | +## Access types explained |
| 55 | + |
| 56 | +### Full access |
| 57 | + |
| 58 | +Users who belong to groups with full access can access: |
| 59 | +- The app server admin interface* |
| 60 | +- All Livebook apps deployed to this deployment group |
| 61 | + |
| 62 | +**Notice that [Admin authentication](authentication.md#admin-authentication) configs will also apply if configured.* |
| 63 | + |
| 64 | +### Slug prefix access |
| 65 | + |
| 66 | +Users who belong to groups with slug prefix access can only access Livebook apps whose URL slugs start with the specified prefix. |
| 67 | + |
| 68 | +For example, with the slug prefix "**finance-**", users can access an app whose slug is "**finance-**budget", but not one with the slug "**hr-**budget". |
| 69 | + |
| 70 | +This allows you to create role-based access control based on your organization's existing group structure. |
| 71 | + |
| 72 | +## Testing the Configuration |
| 73 | + |
| 74 | +To verify the configuration is working: |
| 75 | + |
| 76 | +1. Sign out of any current Livebook Teams sessions |
| 77 | +2. Navigate to an app server or Livebook app in the deployment group where you've enabled OIDC groups authorization |
| 78 | +3. You will be prompted to authenticate through your OIDC provider |
| 79 | +4. After authentication, the system will check your group membership |
| 80 | +5. You will only be granted access if you belong to one of the configured groups with appropriate permissions |
| 81 | + |
| 82 | +## Troubleshooting |
| 83 | + |
| 84 | +If users are experiencing access issues: |
| 85 | + |
| 86 | +1. Verify the group name matches exactly as defined in your IdP (group names are case-sensitive) |
| 87 | +2. Check that the user is a member of the specified group in your IdP |
| 88 | +3. Ensure your OIDC provider is properly set up to include group names inside the ID token |
0 commit comments