Ignore:
Timestamp:
01/20/09 19:53:38 (4 years ago)
Author:
Michael Medin <michael@…>
Branches:
master, 0.4.0, 0.4.1, 0.4.2, stable
Children:
04f2743
Parents:
a4689fc
Message:

2009-01-20 MickeM

  • Fixed issue with CheckWMI when no filter was specified.

2009-01-17 MickeM

+ Added new command line option pdhlookup (to CheckSystem) to lookup index from names.

Probably not usefull to anyone but me :) Usage: "nsclient++ -noboot CheckSystem pdhlookup Antal bindningsreferenser"

  • Fixed so PDH Collectors use the same exception as the rest of the PDH stuff (might give better errors when PDH breaks, but I doubt it)
  • removed debug output from -noboot + Added new command line option pdhmatch to use pattern matching on PDH queries Usage: nsclient++ -noboot CheckSystem pdhmatch \Process(*)\Antal trådar
  • Improved error reporting in the PDH subsystem. + Added new module A_DebugLogMetrics.dll which can be used to generate debug info. Enable the module and a file called process_info.csv will be created under %APP_DATA%/nsclient++/process_info.csv which contains metrics.
  • Fixed handle leak in CheckExternalProcess? and NRPEListsner (executing commands).

2009-01-13 MickeM

  • Fixed issue with 64-bit installer (now installs under Program Files (and not x86) + Brand new build enviornment based upon boost build!!! Use batch file to build (release-build.bat or modify to make your own)
  • Modified /about so it now shows a lot of usefull(?) info.

2008-11-13 MickeM

+ Added truncate option to checkServiceState

2008-09-24 MickeM

  • Imroved the installer (now auto-updates the version when built)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • modules/NSCAAgent/nsca_enrypt.hpp

    r846bbe4 r3692371  
    1 #define HAVE_LIBCRYPTOPP 
    2  
    31#ifdef HAVE_LIBCRYPTOPP 
    42#include <crypto++/cryptlib.h> 
     
    5351#define ENCRYPT_SAFERPLUS       26      /* SAFER+ */ 
    5452#endif 
    55  
     53#define LAST_ENCRYPTION_ID 26 
    5654 
    5755class nsca_encrypt { 
     
    7068    virtual void encrypt(unsigned char *buffer, int buffer_size) = 0; 
    7169    virtual void decrypt(unsigned char *buffer, int buffer_size) = 0; 
    72   }; 
     70    virtual std::wstring getName() = 0; 
     71  }; 
     72#ifdef HAVE_LIBCRYPTOPP 
    7373  template <class TMethod> 
    7474  class cryptopp_encryption : public any_encryption { 
     
    137137      throw encryption_exception(_T("Decryption not supported")); 
    138138    } 
    139  
    140   }; 
     139    std::wstring getName() { 
     140      return TMethod::StaticAlgorithmName(); 
     141    } 
     142 
     143  }; 
     144#endif 
    141145  class no_encryption : public any_encryption { 
    142146  public: 
     
    150154    void encrypt(unsigned char *buffer, int buffer_size) {} 
    151155    void decrypt(unsigned char *buffer, int buffer_size) {} 
     156    std::wstring getName() { 
     157      return _T("No Encryption (not safe)"); 
     158    } 
    152159  }; 
    153160  class xor_encryption : public any_encryption { 
     
    205212    void decrypt(unsigned char *buffer, int buffer_size) { 
    206213      throw encryption_exception(_T("Decryption not supported")); 
     214    } 
     215    std::wstring getName() { 
     216      return _T("XOR (not safe)"); 
    207217    } 
    208218  }; 
     
    237247 
    238248// UNdefined 
     249#ifdef HAVE_LIBCRYPTOPP 
    239250      case ENCRYPT_3WAY: 
    240251      case ENCRYPT_ARCFOUR: 
     
    248259      case ENCRYPT_SAFER128: 
    249260      case ENCRYPT_SAFERPLUS: 
     261#endif 
    250262      default: 
    251263        return false; 
     
    329341    core_->encrypt(buffer, buffer_size); 
    330342  } 
    331  
    332343  unsigned char* get_rand_buffer(int length) { 
     344    unsigned char * buffer = new unsigned char[length+1]; 
     345#if HAVE_LIBCRYPTOPP 
    333346    CryptoPP::AutoSeededRandomPool rng; 
    334     unsigned char * buffer = new unsigned char[length+1]; 
    335347    rng.GenerateBlock(buffer, length); 
     348#endif 
    336349    return buffer; 
    337350  } 
Note: See TracChangeset for help on using the changeset viewer.