Skip to content

Personal Access Tokens no longer work with https when 2fa is turned on. #15919

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

Closed
2 of 6 tasks
musicislife08 opened this issue May 18, 2021 · 1 comment · Fixed by #15915
Closed
2 of 6 tasks

Personal Access Tokens no longer work with https when 2fa is turned on. #15919

musicislife08 opened this issue May 18, 2021 · 1 comment · Fixed by #15915

Comments

@musicislife08
Copy link

Description

I am not sure what changed however after a recent update I can no longer use my Personal Access Token to pull from my repo while 2fa is turned on like all of the documentation says I should be able to do however it always returns the following even with a brand new token.

using ~git clone https://username:token@repo.domain/org/repo.git` or any other command no longer works as it used to.
This does the same on the try.gitea.io site after turning on 2fa. This feature used to work however im not sure why its not allowing the use of the pat anymore.

git pull
remote: Users with two-factor authentication enabled cannot perform HTTP/HTTPS operations via plain username and password. Please create and use a personal access token on the user settings page
fatal: Authentication failed for 'repourlhere'

The above gist includes the debug logs from both the git file and from the docker container logs.

@kimdre
Copy link

kimdre commented May 19, 2021

This was a Bug in #15303 and got fixed with #15915.
Try to update your Gitea. The new Docker Image including the Fix has also been rolled out.
I tested the Token Auth successfully again in 1.15.0+dev-325-g370cfde35

@zeripath zeripath linked a pull request May 19, 2021 that will close this issue
@go-gitea go-gitea locked and limited conversation to collaborators Oct 19, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants