14#ifndef OPENVPN_SSL_PSID_H
15#define OPENVPN_SSL_PSID_H
45 template <
typename BufType>
58 template <
typename BufType>
95 std::string
str()
const
void prepend(const T *data, const size_t size)
Prepend data to the buffer.
void write(const T *data, const size_t size)
Write data to the buffer.
bool match(const ProtoSessionID &other) const
const Buffer get_buf() const
void write(Buffer &buf) const
constexpr bool defined() const
void randomize(StrongRandomAPI &rng)
void prepend(Buffer &buf) const
constexpr ProtoSessionID()
ProtoSessionID(BufType &buf)
virtual void rand_bytes(unsigned char *buf, size_t size)=0
Fill a buffer with random bytes.
Abstract base class for cryptographically strong random number generators.
bool memneq(const void *a, const void *b, size_t size)
BufferType< unsigned char > Buffer
std::string render_hex(const unsigned char *data, size_t size, const bool caps=false)
PsidBuf(typename Buffer::type id)