mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-06-01 04:12:10 +00:00
Use base32 for 2FA scratch token (#18384)
* Use base32 for 2FA scratch token * rename Secure* to Crypto*, add comments
This commit is contained in:
parent
4889ab52de
commit
49dd906753
11 changed files with 41 additions and 37 deletions
|
@ -337,7 +337,7 @@ func SettingsPost(ctx *context.Context) {
|
|||
return
|
||||
}
|
||||
|
||||
remoteSuffix, err := util.RandomString(10)
|
||||
remoteSuffix, err := util.CryptoRandomString(10)
|
||||
if err != nil {
|
||||
ctx.ServerError("RandomString", err)
|
||||
return
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue