--- warning: DO NOT CHANGE THIS MANUALLY, THIS IS GENERATED BY https://github.com/duckdb/community-extensions repository, check README there title: yara excerpt: | DuckDB Community Extensions YARA rule validation + malware-signature scanning in SQL, via pure-Rust yara-x (no libyara) — validate rulesets and scan BLOBs, one row per pattern hit extension: name: yara description: YARA rule validation + malware-signature scanning in SQL, via pure-Rust yara-x (no libyara) — validate rulesets and scan BLOBs, one row per pattern hit version: 0.1.0 language: Rust build: cargo license: MIT excluded_platforms: "wasm_mvp;wasm_eh;wasm_threads;windows_amd64_rtools;windows_amd64_mingw;linux_amd64_musl" requires_toolchains: "rust;python3" maintainers: - alitrack repo: github: alitrack/duckdb-yara ref: 082efda6d744601c1b11bb33618333291b8e73bb ref_next: 082efda6d744601c1b11bb33618333291b8e73bb docs: hello_world: | INSTALL yara FROM community; LOAD yara; -- Pure validation: do these rules compile? (never errors) SELECT yara_check('rule bad { strings: $a = "abc" }'); -- false -- The yara-x modules a rule may import SELECT * FROM yara_modules(); -- Scan data against a ruleset — one row per matched pattern SELECT * FROM yara_string_matches( 'MZ90abc', 'rule MZ { strings: $mz = "MZ" condition: $mz }' ); -- rule | identifier | offset | matched extended_description: | ## yara — YARA in SQL Pure-Rust [yara-x](https://github.com/VirusTotal/yara-x) (no native libyara), so the rules engine compiles into the extension itself. | Function | Returns | Notes | |---|---|---| | `yara_check(rules)` | BOOLEAN | Do the rules compile? NULL in → NULL out. Never errors. | | `yara_modules()` | table | The yara-x modules a rule may `import` | | `yara_string_matches(data, rules)` | table | One row per pattern hit: `rule, identifier, offset, matched` | → [GitHub](https://github.com/alitrack/duckdb-yara) extension_star_count: 0 extension_star_count_pretty: 0 extension_download_count: null extension_download_count_pretty: n/a image: '/images/community_extensions/social_preview/preview_community_extension_yara.png' layout: community_extension_doc --- ### Compatibility Matrix This table covers all DuckDB releases that have not reached [end-of-life](https://duckdb.org/release_calendar), including LTS releases, and shows the 2 most recent patch releases of each. Older patch releases are not listed, but the extension may be available for them as well.
| Platform | 1.4.4 | 1.4.5 | 1.5.5 | 1.5.6 | 2.0.0 | | :--- | :---: | :---: | :---: | :---: | :---: | | Linux AMD64 | ❌ | ❌ | ❌ | ❌ | ✅ | | Linux ARM64 | ❌ | ❌ | ❌ | ❌ | ✅ | | macOS AMD64 | ❌ | ❌ | ❌ | ❌ | ❌ | | macOS ARM64 | ❌ | ❌ | ❌ | ❌ | ✅ | | Windows AMD64 | ❌ | ❌ | ❌ | ❌ | ✅ | | Windows ARM64 | ❌ | ❌ | ❌ | ❌ | ❌ | | WebAssembly | ❌ | ❌ | ❌ | ❌ | ❌ | ### Installing and Loading ```sql INSTALL {{ page.extension.name }} FROM community; LOAD {{ page.extension.name }}; ``` {% if page.docs.hello_world %} ### Example ```sql {{ page.docs.hello_world }}``` {% endif %} {% if page.docs.extended_description %} ### About {{ page.extension.name }} {{ page.docs.extended_description }} {% endif %} ### Added Functions
| function_name | function_type | description | comment | examples | |---------------------|---------------|-------------|---------|----------| | yara_check | scalar | NULL | NULL | | | yara_modules | table | NULL | NULL | | | yara_string_matches | table | NULL | NULL | | ### Overloaded Functions
This extension does not add any function overloads. ### Added Types
This extension does not add any types. ### Added Settings
| name | description | input_type | scope | aliases | typed_value | |----------------|---------------------------------------------------------|------------|--------|---------|-------------| | temp_directory | Set the directory to which temporary files are written. | VARCHAR | GLOBAL | [] | post.db.tmp |