|
|
| Scalar (uint64_t w) DECAF_NOEXCEPT |
| | Set to an unsigned word.
|
| |
|
| Scalar (int64_t w) DECAF_NOEXCEPT |
| | Set to a signed word.
|
| |
|
| Scalar (unsigned int w) DECAF_NOEXCEPT |
| | Set to an unsigned word.
|
| |
|
| Scalar (int w) DECAF_NOEXCEPT |
| | Set to a signed word.
|
| |
|
| Scalar (Rng &rng) DECAF_NOEXCEPT |
| | Construct from RNG.
|
| |
|
| Scalar (const Wrapped &t=decaf_255_scalar_zero) DECAF_NOEXCEPT |
| | Construct from decaf_scalar_t object.
|
| |
|
| Scalar (const Scalar &x) DECAF_NOEXCEPT |
| | Copy constructor.
|
| |
|
| Scalar (const Block &buffer) DECAF_NOEXCEPT |
| | Construct from arbitrary-length little-endian byte sequence.
|
| |
|
size_t | ser_size () const DECAF_NOEXCEPT |
| | Serializable instance.
|
| |
|
void | serialize_into (unsigned char *buffer) const DECAF_NOEXCEPT |
| | Serializable instance.
|
| |
|
Scalar & | operator= (const Scalar &x) DECAF_NOEXCEPT |
| | Assignment.
|
| |
|
Scalar & | operator= (uint64_t w) DECAF_NOEXCEPT |
| | Assign from unsigned 64-bit integer.
|
| |
|
Scalar & | operator= (int64_t w) DECAF_NOEXCEPT |
| | Assign from signed int.
|
| |
|
Scalar & | operator= (unsigned int w) DECAF_NOEXCEPT |
| | Assign from unsigned int.
|
| |
|
Scalar & | operator= (int w) DECAF_NOEXCEPT |
| | Assign from signed int.
|
| |
|
| ~Scalar () DECAF_NOEXCEPT |
| | Destructor securely zeorizes the scalar.
|
| |
|
Scalar & | operator= (const Block &bl) DECAF_NOEXCEPT |
| | Assign from arbitrary-length little-endian byte sequence in a Block.
|
| |
|
Scalar | operator+ (const Scalar &q) const DECAF_NOEXCEPT |
| | Add.
|
| |
|
Scalar & | operator+= (const Scalar &q) DECAF_NOEXCEPT |
| | Add to this.
|
| |
|
Scalar | operator- (const Scalar &q) const DECAF_NOEXCEPT |
| | Subtract.
|
| |
|
Scalar & | operator-= (const Scalar &q) DECAF_NOEXCEPT |
| | Subtract from this.
|
| |
|
Scalar | operator* (const Scalar &q) const DECAF_NOEXCEPT |
| | Multiply.
|
| |
|
Scalar & | operator*= (const Scalar &q) DECAF_NOEXCEPT |
| | Multiply into this.
|
| |
|
Scalar | operator- () const DECAF_NOEXCEPT |
| | Negate.
|
| |
| Scalar | inverse () const |
| | Return 1/this. More...
|
| |
| decaf_error_t DECAF_WARN_UNUSED | inverse_noexcept (Scalar &r) const DECAF_NOEXCEPT |
| | Invert with Fermat's Little Theorem (slow!). More...
|
| |
| Scalar | operator/ (const Scalar &q) const |
| | Return this/q. More...
|
| |
| Scalar & | operator/= (const Scalar &q) |
| | Set this to this/q. More...
|
| |
| Scalar | half () const |
| | Return half this scalar. More...
|
| |
|
bool | operator!= (const Scalar &q) const DECAF_NOEXCEPT |
| | Compare in constant time.
|
| |
|
bool | operator== (const Scalar &q) const DECAF_NOEXCEPT |
| | Compare in constant time.
|
| |
|
Point | operator* (const Point &q) const DECAF_NOEXCEPT |
| | Scalarmul with scalar on left.
|
| |
|
Point | operator* (const Precomputed &q) const DECAF_NOEXCEPT |
| | Scalarmul-precomputed with scalar on left.
|
| |
| SecureBuffer | direct_scalarmul (const FixedBlock< SER_BYTES > &in, decaf_bool_t allow_identity=DECAF_FALSE, decaf_bool_t short_circuit=DECAF_TRUE) const |
| | Direct scalar multiplication. More...
|
| |
|
decaf_error_t DECAF_WARN_UNUSED | direct_scalarmul_noexcept (FixedBuffer< SER_BYTES > &out, const FixedBlock< SER_BYTES > &in, decaf_bool_t allow_identity=DECAF_FALSE, decaf_bool_t short_circuit=DECAF_TRUE) const DECAF_NOEXCEPT |
| | Direct scalar multiplication.
|
| |
|
size_t | ser_size () const DECAF_NOEXCEPT |
| | Return the number of bytes needed to serialize this object.
|
| |
|
void | serialize_into (unsigned char *buf) const DECAF_NOEXCEPT |
| | Serialize this object into a buffer.
|
| |
|
SecureBuffer | serialize () const |
| | Serialize this object into a SecureBuffer and return it.
|
| |
A scalar modulo the curve order.
Supports the usual arithmetic operations, all in constant time.