mirror of https://github.com/OISF/suricata
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Issue: 7672
The subslice transform creates a slice of the input buffer.
Specify the subslice desired -- nbytes and truncate are optional:
subslice: offset <,nbytes> <,truncate>
offset: Specifies the starting offset for the new subslice. When
negative, expresses how far from the end of the input buffer to begin.
nbytes: Specifies the size of the subslice. When negative, specifies
that the subslice will end that many bytes from the end of the input
buffer. Nbytes must be non-zero.
When nbytes is not specified, the size of the subslice will be the size
of the input buffer - offset.
truncate: Specify behavior when offset + nbytes exceeds buffer length.
When present, trims nbytes such that offset + nbytes equals buffer
length. When not present, an empty buffer is produced.
Examples:
subslice: 1; - The subslice will be a copy of the input
buffer but omits the input buffer's first byte
"This is Suricata" -> "his is Suricata"
subslice: 0, 13; - The slice is created from the first 13 bytes
of the input buffer
"This is Suricata" -> "This is Suric"
subslice: 10, -5; - The subslice is created starting at offset 10
and continues to 5 bytes before the end of the input buffer
"This is Suricata" -> "r"
subslice: -3; - The subslice will be the last 3 bytes of the
input buffer.
"This is Suricata" -> "ata"
|
6 months ago | |
|---|---|---|
| .. | ||
| .cargo | 2 years ago | |
| derive | 7 months ago | |
| ffi | 6 months ago | |
| htp | 10 months ago | |
| src | 6 months ago | |
| suricatactl | 7 months ago | |
| suricatasc | 7 months ago | |
| sys | 6 months ago | |
| .gitignore | 2 years ago | |
| Cargo.lock.in | 6 months ago | |
| Cargo.toml.in | 9 months ago | |
| Makefile.am | 7 months ago | |
| cbindgen.toml | 7 months ago | |
| rustfmt.toml | ||