参数
英文版
YARA 4.2.0, the pattern matching swiss army knife.Usage: yara [OPTION]... [NAMESPACE:]RULES_FILE... FILE | DIR | PIDMandatory arguments to long options are mandatory for short options too. --atom-quality-table=FILE path to a file with the atom quality table -C, --compiled-rules load compiled rules -c, --count print only number of matches -d, --define=VAR=VALUE define external variable --fail-on-warnings fail on warnings -f, --fast-scan fast matching mode -h, --help show this help and exit -i, --identifier=IDENTIFIER print only rules named IDENTIFIER --max-process-memory-chunk=NUMBER set maximum chunk size while reading process memory (default=1073741824) -l, --max-rules=NUMBER abort scanning after matching a NUMBER of rules --max-strings-per-rule=NUMBER set maximum number of strings per rule (default=10000) -x, --module-data=MODULE=FILE pass FILE's content as extra data to MODULE -n, --negate print only not satisfied rules (negate) -N, --no-follow-symlinks do not follow symlinks when scanning -w, --no-warnings disable warnings -m, --print-meta print metadata -D, --print-module-data print module data -e, --print-namespace print rules' namespace -S, --print-stats print rules' statistics -s, --print-strings print matching strings -L, --print-string-length print length of matched strings -g, --print-tags print tags -r, --recursive recursively search directories --scan-list scan files listed in FILE, one per line -z, --skip-larger=NUMBER skip files larger than the given size when scanning a directory -k, --stack-size=SLOTS set maximum stack size (default=16384) -t, --tag=TAG print only rules tagged as TAG -p, --threads=NUMBER use the specified NUMBER of threads to scan a directory -a, --timeout=SECONDS abort scanning after the given number of SECONDS -v, --version show version informationSend bug reports and suggestions to: vmalvarez@virustotal.com.
中文版
--atom-quality-table=FILE 带有原子质量表的文件的路径 -C, --compiled-rules 加载编译规则 -c, --count 仅打印匹配数 -d, --define=VAR=VALUE 定义外部变量 --fail-on-warnings 警告失败 -f, --fast-scan 快速匹配模式 -h, --help 显示此帮助并退出 -i, --identifier=IDENTIFIER 仅打印名为 “IDENTIFIER(输入字符串)” 的规则 --max-process-memory-chunk=NUMBER 在读取进程内存时设置最大块大小(默认=1073741824) -l, --max-rules=NUMBER 匹配 “NUMBER(输入数字)” 条规则后中止扫描 --max-strings-per-rule=NUMBER 设置每个规则的最大字符串数(默认值=10000) -x, --module-data=MODULE=FILE 将 FILE 的内容作为额外数据传递给 MODULE -n, --negate 只打印不满足的规则(否定) -N, --no-follow-symlinks 扫描时不要跟随符号链接 -w, --no-warnings 禁用警告 -m, --print-meta 打印元数据 -D, --print-module-data 打印模块数据 -e, --print-namespace 打印规则的命名空间 -S, --print-stats 打印规则的统计信息 -s, --print-strings 打印匹配的字符串 -L, --print-string-length 打印匹配字符串的长度 -g, --print-tags 打印标签 -r, --recursive 递归搜索目录 --scan-list 扫描 “FILE” 中列出的文件,每行一个 -z, --skip-larger=NUMBER 扫描目录时跳过大于给定大小的文件 -k, --stack-size=SLOTS 设置最大堆栈大小(默认=16384) -t, --tag=TAG 仅打印标记为 “TAG(输入字符串)” 的规则 -p, --threads=NUMBER 使用指定的线程数扫描目录 -a, --timeout=SECONDS 在给定的秒数后中止扫描 -v, --version 显示版本信息
功能
打印
-c, --count 仅打印匹配数 -i, --identifier=IDENTIFIER 仅打印名为 “IDENTIFIER(输入字符串)” 的规则 -n, --negate 只打印不满足的规则(否定) -m, --print-meta 打印元数据 -D, --print-module-data 打印模块数据 -e, --print-namespace 打印规则的命名空间 -S, --print-stats 打印规则的统计信息 -s, --print-strings 打印匹配的字符串 -L, --print-string-length 打印匹配字符串的长度 -g, --print-tags 打印标签 -t, --tag=TAG 仅打印标记为 “TAG(输入字符串)” 的规则 -w, --no-warnings 禁用警告
其他
--atom-quality-table=FILE 带有原子质量表的文件的路径 -C, --compiled-rules 加载编译规则 -d, --define=VAR=VALUE 定义外部变量 --fail-on-warnings 警告失败 -f, --fast-scan 快速匹配模式 -h, --help 显示此帮助并退出 --max-process-memory-chunk=NUMBER 在读取进程内存时设置最大块大小(默认=1073741824) -l, --max-rules=NUMBER 匹配 “NUMBER(输入数字)” 条规则后中止扫描 --max-strings-per-rule=NUMBER 设置每个规则的最大字符串数(默认值=10000) -x, --module-data=MODULE=FILE 将 FILE 的内容作为额外数据传递给 MODULE -N, --no-follow-symlinks 扫描时不要跟随符号链接 -r, --recursive 递归搜索目录 --scan-list 扫描 “FILE” 中列出的文件,每行一个 -z, --skip-larger=NUMBER 扫描目录时跳过大于给定大小的文件 -k, --stack-size=SLOTS 设置最大堆栈大小(默认=16384) -p, --threads=NUMBER 使用指定的线程数扫描目录 -a, --timeout=SECONDS 在给定的秒数后中止扫描 -v, --version 显示版本信息