-
-
Notifications
You must be signed in to change notification settings - Fork 5.8k
add mfa doc #26654
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
Merged
Merged
add mfa doc #26654
Changes from 1 commit
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
--- | ||
date: "2023-08-22T14:21:00+08:00" | ||
title: "Usage: Multi-factor Authentication (MFA)" | ||
slug: "multi-factor-authentication" | ||
weight: 15 | ||
toc: false | ||
draft: false | ||
menu: | ||
sidebar: | ||
parent: "usage" | ||
name: "Multi-factor Authentication (MFA)" | ||
weight: 15 | ||
identifier: "multi-factor-authentication" | ||
--- | ||
|
||
# Multi-factor Authentication (MFA) | ||
|
||
Multi-factor Authentication (also referred to as MFA or 2FA) enhances security by requiring a time-sensitive set of credentials in addition to a password. | ||
If a password were later to be compromised, Gitea would still not allow a successful login and the account would remain secure. | ||
Gitea supports both TOTP (Time-based One-Time Password) tokens and FIDO-based hardware keys. | ||
techknowlogick marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
MFA can be configured within the "Security" tab of the user settings page. | ||
|
||
## MFA Considerations | ||
|
||
Enabling MFA on a user does affect how the Git HTTP protocol can be used with the Git CLI. | ||
This interface does not support MFA, and trying to use a password normally will no longer be possible whilst MFA is enabled. | ||
If SSH is not an option for Git operations, an access token can be generated within the "Applications" tab of the user settings page. | ||
This access token can be used as if it were a password in order to allow the Git CLI to function over HTTP. | ||
|
||
> **Warning** - By its very nature, an access token sidesteps the security benefits of MFA. | ||
> It must be kept secure and should only be used as a last resort. | ||
|
||
The Gitea API supports providing the relevant TOTP password in the `X-Gitea-OTP` header, as described in [API Usage](development/api-usage.md). | ||
This should be used instead of an access token where possible. |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.