bcrypt

Wraps the bcrypt (blowfish) library for creating encrypted hashes (useful for passwords)

Pure Nim score 15/100 · tests present · no docs generated

Summary

Latest Version Unknown
License BSD
CI Status Failing
Downloads 0
Last Indexed 2026-07-21 05:23

Installation

nimble install bcrypt
choosenim install bcrypt
git clone https://github.com/ithkuil/bcryptnim/

OS Compatibility

Platform Linux macOS Windows FreeBSD OpenBSD NetBSD Android iOS WASM Embedded
bcrypt - - - - - - -

Source

Repository https://github.com/ithkuil/bcryptnim/
Homepage https://www.github.com/ithkuil/bcryptnim/
Registry Source nimble_official

README

bcrypt

This is a Nimrod wrapper for the bcrypt C functions. It also includes some BSD code for arc4random.
Since these are FreeBSD/OpenBSD code files, the license is BSD, or as stated at the top of the source files. "This product includes software developed by Niels Provos."

bcrypt is useful for hashing passwords.

Usage example:

import bcrypt, os

var salt = ""

if existsFile("salt"):
  salt = readFile("salt")
else:
  salt = genSalt(10)
  writeFile("salt", salt)

echo("salt is " & salt)

echo("Hashed password: ", hash("myPaSword2",salt))