Skip to content

[ZEPPELIN-6784] Honor mapped LDAP roles in notebook permissions - #5628

Open
miinhho wants to merge 1 commit into
apache:masterfrom
miinhho:fix/ldap-role-mapping-notebook-acl
Open

miinhho wants to merge 1 commit into
apache:masterfrom
miinhho:fix/ldap-role-mapping-notebook-acl

Conversation

@miinhho

@miinhho miinhho commented Nov 29, 2026

Copy link
Copy Markdown
Contributor

What is this PR for?

Users who sign in through RoleMappingLdapRealm cannot open notebooks shared only with their mapped role because Zeppelin omits that role from its notebook permission checks.

Include the mapped roles when the user authenticated through that realm, without changing how Zeppelin selects its existing role source. Close the LDAP context after the role lookup.

What type of PR is it?

Bug Fix

What is the Jira issue?

How should this be tested?

Run the server regression tests:

  ./mvnw test -pl zeppelin-server -am \
    -Dtest=ShiroAuthenticationServiceTest,RoleMappingLdapRealmTest \
    -Dsurefire.failIfNoSpecifiedTests=false

The tests check that a mapped LDAP role grants access to a role-restricted notebook in either LDAP/Knox realm order, that removing the role denies access, and that a Knox-only user does not receive the LDAP default role.

Questions:

  • Does the license files need to update? No.
  • Is there breaking changes for older versions? No.
  • Does this needs documentation? No.

Include roles from RoleMappingLdapRealm when it authenticated the user, without changing the existing realm selection order.

Cover role-based notebook access in both LDAP and Knox realm orders and ensure Knox-only users do not receive the LDAP default role.

This branch has not been deployed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant