GHSA-595p-g7xc-c333: Algolia/algoliasearch magento 2 Algolia Search & Discovery For Vulnerability

MODERATE
CWE-74
Published
Advisory Summary

GHSA-595p-g7xc-c333 is a MODERATE algolia search & discovery for vulnerability (CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection')) affecting Algolia/algoliasearch magento 2 libraries in the Packagist ecosystem. The issue involves algolia search & discovery for magento 2 has untrusted data handling. Remediation is available by upgrading affected packages to version 3.17.2, 3.16.2.

GHSA-595p-g7xc-c333 at a Glance

CVE Identifier N/A
GHSA Identifier GHSA-595p-g7xc-c333
Severity MODERATE
CVSS v3.1 Base Score N/A
CWE Classification CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection')
Affected Product Algolia/algoliasearch magento 2
Package Ecosystem Packagist
Published Date
Last Updated

How to Fix GHSA-595p-g7xc-c333

To remediate this vulnerability, upgrade all affected Algolia/algoliasearch magento 2 dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

algolia/algoliasearch-magento-2 fixed: 3.17.2
Upgrade algolia/algoliasearch-magento-2 to 3.17.2
algolia/algoliasearch-magento-2 fixed: 3.16.2
Upgrade algolia/algoliasearch-magento-2 to 3.16.2
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for algolia/algoliasearch-magento-2

How to Check if You Are Affected

To determine whether your application is affected by GHSA-595p-g7xc-c333, inspect your project dependencies for Algolia/algoliasearch magento 2:

inspect dependencies for algolia/algoliasearch-magento-2

Analyze the terminal output to locate any version of Algolia/algoliasearch magento 2 in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 3.17.2), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection'), where the product constructs all or part of a command, data structure, or record using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify how it is parsed or interpreted when it is sent to a downstream component. In Algolia/algoliasearch magento 2, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Impact Versions of the Algolia Search & Discovery extension for Magento 2 prior to **3.17.2** and **3.16.2** contain a vulnerability where data read from the database was treated as a trusted source during job execution. If an attacker is able to modify records used by the extension’s indexing queue, this could result in **arbitrary PHP code execution** when the affected job is processed. Exploitation requires the ability to write malicious data to the Magento database and for the indexing queue to be enabled. --- ### Patches This vulnerability has been fixed in the following versions: - **3.17.2** - **3.16.2** Merchants should upgrade to a supported patched version immediately. Versions outside the supported maintenance window do **not** receive security updates and remain vulnerable. --- ### Workarounds Upgrading to a patched version is the only recommended remediation. If an immediate upgrade is not possible, the following temporary risk mitigations may reduce exposure: - Disable the Algolia indexing queue to prevent queued jobs from being executed. - Restrict job execution logic to an explicit allowlist of permitted operations. - Review the contents of the `algoliasearch_queue` table for unexpected or unrecognized entries. - If queue archiving is enabled, review historical records in `algoliasearch_queue_archive`. These mitigations are provided as guidance only and do not replace upgrading to a patched version. --- ### References - Algolia Search & Discovery for Magento 2 releases: - [3.16.2](https://github.com/algolia/algoliasearch-magento-2/releases/tag/3.16.2) - [3.17.2](https://github.com/algolia/algoliasearch-magento-2/releases/tag/3.17.2)

GHSA-595p-g7xc-c333 Affected Algolia/algoliasearch magento 2 Versions

2 component(s)
Fixed Versions:
3.17.23.16.2
Product / Package Ecosystem Affected Versions Fixed Version
algolia/algoliasearch-magento-2
Packagist
≥ 3.17.0-beta.1
< 3.17.2
3.17.2
algolia/algoliasearch-magento-2
Packagist
< 3.16.2
3.16.2

References

Frequently Asked Questions

What is GHSA-595p-g7xc-c333?
GHSA-595p-g7xc-c333 is a security vulnerability in Algolia/algoliasearch magento 2 involving Algolia Search & Discovery for Magento 2 Has Untrusted Data Handling under CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection').
Which Algolia/algoliasearch magento 2 versions are affected?
Affected versions include releases prior to 3.17.2, 3.16.2 across affected packages: algolia/algoliasearch-magento-2.
What version fixes GHSA-595p-g7xc-c333?
Upgrading to 3.17.2, 3.16.2 (or the latest patched release for your respective branch) resolves the vulnerability.
Is algolia/algoliasearch-magento-2 affected?
Yes, algolia/algoliasearch-magento-2 is affected in releases prior to 3.17.2, 3.16.2. Upgrade your dependency to 3.17.2, 3.16.2 or later.
What CWE is associated with GHSA-595p-g7xc-c333?
GHSA-595p-g7xc-c333 is classified under CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection') (The product constructs all or part of a command, data structure, or record using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify how it is parsed or interpreted when it is sent to a downstream component.).
How can I check Packagist dependencies for GHSA-595p-g7xc-c333?
Run the dependency tree command: 'inspect dependencies for algolia/algoliasearch-magento-2'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-595p-g7xc-c333",
  "modified" : "2026-01-14T21:46:11Z",
  "published" : "2026-01-14T21:46:11Z",
  "aliases" : [ ],
  "summary" : "Algolia Search & Discovery for Magento 2 Has Untrusted Data Handling",
  "details" : "### Impact\n\nVersions of the Algolia Search & Discovery extension for Magento 2 prior to **3.17.2** and **3.16.2** contain a vulnerability where data read from the database was treated as a trusted source during job execution.\n\nIf an attacker is able to modify records used by the extension’s indexing queue, this could result in **arbitrary PHP code execution** when the affected job is processed.\n\nExploitation requires the ability to write malicious data to the Magento database and for the indexing queue to be enabled.\n\n---\n\n### Patches\n\nThis vulnerability has been fixed in the following versions:\n\n- **3.17.2**\n- **3.16.2**\n\nMerchants should upgrade to a supported patched version immediately.\n\nVersions outside the supported maintenance window do **not** receive security updates and remain vulnerable.\n\n---\n\n### Workarounds\n\nUpgrading to a patched version is the only recommended remediation.\n\nIf an immediate upgrade is not possible, the following temporary risk mitigations may reduce exposure:\n\n- Disable the Algolia indexing queue to prevent queued jobs from being executed.\n- Restrict job execution logic to an explicit allowlist of permitted operations.\n- Review the contents of the `algoliasearch_queue` table for unexpected or unrecognized entries.\n- If queue archiving is enabled, review historical records in `algoliasearch_queue_archive`.\n\nThese mitigations are provided as guidance only and do not replace upgrading to a patched version.\n\n---\n\n### References\n\n- Algolia Search & Discovery for Magento 2 releases:\n  - [3.16.2](https://github.com/algolia/algoliasearch-magento-2/releases/tag/3.16.2)\n  - [3.17.2](https://github.com/algolia/algoliasearch-magento-2/releases/tag/3.17.2)",
  "severity" : [ {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "algolia/algoliasearch-magento-2"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "3.17.0-beta.1"
      }, {
        "fixed" : "3.17.2"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 3.17.1"
    }
  }, {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "algolia/algoliasearch-magento-2"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "3.16.2"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 3.16.1"
    }
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/algolia/algoliasearch-magento-2/security/advisories/GHSA-595p-g7xc-c333"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/algolia/algoliasearch-magento-2"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/algolia/algoliasearch-magento-2/releases/tag/3.16.2"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/algolia/algoliasearch-magento-2/releases/tag/3.17.2"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-74" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-01-14T21:46:11Z",
    "nvd_published_at" : null
  }
}