Added mod_word.
This commit is contained in:
parent
5f76f1cb62
commit
33f3c966ac
|
|
@ -255,6 +255,7 @@ extern "C" {
|
|||
pub fn BN_mod_sub(r: *mut BIGNUM, a: *mut BIGNUM, b: *mut BIGNUM, m: *mut BIGNUM, ctx: *mut BN_CTX) -> c_int;
|
||||
pub fn BN_mul(r: *mut BIGNUM, a: *mut BIGNUM, b: *mut BIGNUM, ctx: *mut BN_CTX) -> c_int;
|
||||
pub fn BN_nnmod(rem: *mut BIGNUM, a: *mut BIGNUM, m: *mut BIGNUM, ctx: *mut BN_CTX) -> c_int;
|
||||
pub fn BN_mod_word(r: *mut BIGNUM, w: c_ulong) -> c_ulong;
|
||||
pub fn BN_sqr(r: *mut BIGNUM, a: *mut BIGNUM, ctx: *mut BN_CTX) -> c_int;
|
||||
pub fn BN_sub(r: *mut BIGNUM, a: *mut BIGNUM, b: *mut BIGNUM) -> c_int;
|
||||
|
||||
|
|
|
|||
|
|
@ -145,13 +145,11 @@ impl BigNum {
|
|||
}
|
||||
}
|
||||
|
||||
/*XXX
|
||||
pub fn mod_word(&self, w: c_ulong) -> c_ulong {
|
||||
unsafe {
|
||||
BN_mod_word(self.raw(), w)
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
pub fn checked_gcd(&self, a: &BigNum) -> Result<BigNum, SslError> {
|
||||
unsafe {
|
||||
|
|
|
|||
Loading…
Reference in New Issue