AutoSeedBlockCtrRandom class

An implementation of SecureRandom that uses a BlockCipher with CTR mode to generate random values and automatically self reseeds itself after each request for data, in order to achieve forward security. See section 4.1 of the paper: Practical Random Number Generation in Software (by John Viega).

Implemented types

Constructors

AutoSeedBlockCtrRandom(BlockCipher cipher, [bool _reseedIV = true])

Properties

algorithmName String
Get this algorithm's standard name.
no setteroverride
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

nextBigInteger(int bitLength) BigInt
Get a random BigInteger of bitLength bits.
override
nextBytes(int count) Uint8List
Get a list of bytes of arbitrary length.
override
nextUint16() int
Get two bytes long random int.
override
nextUint32() int
Get four bytes long random int.
override
nextUint8() int
Get one byte long random int.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
seed(CipherParameters params) → void
Seed the RNG with some entropy (look at package cipher_entropy providing entropy sources).
override
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

factoryConfig → FactoryConfig
Intended for internal use.
final