Created
January 25, 2022 22:19
-
-
Save jonasermert/603548ab1608076b1245bbd03c732e33 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
author: Jonas Ermert | |
year: 2022 | |
*/ | |
package main | |
import ( | |
"fmt" | |
"golang.org/x/crypto/bcrypt" | |
) | |
// main implements a function to generate passwords | |
func main() { | |
password := "password" | |
hashedPassword, _ := bcrypt.GenerateFromPassword([]byte(password), 12) | |
fmt.Println(string(hashedPassword)) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment