- Timestamp:
- Feb 16, 2011, 9:33:00 PM (14 years ago)
- Location:
- trunk/src
- Files:
-
- 2 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/samhain.c
r307 r310 71 71 #include "sh_readconf.h" 72 72 #include "sh_hash.h" 73 #include "sh_restrict.h" 73 74 74 75 #include "sh_nmail.h" … … 1786 1787 #endif 1787 1788 #if defined(SH_WITH_CLIENT) || defined(SH_STANDALONE) 1789 sh_restrict_purge (); 1788 1790 1789 1791 -
trunk/src/sh_files.c
r307 r310 1147 1147 p = sh_files_C_dequote(p, &len); 1148 1148 if (!p || len == 0) 1149 SL_RETURN((-1), _("sh_files_push dir"));1149 SL_RETURN((-1), _("sh_files_pushfile")); 1150 1150 1151 1151 if (len >= PATH_MAX) … … 1544 1544 1545 1545 1546 if (rdepth < (-1) || tail == p || rdepth > 99) 1547 rdepth = (-2); 1546 if (tail == p) 1547 { 1548 /* Setting to an invalid number will force MaxRecursionLevel, 1549 * see sh_files_setrec_int() 1550 */ 1551 rdepth = (-2); 1552 } 1553 else if ( (rdepth < (-1) || rdepth > 99) || 1554 ((rdepth == (-1)) && (class != SH_LEVEL_ALLIGNORE)) ) 1555 { 1556 SH_FREE(p); 1557 SL_RETURN((-1), _("sh_files_pushdir")); 1558 } 1548 1559 1549 1560 len = sl_strlen(tail); -
trunk/src/sh_readconf.c
r290 r310 48 48 #include "sh_unix.h" 49 49 #include "sh_utils.h" 50 #include "sh_restrict.h" 50 51 51 52 … … 942 943 sh_files_pushfile_prelink }, 943 944 944 { N_("ignoreadded"), SH_SECTION_MISC, SH_SECTION_NONE,945 { N_("ignoreadded"), SH_SECTION_MISC, SH_SECTION_NONE, 945 946 sh_ignore_add_new }, 946 947 { N_("ignoremissing"), SH_SECTION_MISC, SH_SECTION_NONE, 947 948 sh_ignore_add_del }, 949 950 { N_("skipchecksum"), SH_SECTION_MISC, SH_SECTION_NONE, 951 sh_restrict_define }, 952 { N_("filetype"), SH_SECTION_MISC, SH_SECTION_NONE, 953 sh_restrict_add_ftype }, 954 948 955 949 956 { N_("filecheckscheduleone"), SH_SECTION_MISC, SH_SECTION_NONE, -
trunk/src/sh_unix.c
r295 r310 98 98 #include "sh_hash.h" 99 99 #include "sh_tools.h" 100 #include "sh_restrict.h" 100 101 #include "sh_ipvx.h" 101 102 #include "sh_tiger.h" … … 3749 3750 if (fileHash != NULL) 3750 3751 { 3751 if ((theFile->check_mask & MODI_CHK) == 0) 3752 if ((theFile->check_mask & MODI_CHK) == 0 || 3753 sh_restrict_this(theFile->fullpath, (UINT64) fbuf.st_size, 3754 (UINT64) fbuf.st_mode, rval_open)) 3752 3755 { 3753 3756 sl_strlcpy(fileHash, SH_KEY_NULL, KEY_LEN+1); … … 3802 3805 if (fileHash != NULL) 3803 3806 { 3804 if ((theFile->check_mask & MODI_CHK) == 0) 3807 if ((theFile->check_mask & MODI_CHK) == 0 || 3808 sh_restrict_this(theFile->fullpath, (UINT64) fbuf.st_size, 3809 (UINT64) fbuf.st_mode, rval_open)) 3805 3810 { 3806 3811 sl_strlcpy(fileHash, SH_KEY_NULL, KEY_LEN+1);
Note:
See TracChangeset
for help on using the changeset viewer.