LiveActive security incident?Get immediate response
CVE Record

CVE-2022-31023: Dev error stack trace leaking into prod in Play Framework

Play Framework is a web framework for Java and Scala. Verions prior to 2.8.16 are vulnerable to generation of error messages containing sensitive information. Play Framework, when run in dev mode, shows verbose errors for easy debugging, including an exception stack trace. Play does this by configuring its `DefaultHttpErrorHandler` to do so based on the application mode. In its Scala API Play also provides a static object `DefaultHttpErrorHandler` that is configured to always show verbose errors. This is used as a default value in some Play APIs, so it is possible to inadvertently use this version in production. It is also possible to improperly configure the `DefaultHttpErrorHandler` object instance as the injected error handler. Both of these situations could result in verbose errors displaying to users in a production application, which could expose sensitive information from the application. In particular, the constructor for `CORSFilter` and `apply` method for `CORSActionBuilder` use the static object `DefaultHttpErrorHandler` as a default value. This is patched in Play Framework 2.8.16. The `DefaultHttpErrorHandler` object has been changed to use the prod-mode behavior, and `DevHttpErrorHandler` has been introduced for the dev-mode behavior. A workaround is available. When constructing a `CORSFilter` or `CORSActionBuilder`, ensure that a properly-configured error handler is passed. Generally this should be done by using the `HttpErrorHandler` instance provided through dependency injection or through Play's `BuiltInComponents`. Ensure that the application is not using the `DefaultHttpErrorHandler` static object in any code that may be run in production.

MediumCVSS 5.9Not KEV-listedUpdated
Glexia's TakeAutomated analysismoderate

Security readout for executives and security teams

Plain-English summary

Some Play Framework applications could accidentally show developer-style error pages in production. Those pages may reveal stack traces and sensitive application details to unauthenticated users. This is mainly a confidentiality issue, not a direct takeover vulnerability, but exposed internals can materially help later attacks.

Executive priority

Treat this as a near-term hygiene fix for internet-facing Play applications. It is not described as actively exploited, but leaked stack traces can expose internals, secrets, file paths, or framework details that reduce attacker effort in later stages.

Technical view

In Play Framework before 2.8.16, the Scala DefaultHttpErrorHandler static object always used verbose dev behavior. APIs including CORSFilter and CORSActionBuilder could default to that object, or teams could wire it as the injected handler, causing sensitive error details in production. Version 2.8.16 changes DefaultHttpErrorHandler to prod behavior and adds DevHttpErrorHandler.

Likely exposure

Exposure is most likely in Java or Scala web applications using Play Framework earlier than 2.8.16, especially where CORSFilter, CORSActionBuilder, or custom error handler wiring is present in production code.

Exploitation context

The provided sources do not report active exploitation, and the CVE is not listed as KEV. Exploitation depends on a reachable affected application and an error path that triggers verbose handling. CVSS rates attack complexity high but confidentiality impact high.

Researcher notes

Focus review on Scala API defaults and error handler wiring. The advisory names CORSFilter and CORSActionBuilder as affected API paths. Evidence supports sensitive information disclosure through verbose errors, not integrity or availability impact.

Mitigation direction

  • Upgrade Play Framework to 2.8.16 or later.
  • Pass a properly configured HttpErrorHandler when constructing CORSFilter or CORSActionBuilder.
  • Use dependency injection or BuiltInComponents for production error handling.
  • Remove production use of the DefaultHttpErrorHandler static object.
  • Check vendor guidance before applying any nonstandard workaround.

Validation and detection

  • Inventory Play Framework applications running versions earlier than 2.8.16.
  • Review production code for DefaultHttpErrorHandler static object usage.
  • Check CORSFilter and CORSActionBuilder construction for explicit injected HttpErrorHandler.
  • Confirm production-like error handling suppresses stack traces during controlled QA.
  • Verify dependency records show Play Framework 2.8.16 or later after remediation.
Prepared
Confidence
high
Sources
5

Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.

Potential ATT&CK relevance

Conservative CVE-to-ATT&CK context

These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.

ATT&CK lookup starting points

Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.

cwe · medium confidence lookup

CWE-209: Information exposure and cloud metadata lookup

Information exposure and SSRF weaknesses can make discovery, cloud metadata, and credential material review relevant. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.

Open ATT&CK lookup
cve · low confidence lookup

CVE-2022-31023 mapping review

Open the CVE-to-ATT&CK bridge for reviewed, inferred, or future official mappings tied to this CVE.

Open ATT&CK lookup
Vulnerability profileCVE Program record
Severity
Medium
CVSS
5.9 (3.1)
Known Exploited
No
Published

Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N

Official CVE source material

CNA and ADP enrichment extracted from CVE v5

These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.

1CVSS vectors
0Timeline events
0ADP providers
4Source links

CVSS vector scores

1 official score

We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.

ScoreVersionSeverityVectorExploitImpactSource
5.9CVSS 3.1MediumCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N2.23.6Primary CVE score

Vulnerability scoring details

Base CVSS 3.1 score

5.9Medium
CVSS 3.1 vector shape for CVE-2022-31023Attack VectorAttack ComplexityPrivileges RequiredUser InteractionScopeConfidentiality ImpactIntegrity ImpactAvailability Impact

Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N

Attack Vector
NetworkAdjacentLocalPhysical
Attack Complexity
LowHigh
Privileges Required
NoneLowHigh
User Interaction
NoneRequired
Scope
ChangedUnchanged
Confidentiality Impact
HighLowNone
Integrity Impact
HighLowNone
Availability Impact
HighLowNone
Affected products

Products and packages named in the record

VendorProductVersion / packageStatus
playframeworkplayframework< 2.8.16Listed
Weakness

CWE details

CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.

CWE-209 · source CWE mapping

Generation of Error Message Containing Sensitive Information

Generation of Error Message Containing Sensitive Information represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.