container: root: macro: add bitcoin plugin support
- Adds support to existing macros for bitcoin's RNG via `dfi`'s `Random` * Currently only supports one of bitcoin's RNG's (`FastRandomContext`)
This commit is contained in:
@@ -351,6 +351,15 @@ class Random final
|
||||
|
||||
const std::string timestamp{common::make_timestamp()};
|
||||
|
||||
#ifdef __DFI_PLUGIN_BITCOIN__
|
||||
data.title = "Bitcoin_FastRandomContext_32_RNG_" + timestamp;
|
||||
random(data, []() -> uint32_t {
|
||||
return common::crypto::bitcoin::g_Random->generate();
|
||||
});
|
||||
|
||||
// TODO(afiore): uint64_t (requires canvas-related refactor)
|
||||
#endif
|
||||
|
||||
data.title = "Botan_RNG_" + timestamp;
|
||||
random(data, []() -> uint32_t {
|
||||
return common::crypto::botan::g_Random->generate();
|
||||
|
||||
Reference in New Issue
Block a user