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

Fix inconsistent users issue #35

Merged
merged 1 commit into from
Jan 18, 2019
Merged

Fix inconsistent users issue #35

merged 1 commit into from
Jan 18, 2019

Conversation

gavinfish
Copy link
Member

@gavinfish gavinfish commented Jan 18, 2019

Issue #34

The security advisory helps to expose an existing bug here.

Summary problem here is that when validate seed for current user, this plugin refers to different user ids in session and authentication.

The new seed security listener uses UserDetails#getUsername() to fetch a user which is implemented by AzureAdUser#getUsername() returning the user name of a azure ad user.

In the HttpSessionContextIntegrationFilter2#hasInvalidSessionSeed() method, it gets a user by Authentication#getName() which is implemented in AzureAuthenticationToken#getName() returning the unique name of the azure ad user.

UserDetails#getUsername() returns the username to authenticate the user, so it should also be unique. I also refactored the former username variable to name to make consistent with previous version.

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.

2 participants