2FA IP whitelist to bypass timeouts #4589

Open
opened 2025-11-02 05:55:30 -06:00 by GiteaMirror · 7 comments
Owner

Originally created by @ghnp5 on GitHub (Jan 2, 2020).

  • Gitea version (or commit ref): 1.11.0+dev
  • Operating system: CentOS Docker
  • Database: MySQL

Description

Would it be possible to make 2FA whitelist the IP and not ask for another code for some time defined by us? E.g., for 30 days, do not ask for another 2FA code.

It's very annoying that every time I am logged off (a few times a day, I'd say), I need to keep typing a new code just to login.

It makes me really want to remove the 2FA, but obviously that's not an option I should take.

As an alternative (but would be nice to have both) it would be great to be able to increase the login timeout, as I appear to be booted off very quickly.

Thank you very much.

Originally created by @ghnp5 on GitHub (Jan 2, 2020). - Gitea version (or commit ref): 1.11.0+dev - Operating system: CentOS Docker - Database: MySQL ## Description Would it be possible to make 2FA whitelist the IP and not ask for another code for some time defined by us? E.g., for 30 days, do not ask for another 2FA code. It's very annoying that every time I am logged off (a few times a day, I'd say), I need to keep typing a new code just to login. It makes me really want to remove the 2FA, but obviously that's not an option I should take. As an alternative (but would be nice to have both) it would be great to be able to increase the login timeout, as I appear to be booted off very quickly. Thank you very much.
GiteaMirror added the issue/confirmedtype/enhancement labels 2025-11-02 05:55:30 -06:00
Author
Owner

@lafriks commented on GitHub (Jan 2, 2020):

You can check remember me checkbox to increase login timeout

@lafriks commented on GitHub (Jan 2, 2020): You can check remember me checkbox to increase login timeout
Author
Owner

@ghnp5 commented on GitHub (Jan 2, 2020):

I always do that, but apparently it doesn't increase to whatever fits me.

@ghnp5 commented on GitHub (Jan 2, 2020): I always do that, but apparently it doesn't increase to whatever fits me.
Author
Owner

@bagasme commented on GitHub (Jan 3, 2020):

@ghnp5 bug on remember me?

@bagasme commented on GitHub (Jan 3, 2020): @ghnp5 bug on remember me?
Author
Owner

@ghnp5 commented on GitHub (Feb 9, 2020):

@lafriks @bagasme Just wanted to give an update on this.
Somehow, recently I'm not having problems of being "kicked out" like I was before. I have no idea what changed. Either a config change or an upgrade.

However, it would be nice indeed to whitelist the IP for a while, in case we logout and login on the same IP :)

Thank you.

@ghnp5 commented on GitHub (Feb 9, 2020): @lafriks @bagasme Just wanted to give an update on this. Somehow, recently I'm not having problems of being "kicked out" like I was before. I have no idea what changed. Either a config change or an upgrade. However, it would be nice indeed to whitelist the IP for a while, in case we logout and login on the same IP :) Thank you.
Author
Owner

@stale[bot] commented on GitHub (Apr 9, 2020):

This issue has been automatically marked as stale because it has not had recent activity. I am here to help clear issues left open even if solved or waiting for more insight. This issue will be closed if no further activity occurs during the next 2 weeks. If the issue is still valid just add a comment to keep it alive. Thank you for your contributions.

@stale[bot] commented on GitHub (Apr 9, 2020): This issue has been automatically marked as stale because it has not had recent activity. I am here to help clear issues left open even if solved or waiting for more insight. This issue will be closed if no further activity occurs during the next 2 weeks. If the issue is still valid just add a comment to keep it alive. Thank you for your contributions.
Author
Owner

@ghnp5 commented on GitHub (Apr 9, 2020):

It would be nice indeed to whitelist the IP for a while, in case we logout and login on the same IP.

@ghnp5 commented on GitHub (Apr 9, 2020): It would be nice indeed to whitelist the IP for a while, in case we logout and login on the same IP.
Author
Owner

@stale[bot] commented on GitHub (Jun 9, 2020):

This issue has been automatically marked as stale because it has not had recent activity. I am here to help clear issues left open even if solved or waiting for more insight. This issue will be closed if no further activity occurs during the next 2 weeks. If the issue is still valid just add a comment to keep it alive. Thank you for your contributions.

@stale[bot] commented on GitHub (Jun 9, 2020): This issue has been automatically marked as stale because it has not had recent activity. I am here to help clear issues left open even if solved or waiting for more insight. This issue will be closed if no further activity occurs during the next 2 weeks. If the issue is still valid just add a comment to keep it alive. Thank you for your contributions.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#4589