shell.h 1.6 KB

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