PcapPlusPlus
|
#include <PcapFilter.h>
Public Member Functions | |
MacAddressFilter (MacAddress address, Direction dir) | |
void | parseToString (std::string &result) |
void | setMacAddress (MacAddress address) |
Public Member Functions inherited from pcpp::IFilterWithDirection | |
void | setDirection (Direction dir) |
Public Member Functions inherited from pcpp::GeneralFilter | |
virtual | ~GeneralFilter () |
A class for filtering Ethernet traffic by MAC addresses, for example: "ether src 12:34:56:78:90:12" or "ether dst "10:29:38:47:56:10:29"
For deeper understanding of the filter concept please refer to PcapFilter.h
|
inline |
A constructor that gets the MAC address and the direction and creates the filter with them
[in] | address | The MAC address to use for filtering |
[in] | dir | The MAC address direction to filter (source or destination) |
|
virtual |
A method that parses the class instance into BPF string format
[out] | result | An empty string that the parsing will be written into. If the string isn't empty, its content will be overridden |
Implements pcpp::GeneralFilter.
|
inline |
Set the MAC address
[in] | address | The MAC address to use for filtering |