Skip to content

Fix #245: Don't update user_main_attribute #283

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

Merged
merged 1 commit into from
May 27, 2021

Conversation

jaap3
Copy link
Contributor

@jaap3 jaap3 commented May 27, 2021

No description provided.

@jaap3 jaap3 changed the base branch from master to dev May 27, 2021 09:39
@jaap3
Copy link
Contributor Author

jaap3 commented May 27, 2021

Should be good now (and is rebased on dev)

@peppelinux peppelinux merged commit 596c455 into IdentityPython:dev May 27, 2021
@jaap3 jaap3 deleted the issue245 branch May 27, 2021 11:11
@tacerus
Copy link

tacerus commented Dec 18, 2022

Hello,

I stumbled upon this PR after debugging why the email attribute in my Django application would not be updated - and indeed, after commenting the if attr == user_lookup_key part out, it updates the value as expected.

Is there possibly a way to disable the behavior which I am missing? I understand there was an issue as referenced with #245, however it seems some Django applications do not use a separate username field, causing Djangosaml2 to keep the username as the email value.

@peppelinux
Copy link
Member

Can you share your djangosaml2 settings here?

@tacerus
Copy link

tacerus commented Dec 18, 2022

I think it was error with how I used the application - my issue seems to have arised from the IDP serving the username instead of the email address in the NameID, whilst the Django application only used email addresses to store users - which explained me getting usernames inside of the Django email attribute for SAML authenticated users.

I falsely assumed my issues to be caused by djangosaml2.
Apologies for the false alarm and thank you for your response! :-)

@peppelinux
Copy link
Member

Thank you for having reached us with a very good analysis

Best

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.

3 participants