12 lines
183 B
Go
12 lines
183 B
Go
package crypto
|
|
|
|
import "crypto/bcrypt"
|
|
|
|
func test() {
|
|
hash, err := bcrypt.GenerateFromPassword(pwd, bcrypt.DefaultCost)
|
|
if err != nil {
|
|
panic(err)
|
|
}
|
|
fmt.Println(string(hash))
|
|
}
|