Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JENKINS-19409] use idstrategy to match role assignments #332

Merged
merged 2 commits into from
Aug 23, 2023

Conversation

mawinter69
Copy link
Contributor

@mawinter69 mawinter69 commented Aug 23, 2023

The matching of users to roles was so far case sensitive. But as most security realms work case insensitive this means that permissions are not properly matched when someone logs in with capital letters but the role is assigned to the user with small letters.
The plugin now falls back to the security realms idstrategy in case the user doesn't match case sensitive.
For backward compatibility reasons, this feature can be switched off via com.michelin.cio.hudson.plugins.rolestrategy.RoleMap.FORCE_CASE_SENSITIVE. This can be set either as a startup java property, or via Jenkins script console or via a hook script.

See JENKINS-19409 and others

Testing done

configured to use AD plugin
granted lower case username admin permissions
before: tried login with capital username -> failed with missing overall read
after: login with capital username -> user has admin permissions

Submitter checklist

The matching users to roles was so far case sensitive. But as most
security realms work case insensitive this means that permissions are
not properly matched when someone logs in with capital letters but the
role is assigned to the user with small letters.
The plugin now falls back to the security realms idstrategy in case the
user doesn't match case sensitive.
For backward compatibility reasons, this feature can be switched off.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant