LogExpression represents an nftables expression for logging packet information. This allows for debugging, auditing, or general monitoring of network traffic.
Fields
| Field Name | Description |
|---|---|
level - NftLogLevel!
|
The severity level of the log message. |
flags - NftLogFlags!
|
Flags to control which additional information is included in the log message. |
key - NftLogKey!
|
A key to categorize or configure specific logging behavior. |
snaplen - Uint32!
|
The snapshot length (number of bytes) of the packet to include in the log. |
group - Int!
|
The nflog group to send the log message to (if NFLOG flag is set), returned as an unsigned 16-bit integer. |
qThreshold - Int!
|
The queue threshold for nflog, defining how many packets to queue before sending to userspace, returned as an unsigned 16-bit integer. |
data - String!
|
An optional prefix string to add to the beginning of the log message. |
Used by
ChainExpressionunion: A union of all possible nftables chain expression types.
Example
Example
{
"level": "EMERGENCY",
"flags": "TCPSEQ",
"key": "UNSPEC",
"snaplen": "1073741824",
"group": 987,
"qThreshold": 987,
"data": "xyz789"
}