EAP packet classes organized in hierarchy now

This commit is contained in:
2016-09-01 10:25:33 +02:00
parent 98bd9f1935
commit 844b185887
16 changed files with 492 additions and 377 deletions

View File

@@ -85,6 +85,11 @@ namespace eap
/// Diameter AVP
///
struct diameter_avp;
///
/// EAP packet
///
class packet;
}
///
@@ -638,6 +643,58 @@ namespace eap
#pragma warning(pop)
};
#pragma pack(pop)
class packet
{
public:
///
/// Constructs an empty packet
///
packet();
///
/// Copies a packet
///
/// \param[in] other Packet to copy from
///
packet(_In_ const packet &other);
///
/// Moves a packet
///
/// \param[in] other Packet to move from
///
packet(_Inout_ packet &&other);
///
/// Copies a packet
///
/// \param[in] other Packet to copy from
///
/// \returns Reference to this object
///
packet& operator=(_In_ const packet &other);
///
/// Moves a packet
///
/// \param[in] other Packet to move from
///
/// \returns Reference to this object
///
packet& operator=(_Inout_ packet &&other);
///
/// Empty the packet
///
virtual void clear();
public:
EapCode m_code; ///< Packet code
unsigned char m_id; ///< Packet ID
sanitizing_blob m_data; ///< Packet data
};
}