Skip to main content

YARA-X (yara-x)

YARA-X rule engine of the file security pipeline: an authenticated HTTPS worker with the navin-baseline rules and controlled rule updates from the internal repository.

Generated from catalog/services/yara-x.yaml: do not edit by hand.

Summary​

Version1.22.1
Useinstall and configure
Layerfunctional (AI catalog)
CategorySecurity and policies
Installation methodspython
External connectionno
Sandbox onlyno

Licence​

SPDX identifierBSD-3-Clause
Licence policylicence exception
Licence exceptionLEX-023 (pending, awaiting the client)
Platform componentyara-x

Packages and artifacts​

A package the project of the service publishes (its image, its binary archive, its Python or OS package) carries the licence of the service; a third-party package carries the licence written on its row, read from the official upstream metadata.

KindPackageVersionLicenceDetails
Python packageyara-x1.22.1BSD-3-Clauseinterpreters, in order of preference python3.11, python3.12, python3.10

Supported systems and architectures​

MethodOperating systemsArchitectures
pythonRHEL family (dnf), Debian family (apt), Arch Linux (pacman)x86_64, aarch64 (not restricted by the descriptor)

Certified host systems: RHEL 8/9/10, Rocky Linux 8/9/10, AlmaLinux 8/9/10, Oracle Linux 8/9, CentOS Stream 9/10, Ubuntu 22.04/24.04, Debian 12, Arch Linux (rolling). The host preflight accepts these systems (other releases of a known family give a warning, end of life releases are refused) and the x86_64 and aarch64 architectures.

Prerequisites​

Host​

  • at least 1024 MB of memory (warning, memory).

Network and ports​

ComponentPort namePortOpened in the host firewall
workerapi8475/tcpyes

Services and connections needed​

This service has no dependency.

Installation methods and modes​

MethodDefaultWhat the method uses
pythonyesa Python virtual environment holding the Python packages of the descriptor

Components​

ComponentKindInstallation methodsPorts
Worker (worker)masterpython8475/tcp

Single worker (standalone) (default)​

One YARA-X worker.

What the mode deploys:

ComponentPlacement
workermin 1, max 1

Replicated (replicated)​

Two or more independent workers with the same rule set; the platform fails over between them.

What the mode deploys:

ComponentPlacement
workermin 2, recommended 2

Install this service​

The install wizard of the Navin Manager plans, validates and runs the installation; you need the services:install permission on the cluster.

  1. Open the wizard. In Clusters, choose the row action Install services of the target cluster. The wizard opens on its first step, Service.

  2. Choose the service. On the Service step, select YARA-X. The card shows the licence BSD-3-Clause.

  3. Choose the hosts and the mode. On the Hosts step, tick the hosts, then choose the Mode: standalone (default), replicated. Each mode deploys the components listed in Installation methods and modes.

  4. Bindings. This service has no dependency: the Bindings step has nothing to bind.

  5. Configure. On the Configure step, review the parameters (see Configuration parameters). Passwords left empty with a generated default are generated and sealed by the Manager.

  6. Review and install. On the Install step the Manager validates the plan and shows the installation order; when it says "The plan is valid. Ready to install.", choose Install. A highly available mode is installed only when its HA checks pass.

  7. Verify. The operation ends when the health checks of every instance pass (see Health checks); the service then shows as running in Services. Open the service and choose Run the smoke test in the Checks card: Scans the EICAR test file (must match navin_eicar_test_file), then a clean file (must match nothing).

High availability​

Clusterreplicas (replication)
High availabilityexternal (external)
Failoverclient side (client)
Replicationnone (none)
Quorumnone (none)
Discoverystatic (static)
Entry pointclient discovery (client-discovery)
Official documentationhttps://virustotal.github.io/yara-x/
Referenceshttps://virustotal.github.io/yara-x/docs/
Peer TLS parametertls_enabled
Peer authenticationClients authenticate to every worker with the Bearer key; workers have no peer.

Topology per mode​

ModesHighest catalog levelDistributionQuorum componentFault domainsDescription
standalonestandalone (standalone)single (single)-1One worker, no fault tolerance (uploads are refused in enforce mode while it is down).
replicatedha (ha)active-active (active-active)-2Two or more stateless workers with the same rule set; the platform receives every worker and fails over to the next one.

Notes​

  • Every worker keeps its own copy of the rules: run update_rules on all workers (target all) so that they serve the same version.

Configuration parameters​

Network​

ParameterTypeDefaultAllowed valuesRequiredSecretRestartDescription
Worker port (port)port8475-nonoyesHTTPS port of the worker (/v1/scan, /v1/rules/reload, /readyz, /metrics).

Security​

ParameterTypeDefaultAllowed valuesRequiredSecretRestartDescription
TLS (tls_enabled)booltrue-nonoyesServe the worker over HTTPS with a certificate of the manager CA (required in production).
API key (api_key)passwordgenerated-noyesnoBearer key of the worker clients (EAI_YARAX_API_KEY of the platform).

Rules​

ParameterTypeDefaultAllowed valuesRequiredSecretRestartDescription
Rule repository (rules_repository_url)url{{ mirror.url }}/yara-rules-nononoInternal HTTPS repository serving navin-rules-<version>.tar.gz, checked with the manager CA (update_rules).

Scan limits​

ParameterTypeDefaultAllowed valuesRequiredSecretRestartDescription
Largest file (max_file_size_mb)int100min 1, max 2000, MBnononoBody limit of /v1/scan (413 above); keep it at least the platform limit EAI_FILE_SCAN_MAX_BYTES.
Scan timeout (scan_timeout_s)int60min 1, max 600, snononoTimeout of the YARA-X scanner for one file (500 scan_timeout beyond).

Endpoints​

EndpointSchemeComponentPortPathTLS parameterBinding parametersBinding secretsProvisioning command
apihttpworker8475 (port)-tls_enabled-api_key-

Commands​

CommandComponentTargetDescription
Rule set status (rules_status)workerevery hostActive and previous rule sets of each worker and its readiness.
Update the rules (update_rules)workerevery hostDownloads navin-rules-<version>.tar.gz from the internal repository, checks its sha256, compiles it in a staging directory, switches atomically and reloads each worker. Any failure keeps the active rules.
Roll back the rules (rollback_rules)workerevery hostSwitches each worker back to its previous rule set and reloads it. (asks for confirmation)
Worker logs (logs)workerchosen hostLast lines of the worker journal.

Command parameters​

CommandParameterTypeDefaultRequiredDescription
update_rulesVersion (version)string-yesVersion of the rule set (file navin-rules-<version>.tar.gz of the repository).
update_rulesExpected sha256 (sha256)string-yesSHA-256 of the archive published with the rule set; the download is refused when it differs.

Health checks​

Liveness (per instance)​

ComponentCheckDetails
workerHTTP {{ 'https' if config.tls_enabled else 'http' }}://{{ host.ip or '127.0.0.1' }}:{{ config.port }}/healthzExpected 200; 30 retries; interval 2 s; timeout 5 s

Readiness (service check)​

CheckDetails
HTTP {{ 'https' if config.tls_enabled else 'http' }}://{{ host.ip or '127.0.0.1' }}:{{ config.port }}/readyzExpected 200; Expected "status": "ready"; 10 retries; interval 3 s; timeout 10 s

Smoke test​

Scans the EICAR test file (must match navin_eicar_test_file), then a clean file (must match nothing). (worker: eicar_matched, clean_nothing)

Preflight checks​

CheckTypeMeaningSeverityComponents
memorymemory_mb {"min": 1024}at least 1024 MB of memorywarningevery component
port_freeport_free {"param": "port"}port 8475 free on the hostblockingevery component

Uninstall​

Paths removed when the data is purged: {{ paths.data }}, {{ paths.log }}.

  • Worker metrics: {{ 'https' if config.tls_enabled else 'http' }}://{{ host.fqdn }}:{{ config.port }}/metrics

Upstream documentation​