1 #ifndef PACKETPP_IPV6_EXTENSION
2 #define PACKETPP_IPV6_EXTENSION
51 virtual size_t getExtensionLen()
const {
return 8 * (getBaseHeader()->headerLen+1); }
70 struct ipv6_ext_base_header
77 IPv6Extension(IDataContainer* dataContainer,
size_t offset) :
78 m_NextHeader(NULL), m_ExtType(
IPv6ExtensionUnknown), m_DataContainer(dataContainer), m_Offset(offset), m_ShadowData(NULL) {}
82 m_NextHeader(NULL), m_ExtType(
IPv6ExtensionUnknown), m_DataContainer(NULL), m_Offset(0), m_ShadowData(NULL) {}
85 IPv6Extension& operator=(
const IPv6Extension& other);
87 uint8_t* getDataPtr()
const;
89 void initShadowPtr(
size_t size);
91 ipv6_ext_base_header* getBaseHeader()
const {
return (ipv6_ext_base_header*)getDataPtr(); }
93 void setNextHeader(IPv6Extension* nextHeader) { m_NextHeader = nextHeader; }
95 IPv6Extension* m_NextHeader;
99 IDataContainer* m_DataContainer;
101 uint8_t* m_ShadowData;
201 static const uint8_t Pad0OptionType = 0;
202 static const uint8_t PadNOptionType = 1;
220 return sizeof(uint8_t);
222 return (
size_t)(m_Data->
recordLen +
sizeof(uint16_t));
286 TLVRecordBuilder::operator=(other);
303 IPv6Option
getOption(uint8_t optionType)
const;
425 IPv6RoutingHeader(uint8_t routingType, uint8_t segmentsLeft,
const uint8_t* additionalRoutingData,
size_t additionalRoutingDataLen);
501 IPv6AuthenticationHeader(uint32_t securityParametersIndex, uint32_t sequenceNumber,
const uint8_t* integrityCheckValue,
size_t integrityCheckValueLen);
537 #endif // PACKETPP_IPV6_EXTENSION