forked from kevadesu/forgejo
Merge pull request 'feat: migrate TOTP secrets to keying
' (#6074) from gusted/forgejo-totp-keying into forgejo
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/6074 Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>
This commit is contained in:
commit
22d08c62f1
18 changed files with 149 additions and 47 deletions
|
@ -38,9 +38,8 @@ func TestAPITwoFactor(t *testing.T) {
|
|||
tfa := &auth_model.TwoFactor{
|
||||
UID: user.ID,
|
||||
}
|
||||
require.NoError(t, tfa.SetSecret(otpKey.Secret()))
|
||||
|
||||
require.NoError(t, auth_model.NewTwoFactor(db.DefaultContext, tfa))
|
||||
require.NoError(t, auth_model.NewTwoFactor(db.DefaultContext, tfa, otpKey.Secret()))
|
||||
|
||||
req = NewRequest(t, "GET", "/api/v1/user").
|
||||
AddBasicAuth(user.Name)
|
||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading…
Add table
Add a link
Reference in a new issue