<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto"><div>Hello ,</div><div>I think i have found a solution . As i understood, if we use GetFlags function ( inface-> GetFlags) we can recognize this packet is from application layer or from other peer .  If this value is one ( or opposite zero) ,it is from application layer . This message is received from other peer if the interface flag related to this message will be zero. </div><div>Hope it will be helpful for other persons who face the same problem. </div><div>And thanks u for all of your helps</div><div>Regards<br><br><br></div><div><br>On Apr 20, 2016, at 11:53 AM, Zeinab Rezaiefar <<a href="mailto:z.rezaiefar@yahoo.com">z.rezaiefar@yahoo.com</a>> wrote:<br><br></div><blockquote type="cite"><div><div style="color:#000; background-color:#fff; font-family:times new roman, new york, times, serif;font-size:16px"><div id="yui_3_16_0_ym19_1_1461069702816_11407" dir="ltr"><span id="yui_3_16_0_ym19_1_1461069702816_11751">Hello Alex and <span id="yui_3_16_0_ym19_1_1461069702816_11819" style="float: none; display: inline;">Spyridon,</span></span></div><div id="yui_3_16_0_ym19_1_1461069702816_11406" dir="ltr"><span id="yui_3_16_0_ym19_1_1461069702816_11405">firstly I would like to say thanks for your helping and your nice explanation. I am using ndnsim version1. as you mentioned, in every node that I install application, I have another interface too. however, my problem is that how I can recognize the  difference between internal interface and the external interfaces ( interface which a node receives packet from its neighbors)  in the code?  since I decide to forward packets based on from which interface I have received this packet ( which shows which peer has sent this packet), it is so important for me to distinguish between internal and external interfaces.</span></div><div id="yui_3_16_0_ym19_1_1461069702816_11558" dir="ltr"><span id="yui_3_16_0_ym19_1_1461069702816_11557">moreover, is there any field like hop-count that shows this message is from other nodes ( form the peer of the node ) and it is not generated by this node?</span></div><div id="yui_3_16_0_ym19_1_1461069702816_11594" dir="ltr"><span id="yui_3_16_0_ym19_1_1461069702816_11826">I am looking forward to hearing  you.</span></div><div id="yui_3_16_0_ym19_1_1461069702816_11833" dir="ltr"><span>thanks in advance</span></div><div id="yui_3_16_0_ym19_1_1461069702816_11834" dir="ltr"><span>best regards</span></div><div id="yui_3_16_0_ym19_1_1461069702816_11593" dir="ltr"><span></span><br></div> <div class="qtdSeparateBR"><br><br></div><div class="yahoo_quoted" style="display: block;"> <div style="font-family: times new roman, new york, times, serif; font-size: 16px;"> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;"> <div dir="ltr"><font face="Arial" size="2"> On Wednesday, April 20, 2016 10:58 AM, Alex Afanasyev <<a href="mailto:aa@cs.ucla.edu">aa@cs.ucla.edu</a>> wrote:<br></font></div>  <br><br> <div class="y_msg_container">Hi Zeinab,<br clear="none"><br clear="none">Which version of ndnSIM you're using.  For ndnSIM 1.0 your reasoning is almost correct.  There could also be face related to the application, if you have an application installed.  If a node doesn't have an application, then there should be just one face per simulated connection.<br clear="none"><br clear="none">ndnSIM 2, in addition to faces that correspond to network interfaces and applications, there are also several internal faces (internal face for management, face to represent content store, null face).<br clear="none"><div class="yqt1726997904" id="yqtfd34795"><br clear="none">---<br clear="none">Alex<br clear="none"><br clear="none">>> On Apr 19, 2016, at 5:58 AM, Zeinab Rezaiefar <<a href="mailto:z.rezaiefar@yahoo.com" shape="rect" ymailto="mailto:z.rezaiefar@yahoo.com">z.rezaiefar@yahoo.com</a>> wrote:<br clear="none">>> <br clear="none">>> Hello everyone,<br clear="none">>> I would like to say that I think that number of interfaces in one node related to number of its connection (in the wired scenario)<br clear="none">>> However, in the scenario that I run, node 1 has just one direct connect to node 2 . In my point of view , this node should have one interface, however, when I print interface of the interest message that is received in forwarding function. ( using inFace->GetId () for interface related to the interest message and node->GetId () for the node id).  I recognized that node 1 received interest messages from interface1 and 0.<br clear="none">>> however, I expected that this node just received  interest messages from one interface.  Is there anybody knows why this thing happens or what mistake I am doing?<br clear="none">>> Thanks in advance<br clear="none">>> best regards</div><br><br></div>  </div> </div>  </div></div></div></blockquote></body></html>