CVE-2022-23633 is a high-severity (CVSS 7.4) Information Exposure vulnerability in actionpack. A fix is available for actionpack — see the affected versions and patch details below.
Exposure of sensitive information in Action Pack
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
CVE-2022-23633 by exploitation likelihood (EPSS) against impact (CVSS). Outside the shaded patch-first corner.
Where this sits among everything scored
Of 385,738 CVEs with a current EPSS score, this one falls in the < 10% band (highlighted). Counts from FIRST.org, log-scaled.
Real-World Exposure
actionpack💎actionpack💎actionpack💎actionpackReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects RubyGems packages — download data is not available via public APIs for these ecosystems.
Description
Impact
Under certain circumstances response bodies will not be closed, for example a bug in a webserver or a bug in a Rack middleware. In the event a response is not notified of a close, ActionDispatch::Executor will not know to reset thread local state for the next request. This can lead to data being leaked to subsequent requests, especially when interacting with ActiveSupport::CurrentAttributes.
Upgrading to the FIXED versions of Rails will ensure mitigation of this issue even in the context of a buggy webserver or middleware implementation.
Patches
This has been fixed in Rails 7.0.2.2, 6.1.4.6, 6.0.4.6, and 5.2.6.2.
Workarounds
Upgrading is highly recommended, but to work around this problem the following middleware can be used:
class GuardedExecutor < ActionDispatch::Executor
def call(env)
ensure_completed!
super
end
private
def ensure_completed!
@executor.new.complete! if @executor.active?
end
end
# Ensure the guard is inserted before ActionDispatch::Executor
Rails.application.configure do
config.middleware.swap ActionDispatch::Executor, GuardedExecutor, executor
end
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 💎RubyGems | actionpack | ≥ 5.0.0.0&&< 5.2.6.2 | 5.2.6.2bundle update actionpack --conservative |
| 💎RubyGems | actionpack | ≥ 6.0.0.0&&< 6.0.4.6 | 6.0.4.6bundle update actionpack --conservative |
| 💎RubyGems | actionpack | ≥ 6.1.0.0&&< 6.1.4.6 | 6.1.4.6bundle update actionpack --conservative |
| 💎RubyGems | actionpack | ≥ 7.0.0.0&&< 7.0.2.2 | 7.0.2.2bundle update actionpack --conservative |
Affected Products
debian linuxdebianrailsrubyonrailsDetection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for actionpack, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update actionpack to 5.2.6.2 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2022-23633 is resolved across your whole dependency graph.
Workarounds
Assume what was exposed is already known: rotate any credential, token or key that the affected component could return, restrict the endpoint to callers that genuinely need it, and strip sensitive fields from responses and error output at the boundary rather than relying on the client not to read them.
Fixing This On Your OS
If you run this on a Linux distribution, patch through your package manager against the distro's own security advisory below — it tracks the exact backported fix for your release, which can ship on a different timeline (and sometimes a different severity) than the upstream project.
A workaround for this problem: ~~~ class GuardedExecutor < ActionDispatch::Executor def call(env) ensure_completed! super end private def ensure_completed! @executor.new.complete! if @executor.active? end end # Ensure the guard is inserted before ActionDispatch::Executor Rails.application.configure do config.middleware.swap ActionDispatch::Executor, GuardedExecutor, executor end ~~~Source: Red Hat security advisory for CVE-2022-23633 (CC BY 4.0)
| Product | Fixed in | Advisory |
|---|---|---|
| Red Hat Satellite 6.11 for RHEL 7 | tfm-rubygem-actionpack-0:6.0.4.7-1.el7sat | RHSA-2022:5498 |
Frequently Asked Questions
Is CVE-2022-23633 in your dependencies?
Find it across RubyGems, including transitive dependencies.