CVE-2021-31856 in layer5 meshery

LogPulse has a published detection rule for this CVE: it raises a notable when someone tries to exploit it.

What the vulnerability is

A SQL Injection vulnerability in the REST API in Layer5 Meshery 0.5.2 allows an attacker to execute arbitrary SQL commands via the /experimental/patternfiles endpoint (order parameter in GetMesheryPatterns in models/meshery_pattern_persister.go).

Affected software: layer5 meshery

Scores

What LogPulse has for it

How to mitigate it

Upgrade Meshery past 0.5.2

Patch or upgrade. Meshery 0.5.2 puts the order parameter of the patternfiles API into SQL unescaped. Later releases validate the sort column.

Applies to: Layer5 Meshery 0.5.2 and earlier.

  1. Check the Meshery version with mesheryctl version.
  2. Upgrade to a current Meshery release with mesheryctl system update, or pull the latest images and restart.
  3. Keep the Meshery API reachable only from the admin network.

Sources:

Source data: NIST NVD, CISA KEV and FIRST EPSS. LogPulse processes new CVEs every hour.

We build every detection with great care, but no two environments are the same. Log sources, parsing and configuration differ, so test a detection in your own environment before you rely on it.

Start free with LogPulse