diff options
Diffstat (limited to 'internal/tool')
-rw-r--r-- | internal/tool/tool.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/internal/tool/tool.go b/internal/tool/tool.go index 37c51dd1..2120fac3 100644 --- a/internal/tool/tool.go +++ b/internal/tool/tool.go @@ -170,7 +170,7 @@ func CreateTimeLimitCode(data string, minutes int, startInf interface{}) string // create sha1 encode string sh := sha1.New() - _, _ = sh.Write([]byte(data + conf.SecretKey + startStr + endStr + com.ToStr(minutes))) + _, _ = sh.Write([]byte(data + conf.Security.SecretKey + startStr + endStr + com.ToStr(minutes))) encoded := hex.EncodeToString(sh.Sum(nil)) code := fmt.Sprintf("%s%06d%s", startStr, minutes, encoded) |