CVE-2022-22936: Salt Authentication Bypass Vulnerability

HIGH
Advisory Identifier: GHSA-5r3f-3m3j-wcj2
CVSS 8.8
CWE-294
Published
Advisory Summary

CVE-2022-22936 is a HIGH (CVSS 8.8) authentication bypass vulnerability (CWE-294: Authentication Bypass by Capture-replay) affecting Salt libraries in the PyPI ecosystem. The issue involves saltstack salt authentication bypass by capture-replay. Remediation is available by upgrading affected packages to version 3002.8, 3003.4, 3004.1.

CVE-2022-22936 at a Glance

CVE Identifier CVE-2022-22936
GHSA Identifier GHSA-5r3f-3m3j-wcj2
Severity HIGH
CVSS v3.1 Base Score 8.8
CWE Classification CWE-294: Authentication Bypass by Capture-replay
Affected Product Salt
Package Ecosystem PyPI
Published Date
Last Updated

Security Impact

CVSS: 8.8

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:A/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H).

Attack Vector Adjacent (AV:A)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity High (I:H)
Availability High (A:H)

How to Fix CVE-2022-22936

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

salt fixed: 3002.8
pip install salt>=3002.8
salt fixed: 3003.4
pip install salt>=3003.4
salt fixed: 3004.1
pip install salt>=3004.1
Verify Direct and Transitive Dependencies

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

pip show salt

How to Check if You Are Affected

To determine whether your Python environment is affected by CVE-2022-22936, inspect your installed packages using pip:

pip show salt

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

Note: The pip show salt command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-294: Authentication Bypass by Capture-replay, where a capture-replay flaw exists when the design of the product makes it possible for a malicious user to sniff network traffic and bypass authentication by replaying it to the server in question to the same effect as the original message (or with minor changes). In Salt, 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

An issue was discovered in SaltStack Salt in versions before 3002.8, 3003.4, 3004.1. Job publishes and file server replies are susceptible to replay attacks, which can result in an attacker replaying job publishes causing minions to run old jobs. File server replies can also be re-played. A sufficient craft attacker could gain root access on minion under certain scenarios.

CVE-2022-22936 Affected Salt Versions

3 component(s)
Fixed Versions:
3002.83003.43004.1
Product / Package Ecosystem Affected Versions Fixed Version
salt
PyPI
< 3002.8
3002.8
salt
PyPI
≥ 3003
< 3003.4
3003.4
salt
PyPI
≥ 3004
< 3004.1
3004.1

References

Frequently Asked Questions

What is CVE-2022-22936?
CVE-2022-22936 is a security vulnerability in Salt involving SaltStack Salt Authentication Bypass by Capture-replay under CWE-294: Authentication Bypass by Capture-replay.
Which Salt versions are affected?
Affected versions include releases prior to 3002.8, 3003.4, 3004.1 across affected packages: salt.
What version fixes CVE-2022-22936?
Upgrading to 3002.8, 3003.4, 3004.1 (or the latest patched release for your respective branch) resolves the vulnerability.
Is salt affected?
Yes, salt is affected in releases prior to 3002.8, 3003.4, 3004.1. Upgrade your dependency to 3002.8, 3003.4, 3004.1 or later.
What is the CVSS score of CVE-2022-22936?
CVE-2022-22936 has a CVSS v3.1 base score of 8.8 (HIGH) with vector string CVSS:3.1/AV:A/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H.
What CWE is associated with CVE-2022-22936?
CVE-2022-22936 is classified under CWE-294: Authentication Bypass by Capture-replay (A capture-replay flaw exists when the design of the product makes it possible for a malicious user to sniff network traffic and bypass authentication by replaying it to the server in question to the same effect as the original message (or with minor changes).).
How can I check PyPI dependencies for CVE-2022-22936?
Run the dependency tree command: 'pip show salt'. 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-5r3f-3m3j-wcj2",
  "modified" : "2024-10-22T14:54:47Z",
  "published" : "2022-03-30T00:00:20Z",
  "aliases" : [ "CVE-2022-22936" ],
  "summary" : "SaltStack Salt Authentication Bypass by Capture-replay",
  "details" : "An issue was discovered in SaltStack Salt in versions before 3002.8, 3003.4, 3004.1. Job publishes and file server replies are susceptible to replay attacks, which can result in an attacker replaying job publishes causing minions to run old jobs. File server replies can also be re-played. A sufficient craft attacker could gain root access on minion under certain scenarios.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:A/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "salt"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "3002.8"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "salt"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "3003"
      }, {
        "fixed" : "3003.4"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "salt"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "3004"
      }, {
        "fixed" : "3004.1"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2022-22936"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/pypa/advisory-database/tree/main/vulns/salt/PYSEC-2022-173.yaml"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/saltstack/salt"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/saltstack/salt/blob/8f9405cf8e6f7d7776d5000841c886dec6d96250/doc/topics/releases/3002.8.rst#L31"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/saltstack/salt/blob/8f9405cf8e6f7d7776d5000841c886dec6d96250/doc/topics/releases/3003.4.rst#L32"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/saltstack/salt/blob/8f9405cf8e6f7d7776d5000841c886dec6d96250/doc/topics/releases/3004.1.rst#L30"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/saltstack/salt/releases"
  }, {
    "type" : "WEB",
    "url" : "https://repo.saltproject.io"
  }, {
    "type" : "WEB",
    "url" : "https://saltproject.io/security_announcements/salt-security-advisory-release"
  }, {
    "type" : "WEB",
    "url" : "https://security.gentoo.org/glsa/202310-22"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-294" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-04-22T21:14:00Z",
    "nvd_published_at" : "2022-03-29T17:15:00Z"
  }
}