akmhoque | 157b0a4 | 2014-05-13 00:26:37 -0500 | [diff] [blame] | 1 | ; the general section contains all the general settings for router |
akmhoque | ba09474 | 2014-02-28 11:47:21 -0600 | [diff] [blame] | 2 | |
akmhoque | 157b0a4 | 2014-05-13 00:26:37 -0500 | [diff] [blame] | 3 | general |
| 4 | { |
| 5 | ; mandatory configuration command section network, site and router |
akmhoque | ba09474 | 2014-02-28 11:47:21 -0600 | [diff] [blame] | 6 | |
akmhoque | 157b0a4 | 2014-05-13 00:26:37 -0500 | [diff] [blame] | 7 | network /ndn/ ; name of the network the router belongs to in ndn URI format |
akmhoque | 93f1a07 | 2014-06-19 16:24:28 -0500 | [diff] [blame] | 8 | site /edu/memphis ; name of the site the router belongs to in ndn URI format |
| 9 | router /%C1.O.R./cs/pollux ; name of the router in ndn URI format |
akmhoque | 157b0a4 | 2014-05-13 00:26:37 -0500 | [diff] [blame] | 10 | |
| 11 | ; lsa-refresh-time is the time in seconds, after which router will refresh its LSAs |
| 12 | |
| 13 | lsa-refresh-time 1800 ; default value 1800. Valid values 240-7200 |
| 14 | |
| 15 | ; log-level is to set the levels of log for NLSR |
| 16 | |
akmhoque | 674b0b1 | 2014-05-20 14:33:28 -0500 | [diff] [blame] | 17 | log-level INFO ; default value INFO, valid value DEBUG, INFO |
| 18 | log-dir /var/log/nlsr/ ; path for log directory (Absolute path) |
| 19 | seq-dir /var/lib/nlsr/ ; path for sequence directory (Absolute path) |
akmhoque | 157b0a4 | 2014-05-13 00:26:37 -0500 | [diff] [blame] | 20 | } |
| 21 | |
| 22 | ; the neighbors section contains the configuration for router's neighbors and hello's behavior |
| 23 | |
| 24 | neighbors |
| 25 | { |
| 26 | ; in case hello interest timed out, router will try 'hello-retries' times at 'hello-time-out' |
| 27 | ; seconds interval before giving up for any neighbors (deciding link is down) |
| 28 | |
| 29 | hello-retries 3 ; interest retries number in integer. Default value 3 |
| 30 | ; valid values 1-10 |
| 31 | |
| 32 | hello-timeout 1 ; interest time out value in integer. Default value 1 |
| 33 | ; Valid values 1-15 |
| 34 | |
| 35 | hello-interval 60 ; interest sending interval in seconds. Default value 60 |
| 36 | ; valid values 30-90 |
| 37 | ; neighbor command is used to configure router's neighbor. Each neighbor will need |
| 38 | ; one block of neighbor command |
| 39 | |
| 40 | neighbor |
| 41 | { |
akmhoque | 93f1a07 | 2014-06-19 16:24:28 -0500 | [diff] [blame] | 42 | name /ndn/edu/memphis/%C1.O.R./cs/castor ; name prefix of the neighbor router consists |
akmhoque | 157b0a4 | 2014-05-13 00:26:37 -0500 | [diff] [blame] | 43 | ; of network, site-name and router-name |
| 44 | |
| 45 | face-uri udp://castor.cs.memphis.edu ; face id of the face connected to the neighbor |
| 46 | link-cost 25 ; cost of the connecting link to neighbor |
| 47 | } |
Yingdi Yu | 20e3a6e | 2014-05-26 23:16:10 -0700 | [diff] [blame] | 48 | |
akmhoque | 157b0a4 | 2014-05-13 00:26:37 -0500 | [diff] [blame] | 49 | neighbor |
| 50 | { |
akmhoque | 93f1a07 | 2014-06-19 16:24:28 -0500 | [diff] [blame] | 51 | name /ndn/edu/memphis/%C1.O.R./cs/mira ; name prefix of the neighbor router consists |
akmhoque | 157b0a4 | 2014-05-13 00:26:37 -0500 | [diff] [blame] | 52 | ; of network, site-name and router-name |
| 53 | |
| 54 | face-uri udp://mira.cs.memphis.edu ; face id of the face connected to the neighbor |
| 55 | link-cost 30 ; cost of the connecting link to neighbor |
| 56 | } |
| 57 | } |
| 58 | |
| 59 | ; the hyperbolic section contains the configuration settings of enabling a router to calculate |
| 60 | ; routing table using [hyperbolic routing table calculation](http://arxiv.org/abs/0805.1266) method |
| 61 | |
| 62 | hyperbolic |
| 63 | { |
| 64 | ; commands in this section follows a strict order |
| 65 | ; the switch is used to set hyperbolic routing calculation in NLSR |
| 66 | |
Yingdi Yu | 20e3a6e | 2014-05-26 23:16:10 -0700 | [diff] [blame] | 67 | state off ; default value 'off', set value 'on' to enable hyperbolic routing table |
akmhoque | 157b0a4 | 2014-05-13 00:26:37 -0500 | [diff] [blame] | 68 | ; calculation which turns link state routing 'off'. set value to 'dry-run" |
| 69 | ; to test hyperbolic routing and compare with link state routing. |
akmhoque | ba09474 | 2014-02-28 11:47:21 -0600 | [diff] [blame] | 70 | |
| 71 | |
akmhoque | 157b0a4 | 2014-05-13 00:26:37 -0500 | [diff] [blame] | 72 | radius 123.456 ; radius of the router in hyperbolic coordinate system |
| 73 | angle 1.45 ; angle of the router in hyperbolic coordinate system |
| 74 | } |
| 75 | |
| 76 | |
| 77 | ; the fib section is used to configure fib entry's type to ndn FIB updated by NLSR |
| 78 | |
| 79 | fib |
| 80 | { |
| 81 | ; the max-faces-per-prefix is used to limit the number of faces for each name prefixes |
| 82 | ; by NLSR in ndn FIB |
| 83 | |
| 84 | max-faces-per-prefix 3 ; default value 0. Valid value 0-60. By default (value 0) NLSR adds |
| 85 | ; all available faces for each reachable name prefixes in NDN FIB |
| 86 | |
| 87 | } |
| 88 | |
Yingdi Yu | 20e3a6e | 2014-05-26 23:16:10 -0700 | [diff] [blame] | 89 | ; the advertising section contains the configuration settings of the name prefixes |
akmhoque | 157b0a4 | 2014-05-13 00:26:37 -0500 | [diff] [blame] | 90 | ; hosted by this router |
| 91 | |
| 92 | advertising |
| 93 | { |
| 94 | ; the ndnname is used to advertised name from the router. To advertise each name prefix |
| 95 | ; configure one block of ndnname configuration command for every name prefix. |
| 96 | |
| 97 | prefix /ndn/edu/memphis/cs/netlab ; name in ndn URI format |
Yingdi Yu | 20e3a6e | 2014-05-26 23:16:10 -0700 | [diff] [blame] | 98 | prefix /ndn/edu/memphis/sports/basketball |
| 99 | } |
| 100 | |
| 101 | security |
| 102 | { |
| 103 | validator |
| 104 | { |
| 105 | rule |
| 106 | { |
| 107 | id "NSLR Hello Rule" |
| 108 | for data |
| 109 | filter |
| 110 | { |
| 111 | type name |
akmhoque | 93f1a07 | 2014-06-19 16:24:28 -0500 | [diff] [blame] | 112 | regex ^[^<NLSR><INFO>]*<NLSR><INFO><><>$ |
Yingdi Yu | 20e3a6e | 2014-05-26 23:16:10 -0700 | [diff] [blame] | 113 | } |
| 114 | checker |
| 115 | { |
| 116 | type customized |
| 117 | sig-type rsa-sha256 |
| 118 | key-locator |
| 119 | { |
| 120 | type name |
| 121 | hyper-relation |
| 122 | { |
| 123 | k-regex ^([^<KEY><NLSR>]*)<NLSR><KEY><ksk-.*><ID-CERT>$ |
Yingdi Yu | 6a3a4dd | 2014-06-20 14:10:39 -0700 | [diff] [blame] | 124 | k-expand \\1 |
Yingdi Yu | 20e3a6e | 2014-05-26 23:16:10 -0700 | [diff] [blame] | 125 | h-relation equal |
akmhoque | 93f1a07 | 2014-06-19 16:24:28 -0500 | [diff] [blame] | 126 | p-regex ^([^<NLSR><INFO>]*)<NLSR><INFO><><>$ |
Yingdi Yu | 20e3a6e | 2014-05-26 23:16:10 -0700 | [diff] [blame] | 127 | p-expand \\1 |
| 128 | } |
| 129 | } |
| 130 | } |
| 131 | } |
| 132 | |
| 133 | rule |
| 134 | { |
| 135 | id "NSLR LSA Rule" |
| 136 | for data |
| 137 | filter |
| 138 | { |
| 139 | type name |
akmhoque | a816bee | 2014-06-24 14:37:40 -0500 | [diff] [blame] | 140 | regex ^[^<NLSR><LSA>]*<NLSR><LSA> |
Yingdi Yu | 20e3a6e | 2014-05-26 23:16:10 -0700 | [diff] [blame] | 141 | } |
| 142 | checker |
| 143 | { |
| 144 | type customized |
| 145 | sig-type rsa-sha256 |
| 146 | key-locator |
| 147 | { |
| 148 | type name |
| 149 | hyper-relation |
| 150 | { |
| 151 | k-regex ^([^<KEY><NLSR>]*)<NLSR><KEY><ksk-.*><ID-CERT>$ |
Yingdi Yu | 6a3a4dd | 2014-06-20 14:10:39 -0700 | [diff] [blame] | 152 | k-expand \\1 |
Yingdi Yu | 20e3a6e | 2014-05-26 23:16:10 -0700 | [diff] [blame] | 153 | h-relation equal |
akmhoque | 50125a9 | 2014-06-30 08:54:17 -0500 | [diff] [blame^] | 154 | p-regex ^([^<NLSR><LSA>]*)<NLSR><LSA>(<>*)<><><>$ |
Yingdi Yu | 20e3a6e | 2014-05-26 23:16:10 -0700 | [diff] [blame] | 155 | p-expand \\1\\2 |
| 156 | } |
| 157 | } |
| 158 | } |
| 159 | } |
| 160 | |
| 161 | rule |
| 162 | { |
| 163 | id "NSLR Hierarchy Exception Rule" |
| 164 | for data |
| 165 | filter |
| 166 | { |
| 167 | type name |
akmhoque | 50125a9 | 2014-06-30 08:54:17 -0500 | [diff] [blame^] | 168 | regex ^[^<KEY><%C1.O.R.>]*<%C1.O.R.>[^<KEY><NLSR>]*<KEY><ksk-.*><ID-CERT><>$ |
Yingdi Yu | 20e3a6e | 2014-05-26 23:16:10 -0700 | [diff] [blame] | 169 | } |
| 170 | checker |
| 171 | { |
| 172 | type customized |
| 173 | sig-type rsa-sha256 |
| 174 | key-locator |
| 175 | { |
| 176 | type name |
| 177 | hyper-relation |
| 178 | { |
akmhoque | 50125a9 | 2014-06-30 08:54:17 -0500 | [diff] [blame^] | 179 | k-regex ^([^<KEY><%C1.O.N.>]*)<%C1.O.N.>[^<KEY>]*<KEY><ksk-.*><ID-CERT>$ |
Yingdi Yu | 20e3a6e | 2014-05-26 23:16:10 -0700 | [diff] [blame] | 180 | k-expand \\1 |
| 181 | h-relation equal |
akmhoque | 50125a9 | 2014-06-30 08:54:17 -0500 | [diff] [blame^] | 182 | p-regex ^([^<KEY><%C1.O.R.>]*)<%C1.O.R.>[^<KEY>]*<KEY><ksk-.*><ID-CERT><>$ |
Yingdi Yu | 20e3a6e | 2014-05-26 23:16:10 -0700 | [diff] [blame] | 183 | p-expand \\1 |
| 184 | } |
| 185 | } |
| 186 | } |
| 187 | } |
| 188 | |
| 189 | rule |
| 190 | { |
| 191 | id "NSLR Hierarchical Rule" |
| 192 | for data |
| 193 | filter |
| 194 | { |
| 195 | type name |
| 196 | regex ^[^<KEY>]*<KEY><ksk-.*><ID-CERT><>$ |
| 197 | } |
| 198 | checker |
| 199 | { |
| 200 | type hierarchical |
| 201 | sig-type rsa-sha256 |
| 202 | } |
| 203 | } |
| 204 | |
| 205 | trust-anchor |
| 206 | { |
| 207 | type file |
| 208 | file-name "root.cert" |
| 209 | } |
| 210 | } |
akmhoque | 50125a9 | 2014-06-30 08:54:17 -0500 | [diff] [blame^] | 211 | ; cert-to-publish "root.cert" ; optional, a file containing the root certificate. only the router |
| 212 | ; that is designated to publish root cert needs to specify this |
| 213 | ; cert-to-publish "site.cert" ; optional, a file containing the root certificate. only the router |
| 214 | ; that is designated to publish site cert need to specify this |
| 215 | ; cert-to-publish "operator.cert" ; optional, a file containing the root certificate. only the |
| 216 | ; router that is designated to publish operator cert need to |
| 217 | ; specify this |
| 218 | cert-to-publish "router.cert" ; required, a file containing the router certificate. |
akmhoque | 157b0a4 | 2014-05-13 00:26:37 -0500 | [diff] [blame] | 219 | } |