Botan 3.13.0
Crypto and TLS for C&
Botan::PCurve::PrimeOrderCurve::Scalar Class Referencefinal

#include <pcurves.h>

Public Member Functions

const auto & _curve () const
const auto & _value () const
void _zeroize ()
Scalaroperator= (const Scalar &other)=default
Scalaroperator= (Scalar &&other)=default
 Scalar (const Scalar &other)=default
 Scalar (Scalar &&other)=default
 ~Scalar ()

Static Public Member Functions

static Scalar _create (CurvePtr curve, StorageUnit v)

Detailed Description

Elliptic curve scalar

This refers to the set of integers modulo the (prime) group order of the elliptic curve.

Definition at line 66 of file pcurves.h.

Constructor & Destructor Documentation

◆ Scalar() [1/2]

Botan::PCurve::PrimeOrderCurve::Scalar::Scalar ( const Scalar & other)
default

References Scalar().

Referenced by _create(), operator=(), operator=(), Scalar(), and Scalar().

◆ Scalar() [2/2]

Botan::PCurve::PrimeOrderCurve::Scalar::Scalar ( Scalar && other)
default

References Scalar().

◆ ~Scalar()

Botan::PCurve::PrimeOrderCurve::Scalar::~Scalar ( )
inline

Definition at line 74 of file pcurves.h.

References _zeroize().

Member Function Documentation

◆ _create()

Scalar Botan::PCurve::PrimeOrderCurve::Scalar::_create ( CurvePtr curve,
StorageUnit v )
inlinestatic

Definition at line 82 of file pcurves.h.

82{ return Scalar(std::move(curve), v); }
Scalar(const Scalar &other)=default

References Scalar().

◆ _curve()

const auto & Botan::PCurve::PrimeOrderCurve::Scalar::_curve ( ) const
inline

Definition at line 78 of file pcurves.h.

78{ return m_curve; }

◆ _value()

const auto & Botan::PCurve::PrimeOrderCurve::Scalar::_value ( ) const
inline

Definition at line 80 of file pcurves.h.

80{ return m_value; }

◆ _zeroize()

void Botan::PCurve::PrimeOrderCurve::Scalar::_zeroize ( )

Definition at line 16 of file pcurves.cpp.

16 {
17 secure_zeroize_buffer(m_value.data(), m_value.size() * sizeof(word));
18}
void secure_zeroize_buffer(void *ptr, size_t n)
Definition mem_utils.cpp:29
std::conditional_t< HasNative64BitRegisters, std::uint64_t, uint32_t > word
The native machine word, used as the limb type for multiprecision integers.
Definition types.h:131

References Botan::secure_zeroize_buffer().

Referenced by ~Scalar().

◆ operator=() [1/2]

Scalar & Botan::PCurve::PrimeOrderCurve::Scalar::operator= ( const Scalar & other)
default

References Scalar().

◆ operator=() [2/2]

Scalar & Botan::PCurve::PrimeOrderCurve::Scalar::operator= ( Scalar && other)
default

References Scalar().


The documentation for this class was generated from the following files: