Browse code

libclamav: add CL_FLEVEL_DCONF (bb#1313)

git-svn: trunk@4550

Tomasz Kojm authored on 2008/12/11 04:02:40
Showing 4 changed files
... ...
@@ -1,3 +1,7 @@
1
+Wed Dec 10 20:09:00 CET 2008 (tk)
2
+---------------------------------
3
+ * libclamav: add CL_FLEVEL_DCONF (bb#1313)
4
+
1 5
 Tue Dec  9 03:32:08 CET 2008 (acab)
2 6
 -----------------------------------
3 7
  * clamconf: skip milter's directives
... ...
@@ -247,7 +247,7 @@ static int chkflevel(const char *entry, int field)
247 247
 	    return 0;
248 248
 	}
249 249
 
250
-	if((unsigned int) atoi(pt) > cl_retflevel()) {
250
+	if((unsigned int) atoi(pt) > CL_FLEVEL_DCONF) {
251 251
 	    free(pt);
252 252
 	    return 0;
253 253
 	}
... ...
@@ -260,7 +260,7 @@ static int chkflevel(const char *entry, int field)
260 260
 		return 0;
261 261
 	    }
262 262
 
263
-	    if((unsigned int) atoi(pt) < cl_retflevel()) {
263
+	    if((unsigned int) atoi(pt) < CL_FLEVEL_DCONF) {
264 264
 		free(pt);
265 265
 		return 0;
266 266
 	    }
... ...
@@ -92,8 +92,6 @@ static pthread_mutex_t cli_ctime_mutex = PTHREAD_MUTEX_INITIALIZER;
92 92
 #define       P_tmpdir        "C:\\WINDOWS\\TEMP"
93 93
 #endif
94 94
 
95
-#define CL_FLEVEL 38 /* don't touch it */
96
-
97 95
 uint8_t cli_debug_flag = 0;
98 96
 
99 97
 #ifndef CLI_MEMFUNSONLY
... ...
@@ -35,6 +35,18 @@
35 35
 #include "dconf.h"
36 36
 #include "libclamunrar_iface/unrar_iface.h"
37 37
 
38
+/*
39
+ * CL_FLEVEL is the signature f-level specific to the current code and
40
+ *	     should never be modified
41
+ * CL_FLEVEL_DCONF is used in the dconf module and can be bumped by
42
+ * distribution packagers provided they fix *all* security issues found
43
+ * in the old versions of ClamAV. Updating CL_FLEVEL_DCONF will result
44
+ * in re-enabling affected modules.
45
+ */
46
+
47
+#define CL_FLEVEL 38
48
+#define CL_FLEVEL_DCONF	CL_FLEVEL
49
+
38 50
 extern uint8_t cli_debug_flag;
39 51
 
40 52
 /*