shell.h 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. #ifndef _SHELL_H
  2. #define _SHELL_H
  3. #define ERR_BINSTAT 1
  4. #define ERR_BINMOD 2
  5. #define ERR_PASSWD 3
  6. #define ERR_WRONGBINDIR 4
  7. #define ERR_CONFSTAT 5
  8. #define ERR_TMPSTAT 6
  9. #define ERR_CONFDIRMOD 7
  10. #define ERR_CONFMOD 8
  11. #define ERR_TMPMOD 9
  12. #define ERR_NOCONF 10
  13. #define ERR_CONFBADENC 11
  14. #define ERR_WRONGUID 12
  15. #define ERR_WRONGUNAME 13
  16. #define ERR_BADCONF 14
  17. #define ERR_BADBOT 15
  18. #define ERR_BADPASS 16
  19. #define ERR_BOTDISABLED 17
  20. #define ERR_NOBOTS 18
  21. #define ERR_MAX 19
  22. #define EMAIL_OWNERS BIT0
  23. #define EMAIL_TEAM BIT1
  24. #define DETECT_LOGIN 1
  25. #define DETECT_TRACE 2
  26. #define DETECT_PROMISC 3
  27. #define DETECT_PROCESS 4
  28. #define DETECT_SIGCONT 5
  29. #define DET_IGNORE 0
  30. #define DET_WARN 1
  31. #define DET_REJECT 2
  32. #define DET_DIE 3
  33. #define DET_SUICIDE 4
  34. void check_mypid();
  35. int clear_tmp();
  36. char *homedir();
  37. char *my_username();
  38. char *my_uname();
  39. char *confdir();
  40. void baduname(char *, char *);
  41. int email(char *, char *, int);
  42. int shell_exec(char *, char *, char **, char **);
  43. void check_last();
  44. void check_promisc();
  45. void check_trace();
  46. void check_processes();
  47. void detected(int, char *);
  48. void werr(int);
  49. char *werr_tostr(int);
  50. void check_crontab();
  51. void crontab_del();
  52. int crontab_exists();
  53. void crontab_create(int);
  54. void check_trace_start();
  55. #endif /* _SHELL_H */