Feature/#187 change allowlist regexes filenames (#189)
* add risk level filter arguments #45 * fix default level in help #45 * add test yaml files #45 * refactoring and fix level argument usage. * cargo fmt --all * add risk level filter arguments #45 * fix default level in help #45 * add test yaml files #45 * refactoring and fix level argument usage. * cargo fmt --all * update * change filename * fix regexe and allowlist filename in document #187 Co-authored-by: DustInDark <nextsasasa@gmail.com>
This commit is contained in:
@@ -243,12 +243,12 @@ Currently, the following keywords can be specified.
|
||||
* regexes: matches if one of the regular expressions in the file that you specify in this field matches.
|
||||
* allowlist: rule will be skipped if there is any match found in the list of regular expressions in the file that you specify in this field.
|
||||
|
||||
### regexes.txt and allowlist.txt
|
||||
Hayabusa provides built-in rules using regular expressions (defined in `regexes.txt`) and allowlisting (defined in `allowlist.txt`).
|
||||
regexes.txt and allowlist.txt can be edited to change the behavior of all referenced rules at once.
|
||||
### regexes and allowlist
|
||||
Hayabusa provides built-in rules using regular expressions (defined in `config/regex/regexes_suspicous_service.txt`) and allowlisting (defined in `config/regex/allowlist_legimate_serviceimage.txt`).
|
||||
regexes and allowlist can be edited to change the behavior of all referenced rules at once.
|
||||
|
||||
You can also specify to use different regexes and allowlist textfiles.
|
||||
Please refer to the default regexes.txt and allowlist.txt when creating your own.
|
||||
Please refer to the default regexes_suspicous_service.txt and allowlist_legimate_serviceimage.txt when creating your own.
|
||||
|
||||
## condition
|
||||
With the notation we explained above, you can express AND and OR logic but it will be confusing if you are trying to define complex logic.
|
||||
|
||||
@@ -238,10 +238,10 @@ detection:
|
||||
* regexes: 指定したファイルに記載された正規表現のリストにひとつでも一致すれば、`条件に一致した`ものとして処理されます。
|
||||
* allowlist: 指定したファイルに記載された正規表現のリストにひとつでも一致すれば、`条件に一致していない`ものとして処理されます。
|
||||
|
||||
### regexes.txtとallowlist.txt
|
||||
hayabusaではregexesやallowlistを使用した組み込みのルールを用意しており、それらのルールはregexes.txtとallowlist.txtを参照しています。regexes.txtとallowlist.txtを書き換えることで、参照する全てのルールの挙動を一度に変更することが可能です。
|
||||
### regexesとallowlist
|
||||
hayabusaではregexesやallowlistを使用した組み込みのルールを用意しており、それらのルールはhayabusa/config/regex内にあるregexes_suspicous_service.txtとallowlist_legimate_serviceimage.txtを参照しています。これらのファイルを書き換えることで、参照する全てのルールの挙動を一度に変更することが可能です。
|
||||
|
||||
また、regexesやallowlistに指定するファイルは、ユーザーが独自に作成することも可能です。作成する場合、regexes.txtとallowlist.txtを参考にしてください。
|
||||
また、regexesやallowlistに指定するファイルは、ユーザーが独自に作成することも可能です。作成する場合、regexes_suspicous_service.txtとallowlist_legimate_serviceimage.txtを参考にしてください。
|
||||
|
||||
## condition
|
||||
これまでの記法を用いると、AND条件やOR条件を表現することができますが、ANDやOR等が複雑に入り組んだ条件を定義することは難しい場合があります。その場合、conditionというキーワードを使用することで、複雑な条件式を定義することができます。
|
||||
|
||||
Reference in New Issue
Block a user