diff --git a/processors/crypto.go b/processors/crypto.go index bb418b2..d9aa8a4 100644 --- a/processors/crypto.go +++ b/processors/crypto.go @@ -234,17 +234,17 @@ func (p Bcrypt) Alias() []string { } func (p Bcrypt) Transform(data []byte, f ...Flag) (string, error) { - var rounds int + var rounds uint for _, flag := range f { if flag.Short == "r" { - r, ok := flag.Value.(int) + r, ok := flag.Value.(uint) if ok { rounds = r } } } - bytes, err := bcrypt.GenerateFromPassword(data, rounds) + bytes, err := bcrypt.GenerateFromPassword(data, int(rounds)) return string(bytes), err }