1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58
|
From dcfb13aee39561f3623a0bd89915c6db915a52f1 Mon Sep 17 00:00:00 2001
From: Gerrit Pape <pape@smarden.org>
Date: Thu, 9 Aug 2007 08:39:20 +0000
Subject: [PATCH] allow tTdD in config rule checksets as documented.
The tTdD switches in config rule checksets are documented and implemented,
so don't reject them in the options parser.
This was noticed by whollygoat and reported through
http://bugs.debian.org/436360
---
README | 2 ++
examples/root.conf | 2 ++
options.c | 2 +-
3 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/README b/README
index ae7fdd8..e29ae88 100644
--- a/README
+++ b/README
@@ -262,6 +262,8 @@ Here's a table of letters and the corresponding options:
s checksum
i inode
p permissions
+ t file type
+ d device type (if file is blk or chr special)
l number of links
u uid
g gid
diff --git a/examples/root.conf b/examples/root.conf
index 550965d..d73721c 100644
--- a/examples/root.conf
+++ b/examples/root.conf
@@ -19,6 +19,8 @@ current=/root/databases/integrit-foohost.cdb.new
# s checksum
# i inode
# p permissions
+# t file type
+# d device type (if file is blk or chr special)
# l number of links
# u uid
# g gid
diff --git a/options.c b/options.c
index f28fa63..7ad6450 100644
--- a/options.c
+++ b/options.c
@@ -312,7 +312,7 @@ inline static void do_rule(integrit_t *it, char *buf)
buf[n_switches - 1] = '\0';
--n_switches;
}
- if (strspn(buf, "SsIiPpLlUuGgZzAaMmCcRr") != n_switches)
+ if (strspn(buf, "SsIiPpTtDdLlUuGgZzAaMmCcRr") != n_switches)
die(__FUNCTION__,
"Error: unrecognized check switch in conf file rule for %s",
namebuf);
--
debian.1.5.3_rc4.1-dirty
|