diff options
Diffstat (limited to 'mpi.cpp')
-rw-r--r-- | mpi.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -108,6 +108,8 @@ Mpi Mpi::operator^(const Mpi &b) const return res; } +// bit manipulation + void Mpi::rShift(u_int8_t n) { gcry_mpi_rshift(val_, val_, n); @@ -120,6 +122,11 @@ Mpi Mpi::mul2exp(u_int32_t e) const return res; } +void Mpi::clearHighBit(u_int32_t n) +{ + gcry_mpi_clear_highbit( val_, n ); +} + Buffer Mpi::getBuf() const { u_int32_t len = 0, written = 0; |