-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Can't link Github/Gitlab to existing account #9066
Comments
same as #8923 |
It seems to me that it's because external account sign in currently requires password.
m.Post("/link_account_signin", bindIgnErr(auth.SignInForm{}), user.LinkAccountPostSignIn)
type SignInForm struct {
UserName string `binding:"Required;MaxSize(254)"`
// TODO remove required from password for SecondFactorAuthentication
Password string `binding:"Required;MaxSize(255)"`
Remember bool
} As the result, func LinkAccountPostSignIn(ctx *context.Context, signInForm auth.SignInForm) {
// ...
if ctx.HasError() {
ctx.HTML(200, tplLinkAccount)
return
}
//...
The possible solution may be creating a new Let me know if this is an acceptable solution. I could create a PR to solve this issue. |
But don't you think that if you eliminate the need to request the password for verification when connecting with oAuth2, users may abuse to acquire accounts that do not belong to them? |
You are right. The problem is Gitea removes Password form field if you set app.ini So the other solution would be always showing Password field on Link to Existing Account tab. However, this solution conflicts with what #6606 wants to do. I am not sure if it's acceptable. 😕 |
1.10.0
2.20.1
Debian GNU/Linux 10 (buster) amd64
[x]
):gitea.log
Description
Hi! I enabled Gitlab and Github authentication. Its works because I can comme back on Gitea from Github/Gitlab login. Its asks me to link to existing account. I fill it, but I'm redirected to "Register New Account". I can't log in with Github and Gitlab.
Screenshots
The text was updated successfully, but these errors were encountered: