Changing usernames of OIDC users does not work #1564

Closed
opened 2023-07-04 08:16:57 +00:00 by TaoChen · 3 comments

I'm trying rename a user(change it's username and subject in SQL-Table-Users), this user is login though OIDC. I can rename it. But when this user login again, the username will recover.

I try to delete the 'DEL xorm:sql:users:1590036933'(all'xorm:sql:users*') in redis, but when login again, these item will also recover.

I'm trying rename a user(change it's username and subject in SQL-Table-Users), this user is login though OIDC. I can rename it. But when this user login again, the username will recover. I try to delete the 'DEL xorm:sql:users:1590036933'(all'xorm:sql:users*') in redis, but when login again, these item will also recover.
Owner

The cache should not make a difference here. Does it work if you disable the cache?

Did you change the username in Vikunja or in the OIDC service?

Why do you want to change the username in the first place?

The cache should not make a difference here. Does it work if you disable the cache? Did you change the username in Vikunja or in the OIDC service? Why do you want to change the username in the first place?
konrad changed title from Delete Cache to Changing usernames of OIDC users does not work 2023-07-04 11:25:29 +00:00
Author

The cache should not make a difference here. Does it work if you disable the cache?

Yes, when I disable cache. It worked as my exception.

Did you change the username in Vikunja or in the OIDC service?

Yes, I changed the usename in the OIDC. then I try to change this usename in Vikunja, too.

Why do you want to change the username in the first place?

this is a long story....

> The cache should not make a difference here. Does it work if you disable the cache? Yes, when I disable cache. It worked as my exception. > Did you change the username in Vikunja or in the OIDC service? Yes, I changed the usename in the OIDC. then I try to change this usename in Vikunja, too. > > Why do you want to change the username in the first place? this is a long story....
Owner

Yes, I changed the usename in the OIDC. then I try to change this usename in Vikunja, too.

Did you get a randomly generated username or did Vikunja pick up the username from the oidc provider? The provider should report the username as "preferred username" in order for this to work.
I'm not 100% sure but iirc it will only set the username when logging in for the first time.

Usernames in Vikunja are considered unique and not changeable.

> Yes, I changed the usename in the OIDC. then I try to change this usename in Vikunja, too. Did you get a randomly generated username or did Vikunja pick up the username from the oidc provider? The provider should report the username as "preferred username" in order for this to work. I'm not 100% sure but iirc it will only set the username when logging in for the first time. Usernames in Vikunja are considered unique and not changeable.
Sign in to join this conversation.
No Milestone
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: vikunja/vikunja#1564
No description provided.