GO-2026-5048

Source
https://pkg.go.dev/vuln/GO-2026-5048
Import Source
https://vuln.go.dev/ID/GO-2026-5048.json
JSON Data
https://api.osv.dev/v1/vulns/GO-2026-5048
Aliases
Downstream
Published
2026-07-27T16:16:22Z
Modified
2026-07-27T17:00:19.792221728Z
Summary
Denial of service via unbounded map allocations in github.com/iskorotkov/avro/v2 and github.com/hamba/avro/v2
Details

The Avro map decoder accepts attacker-controlled block-element counts from the wire format and grows the destination map without enforcing an upper bound. A producer can declare an arbitrarily large map (in one block, or chunked across many sub-limit blocks) and exhaust process memory until the OOM killer fires.

The fix introduces Config.MaxMapAllocSize with cumulative enforcement across block boundaries. The new limit is opt-in: the field defaults to zero, which preserves the previous unbounded behavior for backward compatibility. Upgrading to v2.33.0 alone does not mitigate the issue; consumers of untrusted Avro data must explicitly set MaxMapAllocSize on their avro.Config.

Database specific
{
    "review_status": "REVIEWED",
    "url": "https://pkg.go.dev/vuln/GO-2026-5048"
}
References
Credits
    • Ivan Korotkov
    • Daniel Błażewicz

Affected packages

Go / github.com/iskorotkov/avro/v2

Package

Name
github.com/iskorotkov/avro/v2
View open source insights on deps.dev
Purl
pkg:golang/github.com/iskorotkov/avro/v2

Affected ranges

Type
SEMVER
Events
Introduced
0Unknown introduced version / All previous versions are affected
Fixed
2.33.0

Ecosystem specific

{
    "imports": [
        {
            "path": "github.com/iskorotkov/avro/v2"
        }
    ]
}

Database specific

source
"https://vuln.go.dev/ID/GO-2026-5048.json"

Go / github.com/hamba/avro/v2

Package

Name
github.com/hamba/avro/v2
View open source insights on deps.dev
Purl
pkg:golang/github.com/hamba/avro/v2

Affected ranges

Type
SEMVER
Events
Introduced
0Unknown introduced version / All previous versions are affected

Ecosystem specific

{
    "imports": [
        {
            "path": "github.com/hamba/avro/v2"
        }
    ]
}

Database specific

source
"https://vuln.go.dev/ID/GO-2026-5048.json"