mirror of
https://github.com/mickael-kerjean/filestash.git
synced 2025-10-30 09:37:55 +08:00
improve (crypto): derivate secret_key for each usage to reduce attack surface in the worst case scenario
This commit is contained in:
@ -85,7 +85,7 @@ func FileLs(ctx App, res http.ResponseWriter, req *http.Request) {
|
||||
Tmp1 interface{}
|
||||
}{ files, perms }
|
||||
if j, err := json.Marshal(tmp); err == nil {
|
||||
return Hash(string(j))
|
||||
return Hash(string(j), 20)
|
||||
}
|
||||
return ""
|
||||
}()
|
||||
|
||||
Reference in New Issue
Block a user