Skip to content

theAkito/easy-bcrypt

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

39 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Brief Example

Hashing a password:

let passwordHash = hashPw(password, genSalt(12))

Verifying a password:

let savedHash = ...
assert hashPw(password, savedHash) == savedHash

Storing a password in a database:

let passwordString = $passwordHash
dbconn.exec("...", passwordString)

Loading a password from a database:

let password = dbconn.exec(
  "SELECT password FROM users WHERE username = ?;", username)
let passwordSalt = loadPasswordSalt(password)

About

Simple wrapper providing a convenient interface for bcrypt

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • C 68.6%
  • Roff 18.5%
  • Assembly 4.8%
  • Nim 4.3%
  • Makefile 2.9%
  • C++ 0.9%