Endpoint configuration · GraphQL type

PayloadExpression type

PayloadExpression represents an nftables expression for accessing and manipulating packet payload data at various layers (link, network, transport). It allows for loading data into registers or writing data from registers back into the packet.

Fields

Field Name Description
operationType - PayloadOperationType! The type of operation: either LOAD data from the packet or WRITE data to the packet.
destRegister - NftRegister! The destination register where data will be loaded (if operationType is LOAD).
sourceRegister - NftRegister! The source register from which data will be written (if operationType is WRITE).
base - PayloadBase! The base offset from which to start accessing the payload (e.g., link layer, network layer).
offset - Uint32! The byte offset relative to the specified 'base' where data access begins.
len - Uint32! The length in bytes of the data to access (load or write).
csumType - PayloadCsumType! The type of checksum operation to perform (e.g., NONE, INET).
csumOffset - Uint32! The byte offset where the checksum field is located within the packet if a checksum operation is being performed.

Used by

  • ChainExpression union: A union of all possible nftables chain expression types.

Example

Example

{
  "operationType": "LOAD",
  "destRegister": "VERDICT",
  "sourceRegister": "VERDICT",
  "base": "LL_HEADER",
  "offset": "1073741824",
  "len": "1073741824",
  "csumType": "NONE",
  "csumOffset": "1073741824"
}