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

Allow user name suffix for OAuth sources #7014

Open
mxmehl opened this issue May 22, 2019 · 1 comment
Open

Allow user name suffix for OAuth sources #7014

mxmehl opened this issue May 22, 2019 · 1 comment
Labels
topic/authentication type/proposal The new feature has not been accepted yet but needs to be discussed first.

Comments

@mxmehl
Copy link

mxmehl commented May 22, 2019

Description

At our Gitea instance, we would like to introduce a second authentication source next to LDAP, namely Github. However, namespace-wise, we would like to give preference to our current and future LDAP users.

Can Gitea automatically add a suffix to a user name when this user registeres with a specific authentication provider, e.g. that the Github user janedoe becomes janedoe-guest or janedoe-github?

Debian's GitLab supports something like that for external users who are not Debian developers: https://signup.salsa.debian.org/register/guest/

@lunny lunny added the type/proposal The new feature has not been accepted yet but needs to be discussed first. label May 24, 2019
@6543 6543 added good first issue Likely to be an easy fix topic/authentication labels Aug 13, 2021
@6543
Copy link
Member

6543 commented Aug 13, 2021

should be handled around here:

if !createAndHandleCreatedUser(ctx, base.TplName(""), nil, u, &gothUser, setting.OAuth2Client.AccountLinking != setting.OAuth2AccountLinkingDisabled) {

after #16594 got in you have the LoginSource souce to check option against

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic/authentication type/proposal The new feature has not been accepted yet but needs to be discussed first.
Projects
None yet
Development

No branches or pull requests

4 participants