Project

General

Profile

Actions

Bug #1504

closed

adding a nexthop with double "/" at the beginning of the prefix result in the creation of "/" entry

Added by Hila Ben Abraham about 10 years ago. Updated about 10 years ago.

Status:
Rejected
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Start date:
04/19/2014
Due date:
% Done:

0%

Estimated time:

Description

I accidentally added a name with multiple '//' at the beginning, and a FIB entry was created for the '/' prefix:

$build/bin/nfdc add-nexthop ndn://bla 7 90

$build/bin/nfd-status 
...
FIB:
/localhost/nfd nexthops={faceid=1 (cost=0)}
/ nexthops={faceid=7 (cost=90)}

is this the expected behavior?

Actions #1

Updated by Alex Afanasyev about 10 years ago

This is correct behavior. This is related to URI format. Check defintion of name URI scheme here: http://named-data.net/doc/ndn-tlv/name.html#ndn-uri-scheme

Actually, I personally never use ndn: in front. Less typing and less confusion with these double slashes.

Actions #2

Updated by Junxiao Shi about 10 years ago

  • Status changed from New to Rejected

In ndn://bla, "bla" is the authority part of the URI, which is ignored.

Actions #3

Updated by Beichuan Zhang about 10 years ago

However, in practice, this kind of typo will probably happen to many users/apps, and they'll have a strange / FIB entry without their knowledge. I feel we should fix it, e.g., by returning an error code for ndn://blah .

Actions #4

Updated by Junxiao Shi about 10 years ago

Unfortunately this is not something NFD can do.

Protocol says:

The authority component (the part after the initial // in the familiar http and ftp URI schemes) is not relevant to NDN. It should not be present, and it is ignored if it is present.

Library's Name::set follows this rule and ignores authority.
When the command reaches NFD, it's already in TLV format of ndn:/.

Protocol should have defined "Authority MUST NOT be present"

Actions #5

Updated by Alex Afanasyev about 10 years ago

This is an old "problem" originated in ccnx and people (at least me) are well aware of it.

Though the question is why can't we simply ignore URI definition and treat authority as just a name (i.e., why we would keep the protocol as is and don't change that)? What is the implication of that?

Actions #6

Updated by Beichuan Zhang about 10 years ago

I knew what the protocol said. My question was: any reason not to change it?

Actions

Also available in: Atom PDF