libmoost
|
00001 /* vim:set ts=3 sw=3 sts=3 et: */ 00028 // [ricky 7/13/2011 ] Mostly ripped from the nsca_send common.h file 00029 00030 #ifndef MOOST_NAGIOS_NSCA_CLIENT_NSCA_COMMON_HPP__ 00031 #define MOOST_NAGIOS_NSCA_CLIENT_NSCA_COMMON_HPP__ 00032 00033 #include <boost/cstdint.hpp> 00034 00035 namespace moost { namespace nagios { 00036 00037 // some constants that can be reused 00038 namespace nsca_const 00039 { 00040 // default config values (these are lfm specific, obviously) 00041 static const char * const DEFAULT_HOST = "xenu.sov.last.fm"; 00042 static const size_t DEFAULT_PORT = 5667; 00043 static const int DEFAULT_RECV_TIMEOUT_MS = 1000; 00044 static const int DEFAULT_SEND_TIMEOUT_MS = 1000; 00045 static const char * const DEFAULT_ENCTYPE = "xor"; 00046 00047 // default values for nsca internals 00048 static const size_t TRANSMITTED_IV_SIZE = 128; 00049 static const size_t MAX_HOSTNAME_LENGTH = 64; 00050 static const size_t MAX_DESCRIPTION_LENGTH = 128; 00051 static const size_t MAX_PLUGINOUTPUT_LENGTH = 512; 00052 static const size_t MAX_PASSWORD_LENGTH = 512; 00053 static const boost::int16_t NSCA_PACKET_VERSION = 3; 00054 } 00055 00056 // supported encryption methods 00057 struct nsca_encryption_method 00058 { 00059 enum type 00060 { 00061 ENCRYPT_NONE = 0, 00062 ENCRYPT_XOR = 1 00063 00064 #ifdef HAVE_LIBMCRYPT 00065 , 00066 ENCRYPT_DES = 2, 00067 ENCRYPT_3DES = 3, 00068 ENCRYPT_CAST128 = 4, 00069 ENCRYPT_CAST256 = 5, 00070 ENCRYPT_XTEA = 6, 00071 ENCRYPT_3WAY = 7, 00072 ENCRYPT_BLOWFISH = 8, 00073 ENCRYPT_TWOFISH = 9, 00074 ENCRYPT_LOKI97 = 10, 00075 ENCRYPT_RC2 = 11, 00076 ENCRYPT_ARCFOUR = 12, 00077 ENCRYPT_RC6 = 13, 00078 ENCRYPT_RIJNDAEL128 = 14, 00079 ENCRYPT_RIJNDAEL192 = 15, 00080 ENCRYPT_RIJNDAEL256 = 16, 00081 ENCRYPT_MARS = 17, 00082 ENCRYPT_PANAMA = 18, 00083 ENCRYPT_WAKE = 19, 00084 ENCRYPT_SERPENT = 20, 00085 ENCRYPT_IDEA = 21, 00086 ENCRYPT_ENIGMA = 22, 00087 ENCRYPT_GOST = 23, 00088 ENCRYPT_SAFER64 = 24, 00089 ENCRYPT_SAFER128 = 25, 00090 ENCRYPT_SAFERPLUS = 26 00091 #endif 00092 }; 00093 }; 00094 00095 }} 00096 00097 #endif