Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rust add external parsers 3 #2798

Closed
wants to merge 6 commits into from

Conversation

chifflier
Copy link
Contributor

Make sure these boxes are signed before submitting your Pull Request -- thank you.

Describe changes:

  • This PR adds the '--enable-rust-experimental' configure flag, for (embedded) rust app layers with external dependencies and/or experimental status
  • It adds support for the NTP protocol, implemented in Rust. The decoding logic is embedded, only the raw parser is an external rust crate (https://github.com/rusticata/ntp-parser)
  • The parser is mostly used as an example, and does protocol validation for NTP version 3 and 4.
  • Some event rules have been added, to detect malformed NTP data
  • This is meant to be an example parser, before working on similar integration for IKEv2 (and later, SNMP, SSH alternative parser, etc.)
  • All comments from Rust add external parsers 1 #2792 have been merged: directories, debug statements, build warnings, rules sids
  • Same for Rust add external parsers 2 #2794 : s/external/experimental/; s/tcp/udp/, add reference to SIDs

Thanks,
Pierre

@chifflier chifflier mentioned this pull request Jun 21, 2017
3 tasks
@inliniac
Copy link
Contributor

I'm trying to compile this branch with --enable-rust (so not enabling your configure flag), but I get:

make[2]: Entering directory '/home/victor/sync/devel/suricata-rust/rust'
cd ../rust && CARGO_TARGET_DIR=/home/victor/devel/suricata-rust/rust/target \
	/usr/bin/python ./gen-c-headers.py && \
	cargo build   --features "lua "
Writing ./gen/c-headers/rust-log-gen.h
Writing ./gen/c-headers/rust-core-gen.h
    Updating registry `https://github.com/rust-lang/crates.io-index`
error: failed to load source for a dependency on `ntp-parser`

Caused by:
  Unable to update registry https://github.com/rust-lang/crates.io-index

@chifflier
Copy link
Contributor Author

Hm, not entirely sure, but:

Unable to update registry https://github.com/rust-lang/crates.io-index

Seems to be the cause of the problem. Network problem ?

@inliniac
Copy link
Contributor

Ok the problem was that I had some permission issues in my ~/.cargo dir. I suspect they were caused by a 'sudo' action as some files were owned by root.

@inliniac inliniac mentioned this pull request Jun 28, 2017
@inliniac
Copy link
Contributor

Merged through #2814, thanks Pierre!

@inliniac inliniac closed this Jun 28, 2017
victorjulien pushed a commit to victorjulien/suricata that referenced this pull request Feb 18, 2019
Add support for http_host buffer for more accurate reporting.
Bug: OISF#2798
victorjulien pushed a commit to victorjulien/suricata that referenced this pull request Feb 20, 2019
Add support for http_host buffer for more accurate reporting.
Bug: OISF#2798
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants