Orbit Framework 2.0.0
A high-performance asynchronous C++20 HTTP server framework.
Loading...
Searching...
No Matches
Random.hpp File Reference
#include <orbit/legacy_namespaces.hpp>
#include <openssl/crypto.h>
#include <openssl/rand.h>
#include <stdexcept>
#include <string>
#include <string_view>
#include <vector>
Include dependency graph for Random.hpp:

Go to the source code of this file.

Namespaces

namespace  orbit
 
namespace  orbit::utils
 

Functions

std::string orbit::utils::secure_random_hex (size_t num_bytes)
 Returns num_bytes of cryptographically secure randomness, hex-encoded.
 
bool orbit::utils::constant_time_equals (std::string_view a, std::string_view b)
 Compares two secrets in time independent of where they differ.