blob: bb267510ec19bdb69271194ca40739713d7a221d [file] [log] [blame]
Shuo Chen478204c2014-03-18 18:27:04 -07001repo
2{
Davide Pesavento4a160042020-04-13 16:50:02 -04003 ; Section defining the list of Data prefixes to register.
4 ; Additionally defines how many components off the end of these Data prefixes to insert into NFD.
5 ; The 'prefix' option can be repeated multiple times.
Nick Gordon190e4dc2017-10-04 16:54:10 -05006 ; 'registration-subset' defines how many components to exclude. This includes the implicit digest
Davide Pesavento4a160042020-04-13 16:50:02 -04007 ; at the end of the Data name.
Shuo Chen478204c2014-03-18 18:27:04 -07008 data
9 {
Nick Gordon190e4dc2017-10-04 16:54:10 -050010 registration-subset 2
Shuo Chen478204c2014-03-18 18:27:04 -070011 prefix "ndn:/example/data/1"
12 prefix "ndn:/example/data/2"
13 }
14
Davide Pesavento4a160042020-04-13 16:50:02 -040015 ; Section defining the list of command prefixes (to insert or delete Data) to register.
16 ; Only the 'prefix' option is allowed here and it can be repeated multiple times.
Shuo Chen478204c2014-03-18 18:27:04 -070017 command
18 {
19 prefix "ndn:/example/repo/1"
20 prefix "ndn:/example/repo/2"
21 }
22
Davide Pesavento4a160042020-04-13 16:50:02 -040023 ; Section to specify where the data should be stored.
Shuo Chen478204c2014-03-18 18:27:04 -070024 storage
25 {
Davide Pesavento4a160042020-04-13 16:50:02 -040026 method "sqlite" ; Currently, only the sqlite storage engine is supported
Davide Pesavento4162cc52019-01-25 01:32:30 -050027 path "/var/lib/ndn/repo-ng" ; Path to repo-ng storage folder
Weiqi Shif0330d52014-07-09 10:54:27 -070028 max-packets 100000
Shuo Chen478204c2014-03-18 18:27:04 -070029 }
30
Davide Pesavento4a160042020-04-13 16:50:02 -040031 ; Section to configure the TCP bulk insert capability.
32 ; An empty section enables TCP bulk insert to listen on localhost, port 7376.
Davide Pesavento4162cc52019-01-25 01:32:30 -050033 tcp_bulk_insert
34 {
35 ; host "localhost" ; Set to listen on a different IP address or hostname
36 ; port 7376 ; Set to listen on a different port number
Shuo Chen478204c2014-03-18 18:27:04 -070037 }
38
39 validator
40 {
Weiqi Shif0330d52014-07-09 10:54:27 -070041 ; The following rule disables all security in the repo
Davide Pesavento4162cc52019-01-25 01:32:30 -050042 trust-anchor
43 {
44 type any
Shuo Chen5d9c4192014-06-21 16:25:38 +080045 }
Shuo Chenc88c87d2014-06-25 20:21:02 +080046
Davide Pesavento4a160042020-04-13 16:50:02 -040047 ; ; These rules are examples to validate signed Interests for commands and data.
48 ; ; One can define their own rules for signed Interests and Data packets to be
49 ; ; inserted according to the Validator Configuration File Format.
50 ; ; See https://named-data.net/doc/ndn-cxx/current/tutorials/security-validator-config.html
Weiqi Shif0330d52014-07-09 10:54:27 -070051 ; rule
52 ; {
Davide Pesavento4a160042020-04-13 16:50:02 -040053 ; id "Simple Rule For Interests"
Weiqi Shif0330d52014-07-09 10:54:27 -070054 ; for interest
55 ; filter
56 ; {
57 ; type name
58 ; name /example/repo/1
59 ; relation is-prefix-of
60 ; }
61 ; checker
62 ; {
63 ; type fixed-signer
64 ; sig-type rsa-sha256
65 ; signer
66 ; {
67 ; type file
Davide Pesavento4a160042020-04-13 16:50:02 -040068 ; ; repo-ng.cert.sample is a non-existent certificate.
69 ; ; One should create their certificates using the ndnsec tool.
Weiqi Shif0330d52014-07-09 10:54:27 -070070 ; file-name "repo-ng.cert.sample"
71 ; }
72 ; }
73 ; }
74 ;
75 ; rule
76 ; {
77 ; id "Simple Rule For Data"
78 ; for data
79 ; filter
80 ; {
81 ; type name
82 ; name /example/data/1
83 ; relation is-prefix-of
84 ; }
85 ; checker
86 ; {
87 ; type fixed-signer
88 ; sig-type rsa-sha256
89 ; signer
90 ; {
91 ; type file
Davide Pesavento4a160042020-04-13 16:50:02 -040092 ; ; repo-ng.cert.sample is a non-existent certificate.
93 ; ; One should create their certificates using the ndnsec tool.
Weiqi Shif0330d52014-07-09 10:54:27 -070094 ; file-name "repo-ng.cert.sample"
95 ; }
96 ; }
97 ; }
Shuo Chen478204c2014-03-18 18:27:04 -070098 }
Davide Pesavento4162cc52019-01-25 01:32:30 -050099}