Files
Bcrypt.cpp/test/main.cpp
Christoph Hilchenbach 1107d7bcb4 changed interface
2019-12-27 16:27:39 +01:00

20 lines
428 B
C++

#include "bcrypt.h"
#include <iostream>
#include <string>
int main()
{
std::string password = "top_secret";
std::string hash = bcrypt::generateHash(password);
std::cout << "Hash: " << hash << std::endl;
std::cout << "\"" << password << "\" : " << bcrypt::validatePassword(password,hash) << std::endl;
std::cout << "\"wrong\" : " << bcrypt::validatePassword("wrong",hash) << std::endl;
return 0;
}