6 NAMESPACE_BEGIN(CryptoPP)
10 maxBits(BitPrecision(n.BitCount())-1)
12 current = modn.Square(modn.Square(seed));
20 current = modn.Square(current);
24 return current.
GetBit(--bitsLeft);
30 for (
int i=0; i<8; i++)
56 Integer i(Integer::POSITIVE, index);
58 Integer e = a_exp_b_mod_c (2, i / maxBits + 1, (p-1)*(q-1));
59 current = modn.Exponentiate(x0, e);
60 bitsLeft = maxBits - i % maxBits;
bool GetBit(size_t i) const
return the i-th bit, i=0 being the least significant bit
void ProcessData(byte *outString, const byte *inString, size_t length)
encrypt or decrypt an array of bytes of specified length
void Seek(lword index)
for random access ciphers, seek to an absolute position
unsigned int GenerateBit()
generate new random bit and return it
byte GenerateByte()
generate new random byte and return it
void GenerateBlock(byte *output, size_t size)
generate random array of bytes
multiple precision integer and basic arithmetics
BlumBlumShub without factorization of the modulus.