NLSR Management » History » Revision 5
Revision 4 (Muktadir Chowdhury, 02/27/2015 06:27 AM) → Revision 5/44 (Muktadir Chowdhury, 02/27/2015 06:27 AM)
NLSR Management =============== NLSR Management provides: - command to add(advertise) routes to name prefix list - command to remove(withdraw) routes to name prefix list ## 1. Control Commands ### Add a name prefix ### command-verb: advertise This command adds a name prefix to the name prefix list. This command can be accepted on ```ndn:/localhost/nlsr/routeUpdate``` prefix. ### Control Parameters - Name (required) ## Remove a name prefix ### command-verb: withdraw This command removes a name prefix from the name prefix list. This command can be accepted on ```ndn:/localhost/nlsr/routeUpdate``` prefix. ### Control Parameters - Name (required) ## 2. Request format NLSR control commands are signed interests, whose name has the following form: ```/<prefix>/<management-module>/<command-verb>/<control-parameters>/<signed-interests-components>``` - ```<prefix>``` is ```/localhost/nlsr ```. Each individual command may specify additional prefixes under which that command could be accepted. - ```<management-module> ```is the name of management module to which the command needs to be dispatched. For example, the name of the management module of the task I’m doing now would be ```routeUpdate```. - ```<command-verb>``` is the command to be executed. For this task this would be either ```withdraw``` or ```advertise```. - <control-parameters> is a ControlParameters TLV block wrapped in a NameComponent. - <signed-interest-components> are four additional components defined by [ndn-cxx:SignedInterest|Signed Interest] spec. So, putting everything together, the complete name of a command interest would be ```localhost/nlsr/routeUpdate/advertise``` or ```localhost/nlsr/routeUpdate/withdraw``` ## 2. Response Format A response from the command interface is a Data that matches the request Interest. The payload of this Data is a ControlResponse block. ##StatusCode: Going to use the codes that has been used by nfd-control-command. StatusCode | Description ------------|------------------------------------ 200 | OK 400 | ControlParameters is incorrect 403 | Command Interest is not authorized 501 | Module or verb is not supported