blob: d32a463f7753ed064916162797f17b678eadd63f [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
Alexander Afanasyev8388ec62014-08-16 18:38:57 -07007 network /ndn/ ; name of the network the router belongs to in ndn URI format
8 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
Vince Lehmanfc7d5b62014-12-05 15:02:47 -060014 ; router-dead-interval is the time in seconds after which an inactive router's
15 ; 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
Vince Lehmanf99b87f2014-08-26 15:54:27 -050022 ; log-level is used to set the logging level for NLSR.
23 ; All debugging levels listed above the selected value are enabled.
24 ;
25 ; Valid values:
26 ;
27 ; NONE ; no messages
28 ; ERROR ; error messages
29 ; WARN ; warning messages
30 ; INFO ; informational messages (default)
31 ; DEBUG ; debugging messages
32 ; TRACE ; trace messages (most verbose)
33 ; ALL ; all messages
akmhoque157b0a42014-05-13 00:26:37 -050034
Vince Lehmanf99b87f2014-08-26 15:54:27 -050035 log-level INFO
36
Muktadir R Chowdhurybfa27602014-10-31 10:57:41 -050037 log-dir /var/log/nlsr/ ; path for log directory (Absolute path)
38 seq-dir /var/lib/nlsr/ ; path for sequence directory (Absolute path)
39 ;log4cxx-conf /path/to/log4cxx-conf ; path for log4cxx configuration file (Absolute path)
akmhoque157b0a42014-05-13 00:26:37 -050040}
41
42; the neighbors section contains the configuration for router's neighbors and hello's behavior
43
44neighbors
45{
Alexander Afanasyev8388ec62014-08-16 18:38:57 -070046 ; in case hello interest timed out, router will try 'hello-retries' times at 'hello-timeout'
47 ; seconds interval before giving up for any neighbors (deciding link is down)
akmhoque157b0a42014-05-13 00:26:37 -050048
49 hello-retries 3 ; interest retries number in integer. Default value 3
50 ; valid values 1-10
51
52 hello-timeout 1 ; interest time out value in integer. Default value 1
53 ; Valid values 1-15
54
55 hello-interval 60 ; interest sending interval in seconds. Default value 60
56 ; valid values 30-90
akmhoque157b0a42014-05-13 00:26:37 -050057
Vince Lehman7b616582014-10-17 16:25:39 -050058 ; adj-lsa-build-interval is the time to wait in seconds after an Adjacency LSA build is scheduled
59 ; before actually building the Adjacency LSA
60
61 adj-lsa-build-interval 5 ; default value 5. Valid values 0-5. It is recommended that
62 ; adj-lsa-build-interval have a lower value than routing-calc-interval
63
64 ; first-hello-interval is the time to wait in seconds before sending the first Hello Interest
65
66 first-hello-interval 10 ; Default value 10. Valid values 0-10
67
Alexander Afanasyev8388ec62014-08-16 18:38:57 -070068 ; neighbor command is used to configure router's neighbor. Each neighbor will need
69 ; one block of neighbor command
70
71 neighbor
72 {
73 name /ndn/edu/memphis/%C1.Router/cs/castor ; name prefix of the neighbor router consists
74 ; of network, site-name and router-name
75
76 face-uri udp://castor.cs.memphis.edu ; face uri of the face connected to the neighbor
77 link-cost 25 ; cost of the connecting link to neighbor
78 }
79
80 neighbor
81 {
82 name /ndn/edu/memphis/%C1.Router/cs/mira ; name prefix of the neighbor router consists
akmhoque157b0a42014-05-13 00:26:37 -050083 ; of network, site-name and router-name
84
Alexander Afanasyev8388ec62014-08-16 18:38:57 -070085 face-uri udp://mira.cs.memphis.edu ; face uri of the face connected to the neighbor
86 link-cost 30 ; cost of the connecting link to neighbor
87 }
akmhoque157b0a42014-05-13 00:26:37 -050088}
89
90; the hyperbolic section contains the configuration settings of enabling a router to calculate
91; routing table using [hyperbolic routing table calculation](http://arxiv.org/abs/0805.1266) method
92
93hyperbolic
94{
Alexander Afanasyev8388ec62014-08-16 18:38:57 -070095 ; commands in this section follows a strict order
96 ; the switch is used to set hyperbolic routing calculation in NLSR
akmhoque157b0a42014-05-13 00:26:37 -050097
Alexander Afanasyev8388ec62014-08-16 18:38:57 -070098 state off ; default value 'off', set value 'on' to enable hyperbolic routing table
Junxiao Shif09e2632015-01-02 18:15:01 -070099 ; calculation which turns link state routing 'off'. set value to 'dry-run'
Alexander Afanasyev8388ec62014-08-16 18:38:57 -0700100 ; to test hyperbolic routing and compare with link state routing.
akmhoqueba094742014-02-28 11:47:21 -0600101
102
Alexander Afanasyev8388ec62014-08-16 18:38:57 -0700103 radius 123.456 ; radius of the router in hyperbolic coordinate system
104 angle 1.45 ; angle of the router in hyperbolic coordinate system
akmhoque157b0a42014-05-13 00:26:37 -0500105}
106
107
108; the fib section is used to configure fib entry's type to ndn FIB updated by NLSR
109
110fib
111{
Alexander Afanasyev8388ec62014-08-16 18:38:57 -0700112 ; the max-faces-per-prefix is used to limit the number of faces for each name prefixes
113 ; by NLSR in ndn FIB
akmhoque157b0a42014-05-13 00:26:37 -0500114
Alexander Afanasyev8388ec62014-08-16 18:38:57 -0700115 max-faces-per-prefix 3 ; default value 0. Valid value 0-60. By default (value 0) NLSR adds
116 ; all available faces for each reachable name prefixes in NDN FIB
Vince Lehman7b616582014-10-17 16:25:39 -0500117
118 ; routing-calc-interval is the time to wait in seconds after a routing table calculation is
119 ; scheduled before actually performing the routing table calculation
120
121 routing-calc-interval 15 ; default value 15. Valid values 0-15. It is recommended that
122 ; routing-calc-interval have a higher value than adj-lsa-build-interval
akmhoque157b0a42014-05-13 00:26:37 -0500123}
124
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700125; the advertising section contains the configuration settings of the name prefixes
akmhoque157b0a42014-05-13 00:26:37 -0500126; hosted by this router
127
128advertising
129{
Alexander Afanasyev8388ec62014-08-16 18:38:57 -0700130 ; the ndnname is used to advertised name from the router. To advertise each name prefix
131 ; configure one block of ndnname configuration command for every name prefix.
akmhoque157b0a42014-05-13 00:26:37 -0500132
Alexander Afanasyev8388ec62014-08-16 18:38:57 -0700133 prefix /ndn/edu/memphis/cs/netlab ; name in ndn URI format
134 prefix /ndn/edu/memphis/sports/basketball
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700135}
136
137security
138{
139 validator
140 {
141 rule
142 {
143 id "NSLR Hello Rule"
144 for data
145 filter
146 {
147 type name
akmhoque93f1a072014-06-19 16:24:28 -0500148 regex ^[^<NLSR><INFO>]*<NLSR><INFO><><>$
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700149 }
150 checker
151 {
152 type customized
153 sig-type rsa-sha256
154 key-locator
155 {
156 type name
157 hyper-relation
158 {
159 k-regex ^([^<KEY><NLSR>]*)<NLSR><KEY><ksk-.*><ID-CERT>$
Yingdi Yu6a3a4dd2014-06-20 14:10:39 -0700160 k-expand \\1
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700161 h-relation equal
akmhoque93f1a072014-06-19 16:24:28 -0500162 p-regex ^([^<NLSR><INFO>]*)<NLSR><INFO><><>$
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700163 p-expand \\1
164 }
165 }
166 }
167 }
168
169 rule
170 {
171 id "NSLR LSA Rule"
172 for data
173 filter
174 {
175 type name
akmhoquea816bee2014-06-24 14:37:40 -0500176 regex ^[^<NLSR><LSA>]*<NLSR><LSA>
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700177 }
178 checker
179 {
180 type customized
181 sig-type rsa-sha256
182 key-locator
183 {
184 type name
185 hyper-relation
186 {
187 k-regex ^([^<KEY><NLSR>]*)<NLSR><KEY><ksk-.*><ID-CERT>$
Yingdi Yu6a3a4dd2014-06-20 14:10:39 -0700188 k-expand \\1
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700189 h-relation equal
Muktadir R Chowdhuryaa3b0852015-08-06 13:08:56 -0500190 ; the last four components in the prefix should be <lsaType><seqNo><version><segmentNo>
191 p-regex ^([^<NLSR><LSA>]*)<NLSR><LSA>(<>*)<><><><>$
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700192 p-expand \\1\\2
193 }
194 }
195 }
196 }
197
198 rule
199 {
200 id "NSLR Hierarchy Exception Rule"
201 for data
202 filter
203 {
204 type name
akmhoquecc827532014-07-09 08:48:49 -0500205 regex ^[^<KEY><%C1.Router>]*<%C1.Router>[^<KEY><NLSR>]*<KEY><ksk-.*><ID-CERT><>$
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700206 }
207 checker
208 {
209 type customized
210 sig-type rsa-sha256
211 key-locator
212 {
213 type name
214 hyper-relation
215 {
alvy297f4162015-03-03 17:15:33 -0600216 k-regex ^([^<KEY><%C1.Operator>]*)<%C1.Operator>[^<KEY>]*<KEY><ksk-.*><ID-CERT>$
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700217 k-expand \\1
218 h-relation equal
akmhoquecc827532014-07-09 08:48:49 -0500219 p-regex ^([^<KEY><%C1.Router>]*)<%C1.Router>[^<KEY>]*<KEY><ksk-.*><ID-CERT><>$
Yingdi Yu20e3a6e2014-05-26 23:16:10 -0700220 p-expand \\1
221 }
222 }
223 }
224 }
225
226 rule
227 {
228 id "NSLR Hierarchical Rule"
229 for data
230 filter
231 {
232 type name
233 regex ^[^<KEY>]*<KEY><ksk-.*><ID-CERT><>$
234 }
235 checker
236 {
237 type hierarchical
238 sig-type rsa-sha256
239 }
240 }
241
242 trust-anchor
243 {
244 type file
245 file-name "root.cert"
246 }
247 }
alvy297f4162015-03-03 17:15:33 -0600248
249 prefix-update-validator
250 {
251 rule
252 {
253 id "NLSR ControlCommand Rule"
254 for interest
255 filter
256 {
257 type name
258 regex ^<localhost><nlsr><prefix-update>[<advertise><withdraw>]<>$
259 }
260 checker
261 {
262 type customized
263 sig-type rsa-sha256
264 key-locator
265 {
266 type name
267 regex ^([^<KEY><%C1.Operator>]*)<%C1.Operator>[^<KEY>]*<KEY><ksk-.*><ID-CERT>$
268 }
269 }
270 }
271
272 rule
273 {
274 id "NLSR Hierarchy Rule"
275 for data
276 filter
277 {
278 type name
279 regex ^[^<KEY>]*<KEY><ksk-.*><ID-CERT><>$
280 }
281 checker
282 {
283 type hierarchical
284 sig-type rsa-sha256
285 }
286 }
287
288 trust-anchor
289 {
290 type file
291 file-name "site.cert"
292 }
293 }
Vince Lehman9f51efd2014-09-18 14:46:01 -0500294 ; cert-to-publish "root.cert" ; optional, a file containing the root certificate
295 ; Only the router that is designated to publish the root cert
296 ; needs to specify this
297
298 ; cert-to-publish "site.cert" ; optional, a file containing the site certificate
299 ; Only the router that is designated to publish the site cert
300 ; needs to specify this
301
302 ; cert-to-publish "operator.cert" ; optional, a file containing the operator certificate
303 ; Only the router that is designated to publish the operator
304 ; cert needs to specify this
305
akmhoque50125a92014-06-30 08:54:17 -0500306 cert-to-publish "router.cert" ; required, a file containing the router certificate.
akmhoque157b0a42014-05-13 00:26:37 -0500307}