|
|
@@ -1,5 +1,5 @@ |
|
|
|
// snf_sync.hpp |
|
|
|
// Copyright (C) 2006 - 2009 ARM Research Labs, LLC. |
|
|
|
// Copyright (C) 2006 - 2020 ARM Research Labs, LLC. |
|
|
|
// See www.armresearch.com for the copyright terms. |
|
|
|
// |
|
|
|
// SNF engine communications protocol interpreter. |
|
|
@@ -22,13 +22,13 @@ class GBUAlertHandler : public cd::Configurator { |
|
|
|
|
|
|
|
void reset(); // Resets the list for a new run. |
|
|
|
|
|
|
|
list<GBUdbAlert> AlertList; // Our list of alerts. |
|
|
|
std::list<GBUdbAlert> AlertList; // Our list of alerts. |
|
|
|
|
|
|
|
// Input variables. |
|
|
|
|
|
|
|
string Alert_time; // time='YYYYMMDDhhmmss' |
|
|
|
string Alert_ip; // ip='12.34.56.78' |
|
|
|
string Alert_t; // t='Ugly', Good, Bad, Ignore |
|
|
|
std::string Alert_time; // time='YYYYMMDDhhmmss' |
|
|
|
std::string Alert_ip; // ip='12.34.56.78' |
|
|
|
std::string Alert_t; // t='Ugly', Good, Bad, Ignore |
|
|
|
int Alert_b; // b='0' |
|
|
|
int Alert_g; // g='0' |
|
|
|
}; |
|
|
@@ -59,20 +59,20 @@ class snf_sync { |
|
|
|
public: |
|
|
|
snf_sync(); // Construct empty. |
|
|
|
snf_sync(const char* bfr, int len); // Construct from buffer. |
|
|
|
snf_sync(string& input); // Construct from string. |
|
|
|
snf_sync(std::string& input); // Construct from string. |
|
|
|
bool read(const char* bfr, int len); // Read from buffer. |
|
|
|
bool read(string& input); // Read from string. |
|
|
|
bool read(std::string& input); // Read from string. |
|
|
|
|
|
|
|
//// And now the interpreted results //// |
|
|
|
bool good(); // True if read was good. |
|
|
|
bool bad(); // True if read was not good. |
|
|
|
|
|
|
|
string snf_sync_challenge_txt; |
|
|
|
string snf_sync_response_nodeid; |
|
|
|
string snf_sync_response_text; |
|
|
|
string snf_sync_error_message; |
|
|
|
std::string snf_sync_challenge_txt; |
|
|
|
std::string snf_sync_response_nodeid; |
|
|
|
std::string snf_sync_response_text; |
|
|
|
std::string snf_sync_error_message; |
|
|
|
int snf_sync_error_code; |
|
|
|
string snf_sync_rulebase_utc; |
|
|
|
std::string snf_sync_rulebase_utc; |
|
|
|
int snf_sync_server_resync_secs; |
|
|
|
|
|
|
|
GBUAlertHandler ClientGBUAlertHandler; // GBU Alerts received from client |