security: Add configuration based validator
Change-Id: Ic5837f4b02a613966c0a2e969c974ebd0786f769
diff --git a/validator.conf.sample b/validator.conf.sample
new file mode 100644
index 0000000..224d3d8
--- /dev/null
+++ b/validator.conf.sample
@@ -0,0 +1,40 @@
+rule
+{
+ id "NRD Prefix Registration Command Rule"
+ for interest
+ filter
+ {
+ type name
+ regex ^<localhost><nrd>[<register><unregister>]<>{3}$
+ }
+ checker
+ {
+ type customized
+ sig-type rsa-sha256
+ key-locator
+ {
+ type name
+ regex ^[^<KEY>]*<KEY><>*<ksk-.*><ID-CERT>$
+ }
+ }
+}
+rule
+{
+ id "Testbed Hierarchy Rule"
+ for data
+ filter
+ {
+ type name
+ regex ^[^<KEY>]*<KEY><>*<ksk-.*><ID-CERT><>$
+ }
+ checker
+ {
+ type hierarchical
+ sig-type rsa-sha256
+ }
+}
+trust-anchor
+{
+ type file
+ file-name "trust-anchor.cert"
+}
\ No newline at end of file