aboutsummaryrefslogtreecommitdiff
path: root/src/tests/cryptpass.cpp
blob: 4b090fe1c165207f9f5ba7c49f808c3b68706dad (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#include "bu/crypt.h"
#include "bu/sio.h"

using namespace Bu;

int main( int argc, char *argv[] )
{
	if( argc == 1 )
		sio << "Syntax: " << argv[0] << " <password> [salt]" << sio.nl
			<< sio.nl;
	else if( argc == 2 )
		sio << "Crypt1:  >> " << cryptPass( argv[1] ) << " <<" << sio.nl;
	else
		sio << "Crypt2:  >> " << cryptPass( argv[1], argv[2] ) << " <<" << sio.nl;

	return 0;
}