MCPcopy
hub / github.com/daptin/daptin / BcryptCheckStringHash

Function BcryptCheckStringHash

server/auth/auth.go:205–208  ·  view source on GitHub ↗
(newString, hash string)

Source from the content-addressed store, hash-verified

203}
204
205func BcryptCheckStringHash(newString, hash string) bool {
206 err := bcrypt.CompareHashAndPassword([]byte(hash), []byte(newString))
207 return err == nil
208}
209
210func AuthVersionFromValue(value interface{}) (int64, bool) {
211 switch v := value.(type) {

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected