blob: fecb57e8a258eec2e79ba78e1baf0b433f703d7b [file] [log] [blame]
akmhoque157b0a42014-05-13 00:26:37 -05001; the general section contains all the general settings for router
akmhoqueba094742014-02-28 11:47:21 -06002
akmhoque157b0a42014-05-13 00:26:37 -05003general
4{
Alexander Afanasyev8388ec62014-08-16 18:38:57 -07005 ; mandatory configuration command section network, site and router
akmhoqueba094742014-02-28 11:47:21 -06006
Junxiao Shib032fcb2022-04-28 01:28:50 +00007 network /ndn ; name of the network the router belongs to in ndn URI format
Alexander Afanasyev8388ec62014-08-16 18:38:57 -07008 site /edu/memphis ; name of the site the router belongs to in ndn URI format
9 router /%C1.Router/cs/pollux ; name of the router in ndn URI format
akmhoque157b0a42014-05-13 00:26:37 -050010
Alexander Afanasyev8388ec62014-08-16 18:38:57 -070011 ; lsa-refresh-time is the time in seconds, after which router will refresh its LSAs
Alexander Afanasyev8388ec62014-08-16 18:38:57 -070012 lsa-refresh-time 1800 ; default value 1800. Valid values 240-7200
akmhoque157b0a42014-05-13 00:26:37 -050013
Nick Gordond5c1a372016-10-31 13:56:23 -050014 ; router-dead-interval is the time in seconds after which an inactive routers
Vince Lehmanfc7d5b62014-12-05 15:02:47 -060015 ; LSAs are removed
16 ;router-dead-interval 3600 ; default value: 2*lsa-refresh-time. Value must be larger
17 ; than lsa-refresh-time
18
Alexander Afanasyev411ee4b2014-08-16 23:17:03 -070019 ; InterestLifetime (in seconds) for LSA fetching
20 lsa-interest-lifetime 4 ; default value 4. Valid values 1-60
21
Varun Patil7d2d6892022-10-14 12:50:30 -070022 ; select sync protocol: chronosync / psync / svs
Ashlesh Gawande32ec3fd2018-07-18 13:42:32 -050023 sync-protocol psync
24
25 ; sync interest lifetime of ChronoSync/PSync in milliseconds
Ashlesh Gawandef7da9c52018-02-06 17:36:46 -060026 sync-interest-lifetime 60000 ; default value 60000. Valid values 1000-120,000
27
dulalsaurab82a34c22019-02-04 17:31:21 +000028 state-dir /var/lib/nlsr ; path for intermediate state files including sequence directory (Absolute path)
akmhoque157b0a42014-05-13 00:26:37 -050029}
30
Ashlesh Gawande30d96e42021-03-21 19:15:33 -070031; the neighbors section contains the configuration for router's neighbors and hello protocol behavior
akmhoque157b0a42014-05-13 00:26:37 -050032
33neighbors
34{
Alexander Afanasyev8388ec62014-08-16 18:38:57 -070035 ; in case hello interest timed out, router will try 'hello-retries' times at 'hello-timeout'
36 ; seconds interval before giving up for any neighbors (deciding link is down)
akmhoque157b0a42014-05-13 00:26:37 -050037
38 hello-retries 3 ; interest retries number in integer. Default value 3
39 ; valid values 1-10
40
Ashlesh Gawande6b388fc2019-09-30 10:14:41 -050041 hello-timeout 1 ; interest time out value in seconds. Default value 1
akmhoque157b0a42014-05-13 00:26:37 -050042 ; Valid values 1-15
43
44 hello-interval 60 ; interest sending interval in seconds. Default value 60
45 ; valid values 30-90
akmhoque157b0a42014-05-13 00:26:37 -050046
Vince Lehman7b616582014-10-17 16:25:39 -050047 ; adj-lsa-build-interval is the time to wait in seconds after an Adjacency LSA build is scheduled
48 ; before actually building the Adjacency LSA
49
Ashlesh Gawande6b388fc2019-09-30 10:14:41 -050050 adj-lsa-build-interval 10 ; default value 10. Valid values 5-30.
Vince Lehman7b616582014-10-17 16:25:39 -050051
Nick Gordond5c1a372016-10-31 13:56:23 -050052 face-dataset-fetch-tries 3 ; default is 3. Valid values 1-10. The FaceDataset is
53 ; gotten from NFD, and is needed to configure NLSR
54 ; correctly. It is recommended not to set this
Muktadir Chowdhuryf04f9892017-08-20 20:42:56 -050055 ; variable too high, because it could cause
Nick Gordond5c1a372016-10-31 13:56:23 -050056 ; congestion for NFD.
57
58 face-dataset-fetch-interval 3600 ; default is 3600. Valid values 1800-5400.
59 ; This controls how often (in seconds) NLSR will attempt to
60 ; fetch a FaceStatus dataset from NFD.
61
Alexander Afanasyev8388ec62014-08-16 18:38:57 -070062 ; neighbor command is used to configure router's neighbor. Each neighbor will need
63 ; one block of neighbor command
64
65 neighbor
66 {
67 name /ndn/edu/memphis/%C1.Router/cs/castor ; name prefix of the neighbor router consists
68 ; of network, site-name and router-name
69
70 face-uri udp://castor.cs.memphis.edu ; face uri of the face connected to the neighbor
71 link-cost 25 ; cost of the connecting link to neighbor
72 }
73
74 neighbor
75 {
76 name /ndn/edu/memphis/%C1.Router/cs/mira ; name prefix of the neighbor router consists
akmhoque157b0a42014-05-13 00:26:37 -050077 ; of network, site-name and router-name
78
Alexander Afanasyev8388ec62014-08-16 18:38:57 -070079 face-uri udp://mira.cs.memphis.edu ; face uri of the face connected to the neighbor
80 link-cost 30 ; cost of the connecting link to neighbor
81 }
akmhoque157b0a42014-05-13 00:26:37 -050082}
83
84; the hyperbolic section contains the configuration settings of enabling a router to calculate
85; routing table using [hyperbolic routing table calculation](http://arxiv.org/abs/0805.1266) method
86
87hyperbolic
88{
Alexander Afanasyev8388ec62014-08-16 18:38:57 -070089 ; commands in this section follows a strict order
90 ; the switch is used to set hyperbolic routing calculation in NLSR
akmhoque157b0a42014-05-13 00:26:37 -050091
Alexander Afanasyev8388ec62014-08-16 18:38:57 -070092 state off ; default value 'off', set value 'on' to enable hyperbolic routing table
Junxiao Shif09e2632015-01-02 18:15:01 -070093 ; calculation which turns link state routing 'off'. set value to 'dry-run'
Alexander Afanasyev8388ec62014-08-16 18:38:57 -070094 ; to test hyperbolic routing and compare with link state routing.
akmhoqueba094742014-02-28 11:47:21 -060095
96
Alexander Afanasyev8388ec62014-08-16 18:38:57 -070097 radius 123.456 ; radius of the router in hyperbolic coordinate system
Muktadir R Chowdhuryb00dc2a2016-11-05 10:48:58 -060098 angle 1.45,2.36 ; angle of the router in hyperbolic coordinate system
akmhoque157b0a42014-05-13 00:26:37 -050099}
100
101
Nick Gordond5c1a372016-10-31 13:56:23 -0500102; the fib section is used to configure fib entrys type to ndn FIB updated by NLSR
akmhoque157b0a42014-05-13 00:26:37 -0500103
104fib
105{
Alexander Afanasyev8388ec62014-08-16 18:38:57 -0700106 ; the max-faces-per-prefix is used to limit the number of faces for each name prefixes
107 ; by NLSR in ndn FIB
akmhoque157b0a42014-05-13 00:26:37 -0500108
Alexander Afanasyev8388ec62014-08-16 18:38:57 -0700109 max-faces-per-prefix 3 ; default value 0. Valid value 0-60. By default (value 0) NLSR adds
110 ; all available faces for each reachable name prefixes in NDN FIB
Vince Lehman7b616582014-10-17 16:25:39 -0500111
112 ; routing-calc-interval is the time to wait in seconds after a routing table calculation is
113 ; scheduled before actually performing the routing table calculation
114
115 routing-calc-interval 15 ; default value 15. Valid values 0-15. It is recommended that
116 ; routing-calc-interval have a higher value than adj-lsa-build-interval
akmhoque157b0a42014-05-13 00:26:37 -0500117}
118
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700119; the advertising section contains the configuration settings of the name prefixes
akmhoque157b0a42014-05-13 00:26:37 -0500120; hosted by this router
121
122advertising
123{
Alexander Afanasyev8388ec62014-08-16 18:38:57 -0700124 ; the ndnname is used to advertised name from the router. To advertise each name prefix
125 ; configure one block of ndnname configuration command for every name prefix.
awlane879afac2025-04-28 17:59:36 -0500126 ; format: <name-prefix> <cost>
akmhoque157b0a42014-05-13 00:26:37 -0500127
awlane879afac2025-04-28 17:59:36 -0500128 /ndn/edu/memphis/cs/netlab 0
129 /ndn/edu/memphis/sports/basketball 0
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700130}
131
132security
133{
134 validator
135 {
136 rule
137 {
Laqin Fand8c9d8c2017-01-18 21:45:14 +0000138 id "NLSR Hello Rule"
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700139 for data
140 filter
141 {
142 type name
Ashlesh Gawandecba0ae22018-03-27 17:57:56 -0500143 regex ^[^<nlsr><INFO>]*<nlsr><INFO><><>$
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700144 }
145 checker
146 {
147 type customized
Ashlesh Gawande30d96e42021-03-21 19:15:33 -0700148 sig-type ecdsa-sha256
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700149 key-locator
150 {
151 type name
152 hyper-relation
153 {
Junxiao Shib032fcb2022-04-28 01:28:50 +0000154 k-regex ^([^<KEY><nlsr>]*)<nlsr><KEY><>{1,3}$
Yingdi Yu6a3a4dd2014-06-20 14:10:39 -0700155 k-expand \\1
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700156 h-relation equal
Ashlesh Gawandecba0ae22018-03-27 17:57:56 -0500157 p-regex ^([^<nlsr><INFO>]*)<nlsr><INFO><><>$
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700158 p-expand \\1
159 }
160 }
161 }
162 }
163
164 rule
165 {
Laqin Fand8c9d8c2017-01-18 21:45:14 +0000166 id "NLSR LSA Rule"
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700167 for data
168 filter
169 {
170 type name
Ashlesh Gawandecba0ae22018-03-27 17:57:56 -0500171 regex ^[^<nlsr><LSA>]*<nlsr><LSA>
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700172 }
173 checker
174 {
175 type customized
Ashlesh Gawande30d96e42021-03-21 19:15:33 -0700176 sig-type ecdsa-sha256
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700177 key-locator
178 {
179 type name
180 hyper-relation
181 {
Junxiao Shib032fcb2022-04-28 01:28:50 +0000182 k-regex ^([^<KEY><nlsr>]*)<nlsr><KEY><>{1,3}$
Yingdi Yu6a3a4dd2014-06-20 14:10:39 -0700183 k-expand \\1
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700184 h-relation equal
Muktadir R Chowdhuryaa3b0852015-08-06 13:08:56 -0500185 ; the last four components in the prefix should be <lsaType><seqNo><version><segmentNo>
Ashlesh Gawandecba0ae22018-03-27 17:57:56 -0500186 p-regex ^<localhop>([^<nlsr><LSA>]*)<nlsr><LSA>(<>*)<><><><>$
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700187 p-expand \\1\\2
188 }
189 }
190 }
191 }
192
193 rule
194 {
Junxiao Shia3a63972022-01-24 02:03:41 +0000195 id "NLSR datasets"
196 for data
197 filter
198 {
199 type name
200 regex ^[^<nlsr>]*<nlsr>[<lsdb><routing-table>]
201 }
202 checker
203 {
204 type customized
205 sig-type ecdsa-sha256
206 key-locator
207 {
208 type name
209 hyper-relation
210 {
211 k-regex ^([^<KEY>]*)<KEY><>{1,3}$ ; router key or certificate
212 k-expand \\1
213 h-relation equal
214 p-regex ^([^<nlsr>]*)<nlsr>[<lsdb><routing-table>]
215 p-expand \\1
216 }
217 }
218 }
219 }
220
221 rule
222 {
Laqin Fand8c9d8c2017-01-18 21:45:14 +0000223 id "NLSR Hierarchy Exception Rule"
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700224 for data
225 filter
226 {
227 type name
Ashlesh Gawandecba0ae22018-03-27 17:57:56 -0500228 regex ^[^<KEY><%C1.Router>]*<%C1.Router>[^<KEY><nlsr>]*<KEY><><><>$
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700229 }
230 checker
231 {
232 type customized
Ashlesh Gawande30d96e42021-03-21 19:15:33 -0700233 sig-type ecdsa-sha256
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700234 key-locator
235 {
236 type name
237 hyper-relation
238 {
Junxiao Shib032fcb2022-04-28 01:28:50 +0000239 k-regex ^([^<KEY><%C1.Operator>]*)<%C1.Operator>[^<KEY>]*<KEY><>{1,3}$
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700240 k-expand \\1
241 h-relation equal
Muktadir Chowdhuryf04f9892017-08-20 20:42:56 -0500242 p-regex ^([^<KEY><%C1.Router>]*)<%C1.Router>[^<KEY>]*<KEY><><><>$
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700243 p-expand \\1
244 }
245 }
246 }
247 }
248
249 rule
250 {
Laqin Fand8c9d8c2017-01-18 21:45:14 +0000251 id "NLSR Hierarchical Rule"
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700252 for data
253 filter
254 {
255 type name
Muktadir Chowdhuryf04f9892017-08-20 20:42:56 -0500256 regex ^[^<KEY>]*<KEY><><><>$
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700257 }
258 checker
259 {
260 type hierarchical
Ashlesh Gawande30d96e42021-03-21 19:15:33 -0700261 sig-type ecdsa-sha256
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700262 }
263 }
264
265 trust-anchor
266 {
267 type file
268 file-name "root.cert"
269 }
270 }
alvy297f4162015-03-03 17:15:33 -0600271
272 prefix-update-validator
273 {
274 rule
275 {
276 id "NLSR ControlCommand Rule"
277 for interest
278 filter
279 {
280 type name
Muktadir Chowdhuryf04f9892017-08-20 20:42:56 -0500281 ; /<prefix>/<management-module>/<command-verb>/<control-parameters>
282 ; /<timestamp>/<random-value>/<signed-interests-components>
283 regex ^<localhost><nlsr><prefix-update>[<advertise><withdraw>]<><><>$
alvy297f4162015-03-03 17:15:33 -0600284 }
285 checker
286 {
287 type customized
Ashlesh Gawande30d96e42021-03-21 19:15:33 -0700288 sig-type ecdsa-sha256
alvy297f4162015-03-03 17:15:33 -0600289 key-locator
290 {
291 type name
Junxiao Shib032fcb2022-04-28 01:28:50 +0000292 regex ^([^<KEY><%C1.Operator>]*)<%C1.Operator>[^<KEY>]*<KEY><>{1,3}$
alvy297f4162015-03-03 17:15:33 -0600293 }
294 }
295 }
296
297 rule
298 {
299 id "NLSR Hierarchy Rule"
300 for data
301 filter
302 {
303 type name
Muktadir Chowdhuryf04f9892017-08-20 20:42:56 -0500304 regex ^[^<KEY>]*<KEY><><><>$
alvy297f4162015-03-03 17:15:33 -0600305 }
306 checker
307 {
308 type hierarchical
Ashlesh Gawande30d96e42021-03-21 19:15:33 -0700309 sig-type ecdsa-sha256
alvy297f4162015-03-03 17:15:33 -0600310 }
311 }
312
313 trust-anchor
314 {
315 type file
316 file-name "site.cert"
317 }
318 }
Muktadir Chowdhuryf04f9892017-08-20 20:42:56 -0500319
Vince Lehman9f51efd2014-09-18 14:46:01 -0500320 ; cert-to-publish "root.cert" ; optional, a file containing the root certificate
321 ; Only the router that is designated to publish the root cert
322 ; needs to specify this
323
324 ; cert-to-publish "site.cert" ; optional, a file containing the site certificate
325 ; Only the router that is designated to publish the site cert
326 ; needs to specify this
327
328 ; cert-to-publish "operator.cert" ; optional, a file containing the operator certificate
329 ; Only the router that is designated to publish the operator
330 ; cert needs to specify this
331
akmhoque50125a92014-06-30 08:54:17 -0500332 cert-to-publish "router.cert" ; required, a file containing the router certificate.
akmhoque157b0a42014-05-13 00:26:37 -0500333}