mirror of
https://github.com/zeek/zeek.git
synced 2025-10-03 15:18:20 +00:00
Migrate all packet analyzers to new API.
This commit is contained in:
parent
cbdaa53f85
commit
6365fa6d80
34 changed files with 135 additions and 105 deletions
|
@ -9,12 +9,12 @@ LinuxSLLAnalyzer::LinuxSLLAnalyzer()
|
|||
{
|
||||
}
|
||||
|
||||
zeek::packet_analysis::AnalysisResultTuple LinuxSLLAnalyzer::Analyze(Packet* packet, const uint8_t*& data)
|
||||
zeek::packet_analysis::AnalyzerResult LinuxSLLAnalyzer::Analyze(Packet* packet, const uint8_t*& data)
|
||||
{
|
||||
if ( data + sizeof(SLLHeader) >= packet->GetEndOfData() )
|
||||
{
|
||||
packet->Weird("truncated_Linux_SLL_header");
|
||||
return { AnalyzerResult::Failed, 0 };
|
||||
return AnalyzerResult::Failed;
|
||||
}
|
||||
|
||||
//TODO: Handle different ARPHRD_types
|
||||
|
@ -28,5 +28,5 @@ zeek::packet_analysis::AnalysisResultTuple LinuxSLLAnalyzer::Analyze(Packet* pac
|
|||
packet->l2_dst = Packet::L2_EMPTY_ADDR;
|
||||
|
||||
data += sizeof(SLLHeader);
|
||||
return { AnalyzerResult::Continue, protocol };
|
||||
return AnalyzeInnerPacket(packet, data, protocol);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue