esp8266ndn
NDN Arduino library for ESP8266 and more
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Classes | Namespaces | Typedefs | Functions
ec.hpp File Reference
#include "../port/ec/port.hpp"
#include "certificate.hpp"
#include "keychain.hpp"

Go to the source code of this file.

Classes

class  ndnph::ec::EcPublicKey
 EC public key. More...
 
class  ndnph::ec::EcPrivateKey
 EC private key. More...
 
struct  ndnph::ec::detail::StoredKeyPair
 Key pair stored in KeyChain. More...
 

Namespaces

 ndnph
 
 ndnph::ec
 
 ndnph::ec::detail
 

Typedefs

using ndnph::ec::detail::PvtLen = port::Ec::Curve::PvtLen
 
using ndnph::ec::detail::PubLen = port::Ec::Curve::PubLen
 
using ndnph::EcPublicKey = ec::EcPublicKey
 
using ndnph::EcPrivateKey = ec::EcPrivateKey
 

Functions

tlv::Value ndnph::ec::detail::getSpkiHeader ()
 Return EC P-256 SPKI except the key. More...
 
tlv::Value ndnph::ec::detail::getOid ()
 Return '1.2.840.10045.2.1 ecPublicKey' OID bytes. More...
 
const uint8_t * ndnph::ec::detail::findPublicKeyInCertificate (const Data &data)
 Extract raw public key from a certificate. More...
 
bool ndnph::ec::generateRaw (uint8_t pvt[EcPrivateKey::KeyLen::value], uint8_t pub[EcPublicKey::KeyLen::value])
 Generate key pair in raw format. More...
 
bool ndnph::ec::detail::generate (Region &region, const Name &name, EcPrivateKey &pvt, EcPublicKey &pub, KeyChain *keyChain, const char *id)
 
bool ndnph::ec::generate (Region &region, const Name &name, EcPrivateKey &pvt, EcPublicKey &pub)
 Generate key pair. More...
 
bool ndnph::ec::generate (Region &region, const Name &name, EcPrivateKey &pvt, EcPublicKey &pub, KeyChain &keyChain, const char *id)
 Generate key pair and save in KeyChain. More...
 
bool ndnph::ec::load (KeyChain &keyChain, const char *id, Region &region, EcPrivateKey &pvt, EcPublicKey &pub)
 Load key pair from KeyChain. More...
 
bool ndnph::ec::isCertificate (const Data &data)
 Determine if the Data packet is a certificate that contains an EC public key. More...