CVE-2024-36112: Nautobot Remote Code Execution Vulnerability

MODERATE
Advisory Identifier: GHSA-qmjf-wc2h-6x3q
CVSS 6.3
CWE-280
Published
Advisory Summary

CVE-2024-36112 is a MODERATE (CVSS 6.3) remote code execution vulnerability (CWE-280: Improper Handling of Insufficient Permissions or Privileges) affecting Nautobot libraries in the PyPI ecosystem. The issue involves nautobot dynamic-group-members doesn't enforce permission restrictions on member objects. Remediation is available by upgrading affected packages to version 1.6.23, 2.2.5.

CVE-2024-36112 at a Glance

CVE Identifier CVE-2024-36112
GHSA Identifier GHSA-qmjf-wc2h-6x3q
Severity MODERATE
CVSS v3.1 Base Score 6.3
CWE Classification CWE-280: Improper Handling of Insufficient Permissions or Privileges
Affected Product Nautobot
Package Ecosystem PyPI
Published Date
Last Updated

Security Impact

CVSS: 6.3

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

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

How to Fix CVE-2024-36112

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

nautobot fixed: 1.6.23
pip install nautobot>=1.6.23
nautobot fixed: 2.2.5
pip install nautobot>=2.2.5
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 nautobot

How to Check if You Are Affected

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

pip show nautobot

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

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

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-280: Improper Handling of Insufficient Permissions or Privileges, where the product does not handle or incorrectly handles when it has insufficient privileges to access resources or functionality as specified by their permissions. this may cause it to follow unexpected code paths that may leave the product in an invalid state. In Nautobot, 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 _What kind of vulnerability is it? Who is impacted?_ A user with permissions to view Dynamic Group records (`extras.view_dynamicgroup` permission) can use the Dynamic Group detail UI view (`/extras/dynamic-groups/<uuid>/`) and/or the members REST API view (`/api/extras/dynamic-groups/<uuid>/members/`) to list the objects that are members of a given Dynamic Group. In versions of Nautobot between 1.3.0 (where the Dynamic Groups feature was added) and 1.6.22 inclusive, and 2.0.0 through 2.2.4 inclusive, Nautobot fails to restrict these listings based on the member object permissions - for example a Dynamic Group of Device objects will list all Devices that it contains, regardless of the user's `dcim.view_device` permissions or lack thereof. ### Patches _Has the problem been patched? What versions should users upgrade to?_ Fixed in Nautobot 1.6.23 and 2.2.5. ### Workarounds _Is there a way for users to fix or remediate the vulnerability without upgrading?_ This vulnerability can be partially mitigated by removing `extras.view_dynamicgroup` permission from users; a full fix will require upgrading. ### References _Are there any links users can visit to find out more?_ - https://github.com/nautobot/nautobot/pull/5757 - https://github.com/nautobot/nautobot/pull/5762

CVE-2024-36112 Affected Nautobot Versions

2 component(s)
Fixed Versions:
1.6.232.2.5
Product / Package Ecosystem Affected Versions Fixed Version
nautobot
PyPI
≥ 1.3.0
< 1.6.23
1.6.23
nautobot
PyPI
≥ 2.0.0
< 2.2.5
2.2.5

References

Frequently Asked Questions

What is CVE-2024-36112?
CVE-2024-36112 is a security vulnerability in Nautobot involving Nautobot dynamic-group-members doesn't enforce permission restrictions on member objects under CWE-280: Improper Handling of Insufficient Permissions or Privileges.
Which Nautobot versions are affected?
Affected versions include releases prior to 1.6.23, 2.2.5 across affected packages: nautobot.
What version fixes CVE-2024-36112?
Upgrading to 1.6.23, 2.2.5 (or the latest patched release for your respective branch) resolves the vulnerability.
Is nautobot affected?
Yes, nautobot is affected in releases prior to 1.6.23, 2.2.5. Upgrade your dependency to 1.6.23, 2.2.5 or later.
What is the CVSS score of CVE-2024-36112?
CVE-2024-36112 has a CVSS v3.1 base score of 6.3 (MODERATE) with vector string CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:N/A:N.
What CWE is associated with CVE-2024-36112?
CVE-2024-36112 is classified under CWE-280: Improper Handling of Insufficient Permissions or Privileges (The product does not handle or incorrectly handles when it has insufficient privileges to access resources or functionality as specified by their permissions. This may cause it to follow unexpected code paths that may leave the product in an invalid state.).
How can I check PyPI dependencies for CVE-2024-36112?
Run the dependency tree command: 'pip show nautobot'. 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-qmjf-wc2h-6x3q",
  "modified" : "2025-01-21T18:30:41Z",
  "published" : "2024-05-29T18:40:56Z",
  "aliases" : [ "CVE-2024-36112" ],
  "summary" : "Nautobot dynamic-group-members doesn't enforce permission restrictions on member objects",
  "details" : "### Impact\n_What kind of vulnerability is it? Who is impacted?_\n\nA user with permissions to view Dynamic Group records (`extras.view_dynamicgroup` permission) can use the Dynamic Group detail UI view (`/extras/dynamic-groups/<uuid>/`) and/or the members REST API view (`/api/extras/dynamic-groups/<uuid>/members/`) to list the objects that are members of a given Dynamic Group. \n\nIn versions of Nautobot between 1.3.0 (where the Dynamic Groups feature was added) and 1.6.22 inclusive, and 2.0.0 through 2.2.4 inclusive, Nautobot fails to restrict these listings based on the member object permissions - for example a Dynamic Group of Device objects will list all Devices that it contains, regardless of the user's `dcim.view_device` permissions or lack thereof.\n\n### Patches\n_Has the problem been patched? What versions should users upgrade to?_\n\nFixed in Nautobot 1.6.23 and 2.2.5.\n\n### Workarounds\n_Is there a way for users to fix or remediate the vulnerability without upgrading?_\n\nThis vulnerability can be partially mitigated by removing `extras.view_dynamicgroup` permission from users; a full fix will require upgrading.\n\n### References\n_Are there any links users can visit to find out more?_\n\n- https://github.com/nautobot/nautobot/pull/5757\n- https://github.com/nautobot/nautobot/pull/5762",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:N/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "nautobot"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "1.3.0"
      }, {
        "fixed" : "1.6.23"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "nautobot"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.0.0"
      }, {
        "fixed" : "2.2.5"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/nautobot/nautobot/security/advisories/GHSA-qmjf-wc2h-6x3q"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2024-36112"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/nautobot/nautobot/pull/5757"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/nautobot/nautobot/pull/5762"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/nautobot/nautobot/commit/3a63aa1327f943b2ac8452757ea2e4d403387ad6"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/nautobot/nautobot/commit/4d1ff2abe2775b0a6fb16e6d1d503a78226a6f8e"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/nautobot/nautobot"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/pypa/advisory-database/tree/main/vulns/nautobot/PYSEC-2024-166.yaml"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-280" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-05-29T18:40:56Z",
    "nvd_published_at" : "2024-05-28T23:15:17Z"
  }
}