[ndnSIM] Full name requested, but Data packet does not have wire format (e.g., not signed)

Qian Wang qwang at research.ait.ie
Fri May 4 03:46:25 PDT 2018


Hi everyone,

I'm running my tests on ndnSIM. It could run a few seconds and then
terminated with the following error:

terminate called after throwing an instance of
'boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<ndn::Data::Error>
>'
  what():  Full name requested, but Data packet does not have wire format
(e.g., not signed)

I'm wondering anyone has idea about this error?
Thanks a lot.


My code for creating the Data packet is at below:

Name replyNackDataName(replyNackName);
auto replyNackData = make_shared<Data>();
replyNackData->setName(replyNackDataName);
replyNackData->setFreshnessPeriod(::ndn::time::milliseconds(m_freshness.GetMilliSeconds()));

std::string rawData("no");
auto rawDataString = rawData.c_str();
const uint8_t* p = reinterpret_cast<const uint8_t*>(rawDataString);
auto buffer = make_shared< ::ndn::Buffer>(p, rawData.size());
replyNackData->setContent(buffer);

Signature signature;
SignatureInfo signatureInfo(static_cast<
::ndn::tlv::SignatureTypeValue>(255));
if (m_keyLocator.size() > 0) {
 signatureInfo.setKeyLocator(m_keyLocator);
 }
signature.setInfo(signatureInfo);
signature.setValue(::ndn::makeNonNegativeIntegerBlock(::ndn::tlv::SignatureValue,
m_signature));
replyNackData->setSignature(signature);
NS_LOG_INFO("node(" << GetNode()->GetId() << ") responding with Data: " <<
replyNackData->getName());

m_transmittedDatas(replyNackData, this, m_face);
m_appLink->onReceiveData(*replyNackData);


Best Regards,
Qian
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.lists.cs.ucla.edu/pipermail/ndnsim/attachments/20180504/a7740d2d/attachment.html>


More information about the ndnSIM mailing list