2FA push "Authentication failed" #12320

Closed
opened 2025-11-02 10:05:29 -06:00 by GiteaMirror · 2 comments
Owner

Originally created by @mature-woman on GitHub (Jan 10, 2024).

Description

After activating 2FA i cannot push using the HTTPS protocol.
After disabling 2FA everything is working.

Gitea Version

1.22.0+dev-514-gdd5693387 built with GNU Make 4.3, go1.21.4 : bindata

Can you reproduce the bug on the Gitea demo site?

No

Log Gist

No response

Screenshots

изображение

Git Version

git version 2.34.1

Operating System

Ubuntu 22 (Linux 6.2.0-39-generic x86_64)

How are you running Gitea?

Compiled by myself

Database

MySQL/MariaDB

Originally created by @mature-woman on GitHub (Jan 10, 2024). ### Description After **activating 2FA** i cannot **push** using the **HTTPS** protocol. After **disabling 2FA** everything is **working**. ### Gitea Version 1.22.0+dev-514-gdd5693387 built with GNU Make 4.3, go1.21.4 : bindata ### Can you reproduce the bug on the Gitea demo site? No ### Log Gist _No response_ ### Screenshots ![изображение](https://github.com/go-gitea/gitea/assets/21334019/50c1558b-57c8-43fd-9178-e3ac6548eba4) ### Git Version git version 2.34.1 ### Operating System Ubuntu 22 (Linux 6.2.0-39-generic x86_64) ### How are you running Gitea? Compiled by myself ### Database MySQL/MariaDB
GiteaMirror added the type/question label 2025-11-02 10:05:29 -06:00
Author
Owner

@lafriks commented on GitHub (Jan 11, 2024):

If you have 2FA enabled you can not use the user's password for git push, you have to create either app token in user settings or use that instead of password or use ssh protocol.

@lafriks commented on GitHub (Jan 11, 2024): If you have 2FA enabled you can not use the user's password for git push, you have to create either app token in user settings or use that instead of password or use ssh protocol.
Author
Owner

@mature-woman commented on GitHub (Jan 11, 2024):

If you have 2FA enabled you can not use the user's password for git push, you have to create either app token in user settings or use that instead of password or use ssh protocol.

For some reason, the built-in SSH server in Gitea does not work in loopback mode on my server/router/cloudflare (does not connect at all), which is why I use HTTPS (i do not want to deal with this right now).

i will try app token, thanks!

@mature-woman commented on GitHub (Jan 11, 2024): > If you have 2FA enabled you can not use the user's password for git push, you have to create either app token in user settings or use that instead of password or use ssh protocol. _For some reason, the built-in SSH server in Gitea does not work in loopback mode on my server/router/cloudflare (does not connect at all), which is why I use HTTPS (i do not want to deal with this right now)._ **i will try app token, thanks!**
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#12320