yara-sys

Crates.io Documentation

Native bindings for the Yara library from VirusTotal. Only works with Yara v4.

More documentation can be found on the Yara's documentation.

Features

By default, this crate uses bindgen to generate bindings on-the-fly, but you can also use the following features to use pre-built bindings file for different version of Yara. Just make sure the version you specify is the same that the version on your system!

Link on already compiled libyara

This is the default, when the vendored option is disabled. You can specify the following environment variables:

Compile options for libyara v4.2.3

When using the vendored feature, Yara will be automatically built and linked statically with yara-sys. You can set the following features change how Yara is built:

Features:

ENV variables

Each of these variables can also be supplied with certain prefixes and suffixes, in the following prioritized order:

  1. <var>_<target> - for example, YARA_CRYPTO_LIB_x86_64-unknown-linux-gnu
  2. <var>_<target_with_underscores> - for example, YARA_CRYPTO_LIB_x86_64_unknown_linux_gnu
  3. <var> - a plain YARA_CRYPTO_LIB, as above.

If none of these variables exist, yara-sys uses built-in defaults

License

Licensed under either of

at your option.