CVE-2024-48909: Github.com/authzed/spicedb Remote Code Execution Vulnerability

LOW
Advisory Identifier: GHSA-3c32-4hq9-6wgj
CVSS 2.0
CWE-172
Published
Advisory Summary

CVE-2024-48909 is a LOW (CVSS 2.0) remote code execution vulnerability (CWE-172: Encoding Error) affecting Github.com/authzed/spicedb libraries in the Go ecosystem. The issue involves spicedb calls to lookupresources using lookupresources2 with caveats may return context is missing when it is not. Remediation is available by upgrading affected packages to version 1.37.1.

CVE-2024-48909 at a Glance

CVE Identifier CVE-2024-48909
GHSA Identifier GHSA-3c32-4hq9-6wgj
Severity LOW
CVSS v3.1 Base Score 2.0
CWE Classification CWE-172: Encoding Error
Affected Product Github.com/authzed/spicedb
Package Ecosystem Go
Published Date
Last Updated

Security Impact

CVSS: 2.0

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

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

How to Fix CVE-2024-48909

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

github.com/authzed/spicedb fixed: 1.37.1
Upgrade github.com/authzed/spicedb to 1.37.1
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 github.com/authzed/spicedb

How to Check if You Are Affected

To determine whether your application is affected by CVE-2024-48909, inspect your project dependencies for Github.com/authzed/spicedb:

inspect dependencies for github.com/authzed/spicedb

Analyze the terminal output to locate any version of Github.com/authzed/spicedb in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.37.1), 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-172: Encoding Error, where the product does not properly encode or decode the data, resulting in unexpected values. In Github.com/authzed/spicedb, 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 Clients that have enabled `LookupResources2` and have caveats in the evaluation path for their requests can return a permissionship of `CONDITIONAL` with context marked as missing, even then the context was supplied. LookupResources2 is the new default in SpiceDB 1.37.0 and has been opt-in since SpiceDB 1.35.0 ### Patches The bug will be released as part of SpiceDB 1.37.1 ### Workarounds Disable LookupResources2 via the `--enable-experimental-lookup-resources` flag by setting it to `false` ``` --enable-experimental-lookup-resources=false ```

CVE-2024-48909 Affected Github.com/authzed/spicedb Versions

1 component(s)
Fixed Versions:
1.37.1
Product / Package Ecosystem Affected Versions Fixed Version
github.com/authzed/spicedb
Go
≥ 1.35.0
< 1.37.1
1.37.1

References

Frequently Asked Questions

What is CVE-2024-48909?
CVE-2024-48909 is a security vulnerability in Github.com/authzed/spicedb involving SpiceDB calls to LookupResources using LookupResources2 with caveats may return context is missing when it is not under CWE-172: Encoding Error.
Which Github.com/authzed/spicedb versions are affected?
Affected versions include releases prior to 1.37.1 across affected packages: github.com/authzed/spicedb.
What version fixes CVE-2024-48909?
Upgrading to 1.37.1 (or the latest patched release for your respective branch) resolves the vulnerability.
Is github.com/authzed/spicedb affected?
Yes, github.com/authzed/spicedb is affected in releases prior to 1.37.1. Upgrade your dependency to 1.37.1 or later.
What is the CVSS score of CVE-2024-48909?
CVE-2024-48909 has a CVSS v3.1 base score of 2.0 (LOW) with vector string CVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:U/C:L/I:N/A:N.
What CWE is associated with CVE-2024-48909?
CVE-2024-48909 is classified under CWE-172: Encoding Error (The product does not properly encode or decode the data, resulting in unexpected values.).
How can I check Go dependencies for CVE-2024-48909?
Run the dependency tree command: 'inspect dependencies for github.com/authzed/spicedb'. 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-3c32-4hq9-6wgj",
  "modified" : "2024-10-14T22:24:05Z",
  "published" : "2024-10-14T21:04:56Z",
  "aliases" : [ "CVE-2024-48909" ],
  "summary" : "SpiceDB calls to LookupResources using LookupResources2 with caveats may return context is missing when it is not",
  "details" : "### Impact\n\nClients that have enabled `LookupResources2` and have caveats in the evaluation path for their requests can return a permissionship of `CONDITIONAL` with context marked as missing, even then the context was supplied.\n\nLookupResources2 is the new default in SpiceDB 1.37.0 and has been opt-in since SpiceDB 1.35.0\n\n### Patches\nThe bug will be released as part of SpiceDB 1.37.1\n\n### Workarounds\nDisable LookupResources2 via the `--enable-experimental-lookup-resources` flag by setting it to `false`\n\n```\n--enable-experimental-lookup-resources=false\n```\n",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:U/C:L/I:N/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/authzed/spicedb"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "1.35.0"
      }, {
        "fixed" : "1.37.1"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/authzed/spicedb/security/advisories/GHSA-3c32-4hq9-6wgj"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2024-48909"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/authzed/spicedb/commit/2f3cf77a7fcfcb478ef5a480a245842c96ac8853"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/authzed/spicedb"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-172" ],
    "severity" : "LOW",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-10-14T21:04:56Z",
    "nvd_published_at" : "2024-10-14T21:15:12Z"
  }
}