feat-use-new-passwd #1095
Merged
xuu
merged 8 commits from feat-use-new-passwd
into main
3 months ago
Loading…
Reference in new issue
There is no content yet.
Delete Branch 'feat-use-new-passwd'
Deleting a branch is permanent. It CANNOT be undone. Continue?
implements a new password system that includes preferred hash + complexity to automatically rehash on login if needed.
This is using argon2i but i can add support for argon2id.now prefers argon2id per comments on #1093
closes #1093
133b296755
to420c7b5bf3
4 months agoDidn't run the code, only looked at it so far. Couldn't find any obvious mistakes. Will try it on the weekend.
hash, err := a.pm.Passwd(password, "")
if err != nil {
log.WithError(err).Error("error creating password hash")
http.Error(w, "Passwrod Creation Failed", http.StatusInternalServerError)
Just noticed a typo in "Passw_or_d".
:D the method for go-passwd's *passwd.Passwd is -in fact- Passwd()
// Save upgraded user password
if err := a.db.SetUser(username, user); err != nil {
log.WithError(err).Error("error saving user object for user")
Maybe it would be helpful to know a bit more context:
error saving user after password upgrade
i agree.. i grabbed this from where i could find the save take place.
// Save upgraded user password
if err := s.db.SetUser(username, user); err != nil {
ctx.Error = true
ctx.Message = s.tr(ctx, "ErrorGetUser")
I've no idea what to use instead, but
ErrorGetUser
seems to be misleading.8782383797
tob2109420b6
3 months agoDid some manual testing...
cd923a3e47
to7c9eef44a3
3 months agob0f72b9e9b
into main 3 months agoReviewers
b0f72b9e9b
.