Skip to content

MM-68216 - add docs about team scoped channels abac#8854

Open
pvev wants to merge 8 commits intomasterfrom
MM-68216-add-team-settings-abac-channels-scope-access-docs
Open

MM-68216 - add docs about team scoped channels abac#8854
pvev wants to merge 8 commits intomasterfrom
MM-68216-add-team-settings-abac-channels-scope-access-docs

Conversation

@pvev
Copy link
Copy Markdown
Contributor

@pvev pvev commented Apr 7, 2026

Summary

This PR adds documentation for the team-level channel membership policies feature introduced as part of the ABAC phase 2 work. It covers how Team Admins create and manage attribute-based access policies for private channels within their team from Team Settings, including the new manage_team_access_rules permission. Existing ABAC and roles docs are updated to reflect the new three-tier hierarchy and cross-link to the new page.

Ticket Link

https://mattermost.atlassian.net/browse/MM-68216

@pvev pvev requested review from amyblais and isacikgoz April 7, 2026 10:06
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 7, 2026

Newest code from mattermost has been published to preview environment for Git SHA 7b48897

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Apr 7, 2026

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

Adds documentation and permissions for a new team-level ABAC feature enabling Team Admins to create and manage attribute-based membership policies for private channels within their team; updates ABAC overview, team settings and role docs, and introduces the manage_team_access_rules permission.

Changes

Cohort / File(s) Summary
Team-Level ABAC Policies Documentation
source/administration-guide/manage/admin/abac-team-channel-policies.rst, source/administration-guide/manage/admin/attribute-based-access-control.rst, source/administration-guide/manage/admin/abac-channel-access-rules.rst
Added a new admin page for team-scoped channel membership policies; updated ABAC overview to include "Team-level channel policies"; appended cross-reference in channel-access guidance to the new team-level docs.
Permission and Role Infrastructure
source/administration-guide/onboard/advanced-permissions-backend-infrastructure.rst
Introduced built-in permission manage_team_access_rules (scope: team) and granted it to the team_admin role by default.
End-User Documentation
source/end-user-guide/collaborate/learn-about-roles.rst, source/end-user-guide/collaborate/team-settings.rst
Added Team Admin privilege text describing team-level ABAC management and a Membership Policies section/tab in Team settings referencing the new team-level policy docs.

Sequence Diagram(s)

sequenceDiagram
  participant TeamAdmin as Team Admin
  participant UI as Team Settings UI
  participant AppServer as Application Server
  participant PolicyStore as Policy Store
  participant SyncJob as Membership Sync Job
  participant SystemPolicy as System-wide Policy Engine

  TeamAdmin->>UI: Open Membership Policies tab
  UI->>AppServer: Request team policies (check ABAC enabled + permission)
  AppServer->>PolicyStore: Fetch team policies for team
  PolicyStore-->>AppServer: Return policies
  AppServer-->>UI: Render policies list

  TeamAdmin->>UI: Create/Edit policy + assign private channels
  UI->>AppServer: Submit policy (validate permission)
  AppServer->>SystemPolicy: Validate no conflict with system-wide policies
  SystemPolicy-->>AppServer: Validation result
  AppServer->>PolicyStore: Save policy and channel assignments
  PolicyStore-->>AppServer: Ack
  AppServer-->>UI: Confirm save

  AppServer->>SyncJob: Trigger immediate sync for affected channels
  SyncJob->>PolicyStore: Read applicable system + team policies
  SyncJob->>PolicyStore: Evaluate membership changes (apply auto-add, removals)
  SyncJob-->>AppServer: Sync complete
  AppServer-->>UI: Notify TeamAdmin of completion
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and specifically describes the main change: adding documentation for team-scoped ABAC channel policies, which aligns with all file modifications.
Description check ✅ Passed The description is directly related to the changeset, providing context about the ABAC phase 2 feature, team-level policies, and documentation updates across multiple files.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch MM-68216-add-team-settings-abac-channels-scope-access-docs

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 7, 2026

Newest code from mattermost has been published to preview environment for Git SHA 79b2d9d

@amyblais amyblais added 1: Dev Review Requires review by a core commiter 2: Editor Review Requires review by an editor labels Apr 7, 2026
@amyblais amyblais requested review from Combs7th and esethna and removed request for amyblais April 7, 2026 10:24
Copy link
Copy Markdown
Member

@isacikgoz isacikgoz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good overall but one correction is needed. Also one thing to confirm.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 8, 2026

Newest code from mattermost has been published to preview environment for Git SHA 8e41512

@pvev pvev requested a review from isacikgoz April 8, 2026 18:07
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 8, 2026

Newest code from mattermost has been published to preview environment for Git SHA 2add867

Copy link
Copy Markdown
Member

@isacikgoz isacikgoz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, just one correction needed, since it's a small one approving and leaving to you to fix before merge.


.. note::

System Admins also have access to the **Membership Policies** tab in Team Settings and can see all policies for the team, including those that span multiple teams.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this also needs to be updated, they are seeing what a regular team admin can see.

@github-actions
Copy link
Copy Markdown
Contributor

Newest code from mattermost has been published to preview environment for Git SHA 77998b0

@github-actions
Copy link
Copy Markdown
Contributor

Newest code from mattermost has been published to preview environment for Git SHA 66c1791

@esethna esethna removed 1: Dev Review Requires review by a core commiter 2: Editor Review Requires review by an editor labels Apr 13, 2026
@esethna
Copy link
Copy Markdown
Contributor

esethna commented Apr 13, 2026

This is a nice doc @pvev :)

@esethna
Copy link
Copy Markdown
Contributor

esethna commented Apr 13, 2026

Same note about rebasing to the right docs branch. If this is v11.7 the branch will be cut in the next few days @pvev

@esethna esethna added the Do Not Merge/Awaiting Next Release To be merged with the next release (e.g. API documentation updates) label Apr 13, 2026
@esethna esethna added this to the v11.7.0 milestone Apr 13, 2026
@github-actions
Copy link
Copy Markdown
Contributor

Newest code from mattermost has been published to preview environment for Git SHA 9690760

@github-actions
Copy link
Copy Markdown
Contributor

Newest code from mattermost has been published to preview environment for Git SHA b280c27

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Do Not Merge/Awaiting Next Release To be merged with the next release (e.g. API documentation updates)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants