Kea
1.5.0
crypto_rng.h
Go to the documentation of this file.
1
// Copyright (C) 2018 Internet Systems Consortium, Inc. ("ISC")
2
//
3
// This Source Code Form is subject to the terms of the Mozilla Public
4
// License, v. 2.0. If a copy of the MPL was not distributed with this
5
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
6
7
#include <boost/noncopyable.hpp>
8
9
#include <
cryptolink/cryptolink.h
>
10
11
#ifndef ISC_CRYPTO_RNG_H
12
#define ISC_CRYPTO_RNG_H
13
14
namespace
isc
{
15
namespace
cryptolink {
16
22
class
RNG
:
private
boost::noncopyable {
23
public
:
28
RNG
();
29
31
virtual
~RNG
();
32
42
virtual
std::vector<uint8_t>
random
(
size_t
len) = 0;
43
44
private
:
45
friend
RNGPtr
&
CryptoLink::getRNG
();
46
};
47
58
std::vector<uint8_t>
random
(
size_t
len);
59
60
}
// namespace cryptolink
61
}
// namespace isc
62
63
#endif // ISC_CRYPTO_RNG_H
64
isc::cryptolink::RNG::random
virtual std::vector< uint8_t > random(size_t len)=0
Generate random value.
isc::cryptolink::RNG::RNG
RNG()
Constructor from a Random Number Generator.
Definition:
crypto_rng.cc:19
isc::cryptolink::RNG
RNG support.
Definition:
crypto_rng.h:22
isc
Defines the logger used by the top-level component of kea-dhcp-ddns.
Definition:
agent_parser.cc:144
isc::cryptolink::RNGPtr
boost::shared_ptr< RNG > RNGPtr
Definition:
cryptolink.h:46
cryptolink.h
isc::cryptolink::RNG::~RNG
virtual ~RNG()
Destructor.
Definition:
crypto_rng.cc:22
isc::cryptolink::CryptoLink::getRNG
virtual RNGPtr & getRNG()
Get the global RNG.
Definition:
cryptolink.cc:45
isc::cryptolink::random
std::vector< uint8_t > random(size_t len)
Generate random value.
Definition:
crypto_rng.cc:26
src
lib
cryptolink
crypto_rng.h
Generated on Fri Jul 10 2020 09:12:51 for Kea by
1.8.18