feat: update gitea vendor
runner nix smoke / nix label and flake smoke (push) Failing after 1m28s

This commit is contained in:
2026-09-26 21:18:24 +00:00
parent c439c1b948
commit d9b2a4e787
3538 changed files with 116131 additions and 44340 deletions
@@ -6,15 +6,14 @@ package v1_9
import (
"fmt"
"code.gitea.io/gitea/models/migrations/base"
"code.gitea.io/gitea/modules/log"
"code.gitea.io/gitea/modules/timeutil"
"code.gitea.io/gitea/modules/util"
"xorm.io/xorm"
"gitea.dev/models/db"
"gitea.dev/models/migrations/base"
"gitea.dev/modules/log"
"gitea.dev/modules/timeutil"
"gitea.dev/modules/util"
)
func HashAppToken(x *xorm.Engine) error {
func HashAppToken(x db.EngineMigration) error {
// AccessToken see models/token.go
type AccessToken struct {
ID int64 `xorm:"pk autoincr"`
@@ -65,10 +64,7 @@ func HashAppToken(x *xorm.Engine) error {
for _, token := range tokens {
// generate salt
salt, err := util.CryptoRandomString(10)
if err != nil {
return err
}
salt := util.CryptoRandomString(10)
token.TokenSalt = salt
token.TokenHash = base.HashToken(token.Sha1, salt)
if len(token.Sha1) < 8 {
@@ -101,7 +97,7 @@ func HashAppToken(x *xorm.Engine) error {
return resyncHashAppTokenWithUniqueHash(x)
}
func resyncHashAppTokenWithUniqueHash(x *xorm.Engine) error {
func resyncHashAppTokenWithUniqueHash(x db.EngineMigration) error {
// AccessToken see models/token.go
type AccessToken struct {
TokenHash string `xorm:"UNIQUE"` // sha256 of token - we will ensure UNIQUE later