osb/source/core/StarSecureRandom_unix.cpp
2023-06-20 14:33:09 +10:00

11 lines
191 B
C++

#include "StarSecureRandom.hpp"
#include "StarFile.hpp"
namespace Star {
ByteArray secureRandomBytes(size_t size) {
return File::open("/dev/urandom", IOMode::Read)->readBytes(size);
}
}