23 #include "../../encoding/buffer-stream.hpp"
24 #include "../transform.hpp"
25 #include "../transform/private-key.hpp"
36 BOOST_ASSERT(key !=
nullptr);
40 KeyHandleMem::doSign(
DigestAlgorithm digestAlgorithm,
const uint8_t* buf,
size_t size)
const
42 switch (digestAlgorithm) {
56 KeyHandleMem::doDecrypt(
const uint8_t* cipherText,
size_t cipherTextLen)
const
58 return m_key->decrypt(cipherText, cipherTextLen);
62 KeyHandleMem::doDerivePublicKey()
const
64 return m_key->derivePublicKey();
Copyright (c) 2013-2016 Regents of the University of California.
KeyHandleMem(shared_ptr< transform::PrivateKey > key)
Use the SHA256 hash of the public key as the key id.
shared_ptr< Buffer > buf()
Flush written data to the stream and return shared pointer to the underlying buffer.
implements an output stream that constructs ndn::Buffer
shared_ptr< const Buffer > ConstBufferPtr