CVE-2022-34038: Go.etcd.io/etcd/v3 Denial of Service Vulnerability

HIGH
Advisory Identifier: GHSA-65rp-cv85-263x
CVSS 7.5
CWE-787
Published
Advisory Summary

CVE-2022-34038 is a HIGH (CVSS 7.5) denial of service vulnerability (CWE-787: Out-of-bounds Write) affecting Go.etcd.io/etcd/v3 libraries in the Go ecosystem. The issue involves etcd denial of service vulnerability. Remediation is available by upgrading affected packages to version 3.5.5.

CVE-2022-34038 at a Glance

CVE Identifier CVE-2022-34038
GHSA Identifier GHSA-65rp-cv85-263x
Severity HIGH
CVSS v3.1 Base Score 7.5
CWE Classification CWE-787: Out-of-bounds Write
Affected Product Go.etcd.io/etcd/v3
Package Ecosystem Go
Published Date
Last Updated

Security Impact

CVSS: 7.5

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

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

How to Fix CVE-2022-34038

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

go.etcd.io/etcd/v3 fixed: 3.5.5
Upgrade go.etcd.io/etcd/v3 to 3.5.5
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 go.etcd.io/etcd/v3

How to Check if You Are Affected

To determine whether your application is affected by CVE-2022-34038, inspect your project dependencies for Go.etcd.io/etcd/v3:

inspect dependencies for go.etcd.io/etcd/v3

Analyze the terminal output to locate any version of Go.etcd.io/etcd/v3 in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 3.5.5), 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-787: Out-of-bounds Write, where the product writes data past the end, or before the beginning, of the intended buffer. In Go.etcd.io/etcd/v3, 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

Etcd v3.5.4 allows remote attackers to cause a denial of service via function PageWriter.write in pagewriter.go

CVE-2022-34038 Affected Go.etcd.io/etcd/v3 Versions

1 component(s)
Fixed Versions:
3.5.5
Product / Package Ecosystem Affected Versions Fixed Version
go.etcd.io/etcd/v3
Go
< 3.5.5
3.5.5

References

Frequently Asked Questions

What is CVE-2022-34038?
CVE-2022-34038 is a security vulnerability in Go.etcd.io/etcd/v3 involving etcd denial of service vulnerability under CWE-787: Out-of-bounds Write.
Which Go.etcd.io/etcd/v3 versions are affected?
Affected versions include releases prior to 3.5.5 across affected packages: go.etcd.io/etcd/v3.
What version fixes CVE-2022-34038?
Upgrading to 3.5.5 (or the latest patched release for your respective branch) resolves the vulnerability.
Is go.etcd.io/etcd/v3 affected?
Yes, go.etcd.io/etcd/v3 is affected in releases prior to 3.5.5. Upgrade your dependency to 3.5.5 or later.
What is the CVSS score of CVE-2022-34038?
CVE-2022-34038 has a CVSS v3.1 base score of 7.5 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H.
What CWE is associated with CVE-2022-34038?
CVE-2022-34038 is classified under CWE-787: Out-of-bounds Write (The product writes data past the end, or before the beginning, of the intended buffer.).
How can I check Go dependencies for CVE-2022-34038?
Run the dependency tree command: 'inspect dependencies for go.etcd.io/etcd/v3'. 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-65rp-cv85-263x",
  "modified" : "2024-03-21T17:58:17Z",
  "published" : "2023-08-22T21:30:26Z",
  "withdrawn" : "2023-10-09T21:46:43Z",
  "aliases" : [ "CVE-2022-34038" ],
  "summary" : "etcd denial of service vulnerability",
  "details" : "Etcd v3.5.4 allows remote attackers to cause a denial of service via function PageWriter.write in pagewriter.go",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "go.etcd.io/etcd/v3"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "3.5.5"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2022-34038"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/golang/vulndb/issues/2016#issuecomment-1698677762"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/etcd-io/etcd/pull/14022"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/etcd-io/etcd/pull/14452"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/etcd-io/etcd/commit/5a315ef88fbfa454e02d27b0b8acb4f89457cd90"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/etcd-io/etcd"
  }, {
    "type" : "WEB",
    "url" : "https://go-review.googlesource.com/c/vulndb/+/524456"
  }, {
    "type" : "WEB",
    "url" : "https://go-review.googlesource.com/c/vulndb/+/524456/2/data/excluded/GO-2023-2016.yaml"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-787" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2023-08-23T13:25:22Z",
    "nvd_published_at" : "2023-08-22T19:16:23Z"
  }
}