Skip to content

oauth filter calls continueDecoding() from within decodeHeaders()

High
mattklein123 published GHSA-rww6-8h7g-8jf6 Jun 9, 2022

Package

Envoy (Envoy)

Affected versions

< 1.22.1

Patched versions

1.22.1

Description

Attack type

Remote

Impact

Denial of Service (crash)

Affected component(s)

OAuth.

Attack vector(s)

Remote.

Discoverer(s)/Credits

Identified by Raul Gutierrez Segales rgs@pinterest.com while investigating GHSA-h45c-2f94-prxh, originally reported by Weiqiu Wen ff800u@gmail.com

References

See also GHSA-h45c-2f94-prxh

Description (brief; included in CVE)

The OAuth filter would try to invoke the remaining filters in the chain after emitting a local response, which triggers an ASSERT() in newer versions and corrupts memory on earlier versions.

Example exploit or proof-of-concept

The general authentication flow in the oauth filter triggers this condition, so should be exploitable.

Description (full; not included in CVE but will be published on GitHub later and linked)

continueDecoding() shouldn’t ever be called from filters after a local reply has been sent.

Mitigation

NA.

Detection

Crashes with possible unrelated stack traces after successful oauth flow metrics are emitted.

Severity

High
7.5
/ 10

CVSS base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

CVE ID

CVE-2022-29228