Tuesday, 20 June 2017

Random number Generation in Crypto++

#include<iostream>
using std::cout;
using std::endl;

#include<cryptopp/integer.h>
using CryptoPP::Integer;

#include<cryptopp/osrng.h>
using CryptoPP::AutoSeededRandomPool;

int main()
{
	// Illustration of generating a random number using AutoSeededRandomPool
	AutoSeededRandomPool rng;
	cout<<Integer(rng,Integer(400),Integer(500))<<endl;
	return 0;
}


No comments:

Post a Comment