MCPcopy Create free account
hub / github.com/FirebirdSQL/firebird / genServerKey

Method genServerKey

src/auth/SecureRemotePassword/srp.cpp:112–123  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

110}
111
112void RemotePassword::genServerKey(string& pubkey, const Firebird::UCharBuffer& verifier)
113{
114 dumpIt("privateKey(S)", privateKey);
115 BigInteger gb(group->generator.modPow(privateKey, group->prime)); // g^b
116 dumpIt("gb", gb);
117 BigInteger v(verifier); // v
118 BigInteger kv = (group->k * v) % group->prime;
119 dumpIt("kv", kv);
120 serverPublicKey = (kv + gb) % group->prime;
121 serverPublicKey.getText(pubkey);
122 dumpIt("serverPublicKey", serverPublicKey);
123}
124
125void RemotePassword::computeScramble()
126{

Callers 2

runTestFunction · 0.80
authenticateMethod · 0.80

Calls 3

modPowMethod · 0.80
dumpItFunction · 0.70
getTextMethod · 0.45

Tested by 1

runTestFunction · 0.64