|
Botan
2.13.0
Crypto and TLS for C++11
|
#include <monty.h>
|
inline |
Create a zero-initialized Montgomery_Int
Definition at line 27 of file monty.h.
Referenced by additive_inverse(), mul(), multiplicative_inverse(), operator*(), operator+(), operator-(), and square().
| Botan::Montgomery_Int::Montgomery_Int | ( | std::shared_ptr< const Montgomery_Params > | params, |
| const BigInt & | v, | ||
| bool | redc_needed = true |
||
| ) |
| Botan::Montgomery_Int::Montgomery_Int | ( | std::shared_ptr< const Montgomery_Params > | params, |
| const uint8_t | bits[], | ||
| size_t | len, | ||
| bool | redc_needed = true |
||
| ) |
| Botan::Montgomery_Int::Montgomery_Int | ( | std::shared_ptr< const Montgomery_Params > | params, |
| const word | words[], | ||
| size_t | len, | ||
| bool | redc_needed = true |
||
| ) |
| Montgomery_Int & Botan::Montgomery_Int::add | ( | const Montgomery_Int & | other, |
| secure_vector< word > & | ws | ||
| ) |
Definition at line 339 of file monty.cpp.
References Botan::BigInt::mod_add().
Referenced by operator+=().
| Montgomery_Int Botan::Montgomery_Int::additive_inverse | ( | ) | const |
Definition at line 420 of file monty.cpp.
References Montgomery_Int().
|
inline |
|
inline |
| void Botan::Montgomery_Int::fix_size | ( | ) |
Definition at line 268 of file monty.cpp.
References Botan::BigInt::get_word_vector(), and Botan::BigInt::sig_words().
| bool Botan::Montgomery_Int::is_one | ( | ) | const |
| bool Botan::Montgomery_Int::is_zero | ( | ) | const |
| Montgomery_Int Botan::Montgomery_Int::mul | ( | const Montgomery_Int & | other, |
| secure_vector< word > & | ws | ||
| ) | const |
Definition at line 363 of file monty.cpp.
References Montgomery_Int().
Referenced by Botan::monty_multi_exp().
| Montgomery_Int & Botan::Montgomery_Int::mul_by | ( | const Montgomery_Int & | other, |
| secure_vector< word > & | ws | ||
| ) |
Definition at line 369 of file monty.cpp.
Referenced by Botan::monty_multi_exp(), and operator*=().
| Montgomery_Int & Botan::Montgomery_Int::mul_by | ( | const secure_vector< word > & | other, |
| secure_vector< word > & | ws | ||
| ) |
| Montgomery_Int & Botan::Montgomery_Int::mul_by_2 | ( | secure_vector< word > & | ws | ) |
Definition at line 425 of file monty.cpp.
References Botan::BigInt::mod_mul().
| Montgomery_Int & Botan::Montgomery_Int::mul_by_3 | ( | secure_vector< word > & | ws | ) |
Definition at line 431 of file monty.cpp.
References Botan::BigInt::mod_mul().
| Montgomery_Int & Botan::Montgomery_Int::mul_by_4 | ( | secure_vector< word > & | ws | ) |
Definition at line 437 of file monty.cpp.
References Botan::BigInt::mod_mul().
| Montgomery_Int & Botan::Montgomery_Int::mul_by_8 | ( | secure_vector< word > & | ws | ) |
Definition at line 443 of file monty.cpp.
References Botan::BigInt::mod_mul().
| Montgomery_Int Botan::Montgomery_Int::multiplicative_inverse | ( | ) | const |
Definition at line 413 of file monty.cpp.
References Montgomery_Int().
|
inline |
| Montgomery_Int Botan::Montgomery_Int::operator* | ( | const Montgomery_Int & | other | ) | const |
Definition at line 357 of file monty.cpp.
References Montgomery_Int().
| Montgomery_Int & Botan::Montgomery_Int::operator*= | ( | const Montgomery_Int & | other | ) |
Definition at line 383 of file monty.cpp.
References mul_by().
| Montgomery_Int & Botan::Montgomery_Int::operator*= | ( | const secure_vector< word > & | other | ) |
Definition at line 389 of file monty.cpp.
References mul_by().
| Montgomery_Int Botan::Montgomery_Int::operator+ | ( | const Montgomery_Int & | other | ) | const |
Definition at line 317 of file monty.cpp.
References Botan::BigInt::mod_add(), and Montgomery_Int().
| Montgomery_Int & Botan::Montgomery_Int::operator+= | ( | const Montgomery_Int & | other | ) |
Definition at line 333 of file monty.cpp.
References add().
| Montgomery_Int Botan::Montgomery_Int::operator- | ( | const Montgomery_Int & | other | ) | const |
Definition at line 325 of file monty.cpp.
References Botan::BigInt::mod_sub(), and Montgomery_Int().
| Montgomery_Int & Botan::Montgomery_Int::operator-= | ( | const Montgomery_Int & | other | ) |
Definition at line 345 of file monty.cpp.
References sub().
| bool Botan::Montgomery_Int::operator== | ( | const Montgomery_Int & | other | ) | const |
|
inline |
| std::vector< uint8_t > Botan::Montgomery_Int::serialize | ( | ) | const |
Definition at line 289 of file monty.cpp.
References Botan::BigInt::encode_1363(), size(), and value().
| size_t Botan::Montgomery_Int::size | ( | ) | const |
Definition at line 296 of file monty.cpp.
Referenced by serialize().
| Montgomery_Int Botan::Montgomery_Int::square | ( | secure_vector< word > & | ws | ) | const |
Definition at line 408 of file monty.cpp.
References Montgomery_Int().
Referenced by Botan::monty_multi_exp().
| Montgomery_Int & Botan::Montgomery_Int::square_this | ( | secure_vector< word > & | ws | ) |
Definition at line 402 of file monty.cpp.
Referenced by Botan::monty_multi_exp().
| Montgomery_Int & Botan::Montgomery_Int::square_this_n_times | ( | secure_vector< word > & | ws, |
| size_t | n | ||
| ) |
| Montgomery_Int & Botan::Montgomery_Int::sub | ( | const Montgomery_Int & | other, |
| secure_vector< word > & | ws | ||
| ) |
Definition at line 351 of file monty.cpp.
References Botan::BigInt::mod_sub().
Referenced by operator-=().
| BigInt Botan::Montgomery_Int::value | ( | ) | const |
Return the value to normal mod-p space
Definition at line 311 of file monty.cpp.
Referenced by Botan::monty_multi_exp(), and serialize().
1.8.9.1