#include <BigMontgomery.hpp>
List of all members.
Public Member Functions |
| | BigMontgomery (int regs, int bits) |
| void | CopyModulus (Leg *out) |
| const Leg * | GetModulus () |
| bool | IsRabinMillerPrime (IRandom *prng, const Leg *n, int trials=20) |
| void | MonAdd (const Leg *in_a, const Leg *in_b, Leg *out) |
| void | MonDouble (const Leg *in, Leg *out) |
| void | MonExpMod (const Leg *in_base, const Leg *in_exp, Leg *out) |
| void | MonInput (const Leg *in, Leg *out) |
| void | MonMultiply (const Leg *in_a, const Leg *in_b, Leg *out) |
| void | MonNegate (const Leg *in, Leg *out) |
| void | MonOutput (const Leg *in, Leg *out) |
| void | MonReduceProduct (Leg *inout_product, Leg *out) |
| void | MonSquare (const Leg *in, Leg *out) |
| void | MonSubtract (const Leg *in_a, const Leg *in_b, Leg *out) |
| void | SetModulus (const Leg *mod) |
Protected Attributes |
| Leg * | CachedModulus |
| Leg | mod_inv |
| Leg * | TempProduct |
| Leg * | TempProductHi |
Private Attributes |
| int | mon_regs |
Static Private Attributes |
| static const int | MON_OVERHEAD = 3 + 4 |
Detailed Description
Definition at line 44 of file BigMontgomery.hpp.
Constructor & Destructor Documentation
| cat::BigMontgomery::BigMontgomery |
( |
int |
regs, |
|
|
int |
bits |
|
) |
| |
Member Function Documentation
| void cat::BigMontgomery::CopyModulus |
( |
Leg * |
out | ) |
|
| const Leg* cat::BigMontgomery::GetModulus |
( |
| ) |
[inline] |
| bool cat::BigMontgomery::IsRabinMillerPrime |
( |
IRandom * |
prng, |
|
|
const Leg * |
n, |
|
|
int |
trials = 20 |
|
) |
| |
| void cat::BigMontgomery::MonAdd |
( |
const Leg * |
in_a, |
|
|
const Leg * |
in_b, |
|
|
Leg * |
out |
|
) |
| |
| void cat::BigMontgomery::MonDouble |
( |
const Leg * |
in, |
|
|
Leg * |
out |
|
) |
| |
| void cat::BigMontgomery::MonExpMod |
( |
const Leg * |
in_base, |
|
|
const Leg * |
in_exp, |
|
|
Leg * |
out |
|
) |
| |
| void cat::BigMontgomery::MonInput |
( |
const Leg * |
in, |
|
|
Leg * |
out |
|
) |
| |
| void cat::BigMontgomery::MonMultiply |
( |
const Leg * |
in_a, |
|
|
const Leg * |
in_b, |
|
|
Leg * |
out |
|
) |
| |
| void cat::BigMontgomery::MonNegate |
( |
const Leg * |
in, |
|
|
Leg * |
out |
|
) |
| |
| void cat::BigMontgomery::MonOutput |
( |
const Leg * |
in, |
|
|
Leg * |
out |
|
) |
| |
| void cat::BigMontgomery::MonReduceProduct |
( |
Leg * |
inout_product, |
|
|
Leg * |
out |
|
) |
| |
| void cat::BigMontgomery::MonSquare |
( |
const Leg * |
in, |
|
|
Leg * |
out |
|
) |
| |
| void cat::BigMontgomery::MonSubtract |
( |
const Leg * |
in_a, |
|
|
const Leg * |
in_b, |
|
|
Leg * |
out |
|
) |
| |
| void cat::BigMontgomery::SetModulus |
( |
const Leg * |
mod | ) |
|
Member Data Documentation
The documentation for this class was generated from the following file: