Skip to content

CVE-2024-37298 Potential memory exhaustion attack due to sparse slice deserialization

HighCVSS 7.5 EPSS 1.1%
Published
Updated
Exploit status
No public exploit known
CISA SSVC
Proof of concept public · automatable: yes · technical impact: partial
Technology
UbuntuDebian

Description

gorilla/schema converts structs to and from form values. Prior to version 1.4.1 Running schema.Decoder.Decode() on a struct that has a field of type []struct{...} opens it up to malicious attacks regarding memory allocations, taking advantage of the sparse slice functionality. Any use of schema.Decoder.Decode() on a struct with arrays of other structs could be vulnerable to this memory exhaustion vulnerability. Version 1.4.1 contains a patch for the issue.

Upgrade path

9 packages: 4 fixed, 4 with no fix yet.

PackageAffectedFixed inStatus
debian/golang-github-gorilla-schema(Debian 12) = 1.2.0-2; = 1.4.1-1; All versions No fix listed No fix yet
ubuntu/golang-github-gorilla-schema(Ubuntu 24.04) All versions No fix listed No fix yet
ubuntu/golang-github-gorilla-schema(Ubuntu 26.04) All versions No fix listed No fix yet
ubuntu/golang-github-gorilla-schema(Ubuntu 26.10) All versions No fix listed No fix yet
debian/golang-github-gorilla-schema(Debian 13) < 1.4.1-1 1.4.1-1 Fixed
debian/golang-github-gorilla-schema(Debian 14) < 1.4.1-1 1.4.1-1 Fixed
gorilla github.com/gorilla/schema(Go) < 1.4.1 1.4.1 Fixed
gorillatoolkit schema < 1.4.1 1.4.1 Fixed
gorilla github.com/gorilla/schema = < 1.4.1 No fix listed Versions listed

Affected products

ProductAffected versionsFixed in
gorilla github.com/gorilla/schema(Go) < 1.4.1 1.4.1
debian/golang-github-gorilla-schema(Debian:12) All versions No fix listed
debian/golang-github-gorilla-schema(Debian:12) = 1.2.0-2 No fix listed
debian/golang-github-gorilla-schema(Debian:12) = 1.4.1-1 No fix listed
debian/golang-github-gorilla-schema(Debian:13) < 1.4.1-1 1.4.1-1
debian/golang-github-gorilla-schema(Debian:14) < 1.4.1-1 1.4.1-1
gorilla github.com/gorilla/schema = < 1.4.1 No fix listed
gorillatoolkit schema < 1.4.1 1.4.1
ubuntu/golang-github-gorilla-schema(Ubuntu:24.04) All versions No fix listed
ubuntu/golang-github-gorilla-schema(Ubuntu:26.04) All versions No fix listed
ubuntu/golang-github-gorilla-schema(Ubuntu:26.10) All versions No fix listed

References