Jason Ish
c5b26e2043
rust: fix clippy ling for needless borrows
...
Cleanup needless borrows found by clippy. This fix done automatically by
`cargo clippy --fix`.
3 years ago
Jason Ish
d712a8b29d
eve/dns: remove dns v1 logging
...
Removal of DNS v1 logging was scheduled to be removed in May 2022.
Ticket: #4157
3 years ago
Jason Ish
0861b66e15
dns: add dns flag to dns request logging
...
Ticket #4515
4 years ago
Odin Jenseg
dfb6f105e8
dns: Logging of Z-bit
...
[Edit by Jason Ish: fix flag bit value]
Ticket #4515
4 years ago
Jason Ish
d5c0962299
rust(lint): fix some usages of references
...
- ref is discouraged for top level variables
- the other borrow is not required
4 years ago
Jason Ish
69cf5c9eea
rust(lint): remove needless borrows
...
These are needless borrows (references) as the item is already
a reference.
4 years ago
Sascha Steinbiss
08a6f1441a
dns: parse SRV records
5 years ago
Antti Tönkyrä
f3ad7f14fa
dns: add rdata logging for NS rrtype
5 years ago
Simon Dugas
4336a0e739
dns: log rdata for NULL record type
...
Logs the rdata for a NULL record type as a printable string.
5 years ago
Simon Dugas
7f26246ce1
dns: parse and log fields for SOA record type
...
Added `dns_parse_rdata_soa` to parse SOA fields into an `DNSRDataSOA`
struct.
Added logging for answer and authority SOA records in both version
1 & 2, as well as grouped formats.
5 years ago
Simon Dugas
8005f50647
dns: refactor to handle more rdata formats
...
Represent rdata as `DNSRData` enum variants instead of `Vec<u8>`.
This will allow parsing/logging of more complex formats like SOA.
5 years ago
Jason Ish
03cf3dcd6d
dns/eve: convert to jsonbuilder
5 years ago
Jason Ish
d809b0959b
dns: cleanup: move DnsGetRcode (Lua) to rust
...
Move the implementation of Lua DnsGetRcode to Rust.
5 years ago
Jason Ish
42e5065ab8
rust: update to Rust 2018 with cargo fix
...
Migrate to Rust 2018 edition.
Credit to Danny Browning for first demontrating this:
https://github.com/OISF/suricata/pull/3604/commits
6 years ago
Victor Julien
3f6624bf16
rust: remove libc crate dependency
...
Use std::os::raw instead.
6 years ago
Victor Julien
bf1bd407dd
rust: fix libc deprecation warnings for int types
6 years ago
Jason Ish
b7083bc3a8
rust/dns/v2 - log rrtype in response
...
Redmine issue:
https://redmine.openinfosecfoundation.org/issues/2723
7 years ago
Jason Ish
b7a58680db
dns/rust - if let Some over options instead of loop.
...
Except in one case where the loop makes more sense for easy break
out.
Also remove one line of non-conforming debug logging.
7 years ago
Jason Ish
87250da0fc
rust/dns: add v1 dns logging
...
Redmine issue:
https://redmine.openinfosecfoundation.org/issues/2704
7 years ago
Jason Ish
27fd521420
eve/dns/v2: support eve/dns v2 in rust
7 years ago
Jason Ish
5a8537fe4a
rust/dns - convert more type values to text
...
Issue:
https://redmine.openinfosecfoundation.org/issues/2364
Convert more record type and errr code values to text.
Remove duplicate type declarations.
8 years ago
Clément Galland
3396747cd6
Dns logger display flags information
8 years ago
Jason Ish
40991cab82
rust/dns: handle multiple txt strings
...
Fix handling of TXT records when there are multiple strings
in a single TXT record. For now, conform to the C implementation
where an answer record is created for each string in a single
txt record.
Also removes the data_len field from the answer entry. In Rust,
the length is available from actual data, which after decoding
may actually be different than the encoded data length, so just
use the length from the actual data.
8 years ago
Jason Ish
829155b9d5
rust/dns: pass byte arrays directly to rust/json
...
Using the json.set_string_from_bytes which will
safely convert the bytes printable ascii string
before logging.
8 years ago
Jason Ish
c473c56eed
rust/dns: fix panic on rrnames with bad chars
...
Check for erros in the UTF-8 conversion, on error, print the
the printable chars as chars, and print non printable chars
as \xHEX.
Redmine issue:
https://redmine.openinfosecfoundation.org/issues/2148
8 years ago
Jason Ish
2aebfbce94
rust/dns: support txt records
8 years ago
Jason Ish
ba1a67e2cb
rust: dns: add log filtering on rrtype
...
While the filtering is still configured in C, the filtering
flags are passed into Rust so it can determine if a record
should be logged or not.
8 years ago
Jason Ish
b588b49779
rust: lua support for DNS based Rust
...
Uses Rust wrappers around Lua to populate Lua
data structures.
8 years ago
Jason Ish
73388042b2
rust: DNS app-layer.
...
A DNS application layer in Rust. This is different than the
C based one, as it is partially stateless by not matching
up responses to replies.
8 years ago