MCPcopy Create free account
hub / github.com/Tripwire/tripwire-open-source / GetByte

Method GetByte

src/cryptlib/rng.cpp:35–48  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

33#endif
34
35byte LC_RNG::GetByte()
36{
37 word32 hi = seed/q;
38 word32 lo = seed%q;
39
40 long test = a*lo - r*hi;
41
42 if (test > 0)
43 seed = test;
44 else
45 seed = test+ m;
46
47 return (seedBytes[0] ^ seedBytes[1] ^ seedBytes[2] ^ seedBytes[3]);
48}
49
50// ********************************************************
51

Callers

nothing calls this directly

Calls 2

xorbufFunction · 0.85
ProcessBlockMethod · 0.45

Tested by

no test coverage detected