mirror of
https://github.com/allankoechke/Bcrypt.cpp.git
synced 2026-12-02 09:03:39 +00:00
Update README.md
This commit is contained in:
committed by
GitHub
parent
f68da11b6e
commit
ce8a29b13e
21
README.md
21
README.md
@@ -1,2 +1,21 @@
|
||||
# Bcrypt.cpp
|
||||
A c++ wrapper around bcrypt password hashing
|
||||
A c++ wrapper around bcrypt (origin: Open BSD) password hashing
|
||||
|
||||
## How to use
|
||||
|
||||
Here an example how to use this wrapper class
|
||||
|
||||
```cpp
|
||||
#include "bcrypt.h"
|
||||
#include <iostream>
|
||||
|
||||
int main(){
|
||||
std::string password = "test";
|
||||
std::string hash = BCrypt::generateHash(password);
|
||||
|
||||
std::cout << BCrypt::validatePassword(password,hash) << std::endl;
|
||||
std::cout << BCrypt::validatePassword("test1",hash) << std::endl;
|
||||
|
||||
return 0;
|
||||
}
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user