Loading...
Searching...
No Matches
lime::bctbx_EDDSA< Curve > Class Template Reference

a wrapper around bctoolbox signature algorithms, implements the Signature interface More...

Inheritance diagram for lime::bctbx_EDDSA< Curve >:

## Public Member Functions

const DSA< Curve, lime::DSAtype::privateKey > | get_secret (void) override
| Secret key.
const DSA< Curve, lime::DSAtype::publicKey > | get_public (void) override
| Public key.
void | set_secret (const DSA< Curve, lime::DSAtype::privateKey > &secretKey) override
| Secret key.
void | set_public (const DSA< Curve, lime::DSAtype::publicKey > &publicKey) override
| Public key.
void | createKeyPair (std::shared_ptr< lime::RNG > rng) override
| generate a new random EdDSA key pair
void | derivePublic (void) override
| Compute the public key using the secret already set in context.
void | sign (const std::vector< uint8_t > &message, DSA< Curve, lime::DSAtype::signature > &signature) override
| Sign a message using the key pair previously set in the object.
void | sign (const X< Curve, lime::Xtype::publicKey > &message, DSA< Curve, lime::DSAtype::signature > &signature) override
bool | verify (const std::vector< uint8_t > &message, const DSA< Curve, lime::DSAtype::signature > &signature) override
| Verify a message signature using the public key previously set in the object.
bool | verify (const X< Curve, lime::Xtype::publicKey > &message, const DSA< Curve, lime::DSAtype::signature > &signature) override
| bctbx_EDDSA ()
| ~bctbx_EDDSA ()
Public Member Functions inherited from lime::Signature< Curve >
virtual | ~Signature ()=default

## Detailed Description

template<typename Curve>
class lime::bctbx_EDDSA< Curve >

a wrapper around bctoolbox signature algorithms, implements the Signature interface

Provides EdDSA on curves 25519 and 448

## Constructor & Destructor Documentation

## bctbx_EDDSA()

template<typename Curve>

lime::bctbx_EDDSA< Curve >::bctbx_EDDSA | ( |  | ) |

inline

## ~bctbx_EDDSA()

template<typename Curve>

lime::bctbx_EDDSA< Curve >::~bctbx_EDDSA | ( |  | ) |

inline

## Member Function Documentation

## createKeyPair()

template<typename Curve>

void lime::bctbx_EDDSA< Curve >::createKeyPair | ( | std::shared_ptr< lime::RNG > | rng | ) |

inline override virtual

generate a new random EdDSA key pair

Parameters

  [in] | rng | The Random Number Generator to be used to generate the private kay

Implements lime::Signature< Curve >.

## derivePublic()

template<typename Curve>

void lime::bctbx_EDDSA< Curve >::derivePublic | ( | void |  | ) |

inline override virtual

Compute the public key using the secret already set in context.

Implements lime::Signature< Curve >.

## get_public()

template<typename Curve>

const DSA< Curve, lime::DSAtype::publicKey > lime::bctbx_EDDSA< Curve >::get_public | ( | void |  | ) |

inline override virtual

Public key.

Implements lime::Signature< Curve >.

## get_secret()

template<typename Curve>

const DSA< Curve, lime::DSAtype::privateKey > lime::bctbx_EDDSA< Curve >::get_secret | ( | void |  | ) |

inline override virtual

Secret key.

Implements lime::Signature< Curve >.

## set_public()

template<typename Curve>

void lime::bctbx_EDDSA< Curve >::set_public | ( | const DSA< Curve, lime::DSAtype::publicKey > & | publicKey | ) |

inline override virtual

Public key.

Implements lime::Signature< Curve >.

## set_secret()

template<typename Curve>

void lime::bctbx_EDDSA< Curve >::set_secret | ( | const DSA< Curve, lime::DSAtype::privateKey > & | secretKey | ) |

inline override virtual

Secret key.

Implements lime::Signature< Curve >.

## sign() [1/2]

template<typename Curve>

void lime::bctbx_EDDSA< Curve >::sign | ( | const std::vector< uint8_t > & | message,
|  | DSA< Curve, lime::DSAtype::signature > & | signature )

inline override virtual

Sign a message using the key pair previously set in the object.

Parameters

  [in] | message | The message to be signed (we can sign any vector or more specifically a key exchange public key)
  [out] | signature | The signature produced from the message with a key pair previously introduced in the object

Implements lime::Signature< Curve >.

## sign() [2/2]

template<typename Curve>

void lime::bctbx_EDDSA< Curve >::sign | ( | const X< Curve, lime::Xtype::publicKey > & | message,
|  | DSA< Curve, lime::DSAtype::signature > & | signature )

inline override virtual

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

a convenience function to directly verify a key exchange public key

Implements lime::Signature< Curve >.

## verify() [1/2]

template<typename Curve>

bool lime::bctbx_EDDSA< Curve >::verify | ( | const std::vector< uint8_t > & | message,
|  | const DSA< Curve, lime::DSAtype::signature > & | signature )

inline override virtual

Verify a message signature using the public key previously set in the object.

Parameters

  [in] | message | The message signed (we can verify any vector or more specifically a key exchange public key)
  [in] | signature | The signature produced from the message with a key pair previously introduced in the object

Returns
  true if the signature is valid, false otherwise

Implements lime::Signature< Curve >.

## verify() [2/2]

template<typename Curve>

bool lime::bctbx_EDDSA< Curve >::verify | ( | const X< Curve, lime::Xtype::publicKey > & | message,
|  | const DSA< Curve, lime::DSAtype::signature > & | signature )

inline override virtual

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

a convenience function to directly verify a key exchange public key

Implements lime::Signature< Curve >.

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

- /build/lime-OjNHTX/lime-5.3.105+dfsg/src/lime_crypto_primitives.cpp