MCPcopy Create free account
hub / github.com/albertobsd/keyhunt / ModExp

Method ModExp

secp256k1/IntMod.cpp:515–525  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

513// ------------------------------------------------
514
515void Int::ModExp(Int *e) {
516 Int base(this);
517 SetInt32(1);
518 uint32_t nbBit = e->GetBitLength();
519 for(int i=0;i<(int)nbBit;i++) {
520 if (e->GetBit(i))
521 ModMul(&base);
522 base.ModMul(&base);
523 }
524
525}
526
527// ------------------------------------------------
528

Callers 2

HasSqrtMethod · 0.80
ModSqrtMethod · 0.80

Calls 3

GetBitLengthMethod · 0.45
GetBitMethod · 0.45
ModMulMethod · 0.45

Tested by

no test coverage detected