Skip to content

Commit

Permalink
Merge pull request #3 from reecerussell/remove-debug-log
Browse files Browse the repository at this point in the history
Remove debug log
  • Loading branch information
reecerussell committed Jan 2, 2022
2 parents 308af37 + 609bfc3 commit da31d6f
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 5 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ module github.com/reecerussell/adaptive-password-hasher
go 1.14

require (
github.com/golang/mock v1.4.4 // indirect
github.com/golang/mock v1.4.4
golang.org/x/crypto v0.0.0-20200604202706-70a84ac30bf9
)
4 changes: 0 additions & 4 deletions hasher.go
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,6 @@ func (h *hasher) Verify(pwd, hash []byte) (ok bool) {
}

hashFunc, iterCnt, saltLen := scanHeader(hash)
fmt.Printf("%d < %d\n", saltLen, h.saltSize)
if saltLen < h.saltSize {
// saltLen must be >= to the hasher's salt size.
return false
Expand Down Expand Up @@ -192,13 +191,10 @@ func scanHeader(buf []byte) (hashAlg func() hash.Hash, iterCnt, saltSize int) {
switch i {
case 1:
hashAlg = alg(v)
break
case 5:
iterCnt = v
break
case 9:
saltSize = v
break
}
}

Expand Down

0 comments on commit da31d6f

Please sign in to comment.