Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x/vulndb: potential Go vuln in github.com/etcd-io/etcd: CVE-2022-34038 #2016

Closed
GoVulnBot opened this issue Aug 22, 2023 · 5 comments
Closed
Assignees
Labels
excluded: NOT_A_VULNERABILITY This is not a vulnerability.

Comments

@GoVulnBot
Copy link

CVE-2022-34038 references github.com/etcd-io/etcd, which may be a Go module.

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

References:

Cross references:

See doc/triage.md for instructions on how to triage this report.

modules:
    - module: github.com/etcd-io/etcd
      vulnerable_at: 2.3.8+incompatible
      packages:
        - package: n/a
description: |-
    Etcd v3.5.4 allows remote attackers to cause a denial of service via function
    PageWriter.write in pagewriter.go
cves:
    - CVE-2022-34038
references:
    - fix: https://github.com/etcd-io/etcd/pull/14022
    - fix: https://github.com/etcd-io/etcd/pull/14452

@maceonthompson maceonthompson self-assigned this Aug 23, 2023
@maceonthompson maceonthompson added the excluded: EFFECTIVELY_PRIVATE This vulnerability exists in a package can be imported, but isn't meant to be outside that module. label Aug 23, 2023
@gopherbot
Copy link
Contributor

Change https://go.dev/cl/522555 mentions this issue: data/excluded: batch add 11 excluded reports

@ahrtr
Copy link

ahrtr commented Aug 29, 2023

The only way to trigger this CVE is to dynamically change an unexported variable's value at runtime.

I am curious how can it be done?

@serathius
Copy link

This is some big misunderstanding. Yes, there is a function in etcd util packages called NewpageWriter. Yes, you can pass pageBytes negative argument, it will cause this function to panic. However, this argument is set based on const, not user configurable, neigher remotely.

There is no way to exploit this. Also etcd-io/etcd#14452 is not a proper fix, it adds validation that will also panic, but will provide a nice error.

@maceonthompson maceonthompson added excluded: NOT_A_VULNERABILITY This is not a vulnerability. and removed excluded: EFFECTIVELY_PRIVATE This vulnerability exists in a package can be imported, but isn't meant to be outside that module. labels Aug 30, 2023
@maceonthompson
Copy link

Thanks for pointing this out! It would have been excluded from the database either way, but we'll update the reason to be "not a vuln"

@gopherbot
Copy link
Contributor

Change https://go.dev/cl/524456 mentions this issue: data/excluded: update GO-2023-2016.yaml

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
excluded: NOT_A_VULNERABILITY This is not a vulnerability.
Projects
None yet
Development

No branches or pull requests

5 participants