]> git.ipfire.org Git - thirdparty/strongswan.git/commitdiff
Added measurement and metadata columns to files table
authorSansar Choinyambuu <schoinya@hsr.ch>
Wed, 19 Oct 2011 07:17:29 +0000 (09:17 +0200)
committerAndreas Steffen <andreas.steffen@strongswan.org>
Mon, 28 Nov 2011 13:39:51 +0000 (14:39 +0100)
Added "/etc/tnc_config" file record for metadata request
Modified files table entries with measurement flag set

src/libimcv/plugins/imv_attestation/data.sql
src/libimcv/plugins/imv_attestation/tables.sql

index 60620dd45d7989f0512ee78f2f739182f62b1105..2cc34fdd2fe31612cbcdd93f938f7262b60d471e 100644 (file)
@@ -39,129 +39,135 @@ INSERT INTO products (
 /* Files */
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, '/lib/i386-linux-gnu/libdl.so.2'
+  0, '/lib/i386-linux-gnu/libdl.so.2', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, '/lib/x86_64-linux-gnu/libdl.so.2'
+  0, '/lib/x86_64-linux-gnu/libdl.so.2', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, '/lib/libdl.so.2'
+  0, '/lib/libdl.so.2', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, '/sbin/iptables'
+  0, '/sbin/iptables', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, '/lib/libxtables.so.5'
+  0, '/lib/libxtables.so.5', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, '/lib/libxtables.so.2'
+  0, '/lib/libxtables.so.2', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  1, '/lib/xtables/'
+  1, '/lib/xtables/', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, 'libxt_udp.so'
+  0, 'libxt_udp.so', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, 'libxt_tcp.so'
+  0, 'libxt_tcp.so', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, 'libxt_esp.so'
+  0, 'libxt_esp.so', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, 'libxt_policy.so'
+  0, 'libxt_policy.so', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, 'libxt_conntrack.so'
+  0, 'libxt_conntrack.so', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, 'libipt_SNAT.so'
+  0, 'libipt_SNAT.so', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, 'libipt_DNAT.so'
+  0, 'libipt_DNAT.so', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, 'libipt_MASQUERADE.so'
+  0, 'libipt_MASQUERADE.so', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, 'libipt_LOG.so'
+  0, 'libipt_LOG.so', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, '/sbin/ip6tables'
+  0, '/sbin/ip6tables', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, 'libip6t_LOG.so'
+  0, 'libip6t_LOG.so', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, 'libxt_mark.so'
+  0, 'libxt_mark.so', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  0, 'libxt_MARK.so'
+  0, 'libxt_MARK.so', 1
 );
 
 INSERT INTO files (
-  type, path
+  type, path, measurement
  ) VALUES (
-  1, '/lib/iptables'
+  1, '/lib/iptables', 1
+);
+
+INSERT INTO files (
+  type, path, metadata
+ ) VALUES (
+  0, '/etc/tnc_config', 1
 );
 
 /* Product-File */
@@ -196,6 +202,12 @@ INSERT INTO product_file (
   1, 17
 );
 
+INSERT INTO product_file (
+  product, file
+) VALUES (
+  1, 22
+);
+
 INSERT INTO product_file (
   product, file
 ) VALUES (
@@ -220,6 +232,12 @@ INSERT INTO product_file (
   2, 7
 );
 
+INSERT INTO product_file (
+  product, file
+) VALUES (
+  2, 22
+);
+
 INSERT INTO product_file (
   product, file
 ) VALUES (
@@ -232,6 +250,12 @@ INSERT INTO product_file (
   3, 4
 );
 
+INSERT INTO product_file (
+  product, file
+) VALUES (
+  3, 22
+);
+
 INSERT INTO product_file (
   product, file
 ) VALUES (
@@ -256,6 +280,13 @@ INSERT INTO product_file (
   4, 7
 );
 
+INSERT INTO product_file (
+  product, file
+) VALUES (
+  4, 22
+);
+
+
 INSERT INTO product_file (
   product, file
 ) VALUES (
@@ -280,6 +311,12 @@ INSERT INTO product_file (
   5, 7
 );
 
+INSERT INTO product_file (
+  product, file
+) VALUES (
+  5, 22
+);
+
 INSERT INTO product_file (
   product, file
 ) VALUES (
@@ -304,6 +341,12 @@ INSERT INTO product_file (
   6, 21
 );
 
+INSERT INTO product_file (
+  product, file
+) VALUES (
+  6, 22
+);
+
 /* File Hashes */
 
 INSERT INTO file_hashes (
index 8cc0e55880e5e6200c864933755f98508c2dd2a2..f6ef2b81e3b9621f1155e00b23a8b29363e03e24 100644 (file)
@@ -4,7 +4,9 @@ DROP TABLE IF EXISTS files;
 CREATE TABLE files (
   id INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
   type INTEGER NOT NULL,
-  path TEXT NOT NULL
+  path TEXT NOT NULL,
+  measurement INTEGER DEFAULT 0,
+  metadata INTEGER DEFAULT 0
 );
 
 DROP TABLE IF EXISTS products;