Class EncapSecurityPayload

  • All Implemented Interfaces:
    IPacket

    public class EncapSecurityPayload
    extends BasePacket
    Implements IPv6 Encapsulating Security Payload (ESP) extension header format. (RFC 4303)
    • Field Detail

      • securityParamIndex

        protected int securityParamIndex
      • sequence

        protected int sequence
    • Constructor Detail

      • EncapSecurityPayload

        public EncapSecurityPayload()
    • Method Detail

      • getSecurityParamIndex

        public int getSecurityParamIndex()
        Gets the security parameter index of this header.
        Returns:
        the security parameter index
      • setSecurityParamIndex

        public EncapSecurityPayload setSecurityParamIndex​(int securityParamIndex)
        Sets the security parameter index of this header.
        Parameters:
        securityParamIndex - the security parameter index to set
        Returns:
        this
      • getSequence

        public int getSequence()
        Gets the sequence number of this header.
        Returns:
        the sequence number
      • setSequence

        public EncapSecurityPayload setSequence​(int sequence)
        Sets the sequence number of this header.
        Parameters:
        sequence - the sequence number to set
        Returns:
        this
      • serialize

        public byte[] serialize()
        Description copied from interface: IPacket
        Sets all payloads parent packet if applicable, then serializes this packet and all payloads.
        Returns:
        a byte[] containing this packet and payloads
      • deserializer

        public static Deserializer<EncapSecurityPayload> deserializer()
        Deserializer function for encapsulated security payload headers.
        Returns:
        deserializer function