mirror of
https://github.com/zeek/zeek.git
synced 2025-10-03 07:08:19 +00:00
Move MySQL analyzer to the new plugin architecture.
This commit is contained in:
parent
b259a41ef2
commit
45d5080870
2 changed files with 18 additions and 6 deletions
|
@ -28,7 +28,7 @@ public:
|
|||
virtual void EndpointEOF(bool is_orig);
|
||||
|
||||
|
||||
static analyzer::Analyzer* InstantiateAnalyzer(Connection* conn)
|
||||
static analyzer::Analyzer* Instantiate(Connection* conn)
|
||||
{ return new MySQL_Analyzer(conn); }
|
||||
|
||||
static bool Available()
|
||||
|
|
|
@ -1,9 +1,21 @@
|
|||
//See the file in the main distribution directory for copyright.
|
||||
|
||||
#include "plugin/Plugin.h"
|
||||
|
||||
#include "MySQL.h"
|
||||
|
||||
BRO_PLUGIN_BEGIN(Bro, MySQL)
|
||||
BRO_PLUGIN_DESCRIPTION("MySQL analyzer");
|
||||
BRO_PLUGIN_ANALYZER("MySQL", MySQL::MySQL_Analyzer);
|
||||
BRO_PLUGIN_BIF_FILE(events);
|
||||
BRO_PLUGIN_END
|
||||
namespace plugin {
|
||||
namespace Bro_MySQL {
|
||||
class Plugin : public plugin::Plugin {
|
||||
public:
|
||||
plugin::Configuration Configure()
|
||||
{
|
||||
AddComponent(new ::analyzer::Component("MySQL", ::analyzer::MySQL::MySQL_Analyzer::Instantiate));
|
||||
plugin::Configuration config;
|
||||
config.name = "Bro::MySQL";
|
||||
config.description = "MySQL analyzer";
|
||||
return config;
|
||||
}
|
||||
} plugin;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue