← 返回命令列表

Linux command

yarac 命令

文本

复制后可按需替换文件名、目录或参数。

常用示例

Compile rules

yarac [rules.yar] [rules.yarc]

Compile multiple files

yarac [rule1.yar] [rule2.yar] [output.yarc]

Show warnings

yarac -w [rules.yar] [output.yarc]

说明

yarac compiles YARA rule source files into an optimized binary format. Precompiled rules load significantly faster than parsing source files each time, which matters when scanning large file sets or running rules on production systems. Multiple rule files can be combined into a single compiled output, consolidating an entire rule set into one deployable binary. External variables can be defined at compile time with -d to parameterize rules without modifying the source. Compiled rule files are not portable across different YARA versions, so rules must be recompiled after upgrading YARA. The -w flag enables warnings during compilation to catch potential issues in rule definitions before deployment.

参数

-w
Show warnings.
-d _VAR=VAL_
Define variable.
--help
Show help.

FAQ

What is the yarac command used for?

yarac compiles YARA rule source files into an optimized binary format. Precompiled rules load significantly faster than parsing source files each time, which matters when scanning large file sets or running rules on production systems. Multiple rule files can be combined into a single compiled output, consolidating an entire rule set into one deployable binary. External variables can be defined at compile time with -d to parameterize rules without modifying the source. Compiled rule files are not portable across different YARA versions, so rules must be recompiled after upgrading YARA. The -w flag enables warnings during compilation to catch potential issues in rule definitions before deployment.

How do I run a basic yarac example?

Run `yarac [rules.yar] [rules.yarc]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

What does -w do in yarac?

Show warnings.