Registry / utility / bitcoinleveldb-rand

bitcoinleveldb-rand

JSON →
library0.1.19rscratesunverified

Deterministic LevelDB-compatible Park–Miller pseudo-random number generator for tests and internal randomized decisions; small, fast, and non-cryptographic.

# Cargo.toml [dependencies] bitcoinleveldb-rand = "0.1.19"
INSTALL
IMPORT
SIG · BITCOINLEVELDB-RAN
B
bitcoinleveldb-rand
utilityrustv0.1.19
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Random
use bitcoinleveldb_rand::Random;

Creates a deterministic random number generator.

use bitcoinleveldb_rand::Random; fn main() { let mut rng = Random::new(42); println!("{}", rng.next()); }
Debug
Known issues
gotchaNot cryptographically secure; do not use for security purposes.
fix
Use a cryptographic RNG like rand::rngs::OsRng for security.
affects: >=0.1.0
Upgrade
Version history
0.1.19latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
9 hits · last 30 days
node
8
Meta
1
Resources
bitcoinleveldb-rand — cargo add bitcoinleveldb-rand · libregistry