[ndnSIM] how to modify nonce field in Interest packet

Alex Afanasyev alexander.afanasyev at ucla.edu
Sun Apr 28 20:57:15 PDT 2013


Hi huyao,

Actually, each retransmitted Interest by ndn::Consumer* application gets its own "unique" (random) nonce.

Consumer::CheckRetxTimeout method (https://github.com/NDN-Routing/ndnSIM/blob/master/apps/ndn-consumer.cc#L122) is responsible for detecting and scheduling retransmission of Interest.

---
Alex

On Apr 28, 2013, at 7:12 PM, yao hu <huyao0107 at gmail.com> wrote:

> Hi Alex,
> 
> Thanks for your reply. I see. 
> 
> One more question is about interest time out or retransmission. Is there a method or function to deal with Interest retransmission or retransmission queue in ndnsim? How about adding a new value to the nonce field in retransmission Interest packet to differentiate it from the orginal one?
> 
> I assume that by default the original Interest and the retransmission Interest if timeout happens should be the same format, right?
> 
> Thanks a lot ~
> 
> Regards,
> huyao
> 
> 
> 
> 2013/4/29 Alex Afanasyev <alexander.afanasyev at ucla.edu>
> Hi huyao,
> 
> (1) The application is fully responsible to put the nonce into the interests. ndn::Consumer-based applications put nonce from uniform distribution (https://github.com/NDN-Routing/ndnSIM/blob/master/apps/ndn-consumer.cc#L206)
> 
> (2) There is  GetNonce() method for ndn::Interest class
> 
> (3) If you write your own app, you just set nonce using SetNonce method.  If you want to reuse existing consumers, then you probably need to change their implementation to some extent.
> 
> ---
> Alex
> 
> On Apr 28, 2013, at 7:06 AM, yao hu <huyao0107 at gmail.com> wrote:
> 
>> Hi Alex,
>> 
>> ndnsim documents says nonce field is filled with a value of uint32_t type. Could you please tell 
>> 
>> (1) what value is filled in nonce field in the current Interest packet implementation. 
>> 
>> (2) how to get the nonce value when receiving Interest packet?
>> 
>> (3) is it possible to fill a self-defined value into nonce field?
>> 
>> Thanks very much!
>> 
>> Regards,
>> huyao
>> _______________________________________________
>> ndnSIM mailing list
>> ndnSIM at lists.cs.ucla.edu
>> http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim
> 
> 
> _______________________________________________
> ndnSIM mailing list
> ndnSIM at lists.cs.ucla.edu
> http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.lists.cs.ucla.edu/pipermail/ndnsim/attachments/20130428/6e80b860/attachment.html>


More information about the ndnSIM mailing list