Changeset 294 for trunk/include


Ignore:
Timestamp:
Oct 31, 2010, 10:26:42 AM (14 years ago)
Author:
katerina
Message:

Tikets #213 and #214 (Use auditd to determine who changed a file, Windows registry check).

Location:
trunk/include
Files:
1 added
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/sh_cat.h

    r279 r294  
    173173 MSG_LOGMON_MARK,
    174174 MSG_LOGMON_BURST,
     175#endif
     176
     177#ifdef USE_REGISTRY_CHECK
     178 MSG_REG_MISS,
     179 MSG_REG_NEW,
     180 MSG_REG_CHANGE,
    175181#endif
    176182
  • trunk/include/sh_extern.h

    r275 r294  
    4141 */
    4242int sh_ext_popen_init (sh_tas_t * task, char * command);
     43
     44/*
     45 * -- Execute command, return first line of output
     46 */
     47int sh_ext_system (char * command);
    4348
    4449/*
  • trunk/include/sh_files.h

    r256 r294  
    2121#define SH_FILES_H
    2222
     23void sh_audit_mark (char * file);
     24void sh_audit_delete_all ();
     25char * sh_audit_fetch (char * file, time_t time, char * result, size_t rsize);
     26
    2327struct sh_dirent {
    2428  char             * sh_d_name;
    2529  struct sh_dirent * next;
    2630};
     31
    2732
    2833/* free a directory listing
  • trunk/include/sh_hash.h

    r205 r294  
    7070/* Check whether a file is present in the database.
    7171 */
    72 int sh_hash_have_it (char * newname);
     72int sh_hash_have_it (const char * newname);
    7373
    7474/* Get a file if it is present in the database.
     75 * If fileHash != NULL also return checksum.
    7576 */
    76 int sh_hash_get_it (char * newname, file_type * tmpFile);
     77int sh_hash_get_it (const char * newname, file_type * tmpFile, char * fileHash);
    7778
    7879/* Delete the database from memory.
     
    113114void sh_hash_unvisited (ShErrLevel level);
    114115
     116/* Search for unvisited entries in the database, custom error handler.
     117 */
     118void sh_hash_unvisited_custom (char prefix, void(*handler)(const char * key));
     119
    115120/* Set a file's status to 'visited'. This is required for
    116121 * files that should be ignored, and may be present in the
     
    135140int hash_full_tree (void);
    136141
    137 /* Insert data
     142/* Insert data.
     143 * 'key' -> path
     144 * 'str' -> binary with size 'size'
    138145 */
    139 void sh_hash_push2db (char * key, unsigned long val1,
    140                       unsigned long val2, unsigned long val3,
    141                       unsigned char * str, int size);
     146struct store2db {
     147  UINT64 val0;
     148  UINT64 val1;
     149  UINT64 val2;
     150  UINT64 val3;
     151  char   checksum[KEY_LEN+1];
     152  unsigned char * str;
     153  int size;
     154};
     155
     156void sh_hash_push2db (const char * key, struct store2db * save);
     157
    142158
    143159/* Retrieve data
    144160 */
    145 char * sh_hash_db2pop (char * key, unsigned long * val1,
    146                        unsigned long * val2, unsigned long * val3,
    147                        int * size);
     161char * sh_hash_db2pop (const char * key,  struct store2db * get);
     162
    148163
    149164/* Write out database
  • trunk/include/sh_unix.h

    r265 r294  
    9090/* use prelink     */
    9191#define MODI_PREL (1 << 13)
     92
    9293/* get content     */
    9394#define MODI_TXT ((1 << 14)|MODI_CHK)
    94 
    9595#define MODI_TXT_ENABLED(a) (((a)&(1 << 14))!=0)
     96
     97/* get audit record  */
     98#define MODI_AUDIT (1 << 15)
     99#define MODI_AUDIT_ENABLED(a) (((a)&(1 << 15))!=0)
     100
    96101
    97102#define SH_TXT_MAX 9200
Note: See TracChangeset for help on using the changeset viewer.