Kea 2.7.6
isc::cryptolink::RNG Class Referenceabstract

RNG support. More...

#include <crypto_rng.h>

+ Inheritance diagram for isc::cryptolink::RNG:

Public Member Functions

 RNG ()
 Constructor from a Random Number Generator.
 
virtual ~RNG ()
 Destructor.
 
virtual std::vector< uint8_t > random (size_t len)=0
 Generate random value.
 

Friends

RNGPtr const & CryptoLink::getRNG () const
 

Detailed Description

RNG support.

This class is used to get the RNG. The global instance can be get with CryptoLink::getRNG()

Definition at line 22 of file crypto_rng.h.

Constructor & Destructor Documentation

◆ RNG()

isc::cryptolink::RNG::RNG ( )

Constructor from a Random Number Generator.

Exceptions
LibraryErrorif there was any unexpected exception in the underlying library

Definition at line 19 of file crypto_rng.cc.

◆ ~RNG()

isc::cryptolink::RNG::~RNG ( )
virtual

Destructor.

Definition at line 22 of file crypto_rng.cc.

Member Function Documentation

◆ random()

virtual std::vector< uint8_t > isc::cryptolink::RNG::random ( size_t len)
pure virtual

Generate random value.

The result will be returned as a std::vector<uint8_t>

Exceptions
LibraryErrorif there was any unexpected exception in the underlying library
Parameters
lenThe number of bytes from the result to generate.
Returns
a vector containing random value.

Friends And Related Symbol Documentation

◆ CryptoLink::getRNG

RNGPtr const & CryptoLink::getRNG ( ) const
friend

The documentation for this class was generated from the following files: