Getkin kin-openapi
kin-openapi openai3filter: nil-pointer panic in ConvertErrors on malformed multipart/form-data body enables unauthenticated DoS
kin-openapi is a Go project for handling OpenAPI files. From 0.10.0 until 0.141.0, openapi3filter.convertParseError in openapi3filter/validation_error_encoder.go dereferences e.Parameter.In without checking whether e.Parameter is nil. A malformed non-string scalar field in a multipart/form-data request body produces a nested ParseError with a nil RequestError.Parameter, and applications that render the validation error through openapi3filter.ConvertErrors or ValidationErrorEncoder panic. An unauthenticated client can repeatedly send such requests to deny service when the application lacks a recovery boundary. JSON request bodies and applications that do not use these error-rendering helpers are not affected. This issue is fixed in version 0.141.0.
Affected versions and mitigation
From the CVE record and the vendor's references.Affected
- >= 0.10.0, < 0.141.0
Fixed in 0.141.0
Mitigation
Upgrade kin-openapi to 0.141.0 or later.
References
- Vendor advisory github.com/getkin/kin-openapi/security/advisor…
- Patch github.com/getkin/kin-openapi/commit/1d0a337c9…
- Release notes github.com/getkin/kin-openapi/releases/tag/v0.…
Timeline
Days relative to CVE publicationNo public PoC found yet; not in CISA KEV.
PoC repositories
Found on GitHub.No PoC repositories found yet.