Cross-Site Request Forgery (CSRF) in solidus_auth_devise (CVE-2021-41274)
Summary
Vulnerability in solidus_auth_devise (CVE-2021-41274). Confidential information can be exposed externally. Exploitable via solidus_auth_devise. Mitigation: upgrade to 2.5.4 or later.
Original description
The description as published by the source.
Impact
CSRF vulnerability that allows user account takeover.
All applications using any version of the frontend component of solidus_auth_devise are affected if protect_from_forgery method is both:
- Executed whether as:
- A
before_actioncallback (the default) - A
prepend_before_action(optionprepend: truegiven) before the:load_objecthook inSpree::UserController(most likely order to find).
- A
- Configured to use
:null_sessionor:reset_sessionstrategies (:null_sessionis the default in case the no strategy is given, butrails --newgenerated skeleton use:exception).
That means that applications that haven't been configured differently from what it's generated with Rails aren't affected.
Patches
Users should promptly update to solidus_auth_devise version 2.5.4.
Workarounds
A couple of options:
-
If possible, change your strategy to
:exception:class ApplicationController < ActionController::Base protect_from_forgery with: :exception end -
Add the following to
config/application.rbto at least run the:exceptionstrategy on the affected controller:config.after_initialize do Spree::UsersController.protect_from_forgery with: :exception end -
We've also released new Solidus versions monkey patching
solidus_auth_devisewith the quick fix. Those versions arev3.1.3,v.3.0.3&v2.11.12. See [GHSA-5629-8855-gf4g](https://github.com/solidusio/solidus/security/adviso…
Source: OSV.dev (Open Source Vulnerabilities) NVD GitHub Advisory OSV
Auto-generated summary
Assembled by SecPulse from the source data (CVSS, CWE, affected versions) using templates — no AI involved. Check the original description and references below for exact details.
A vulnerability tracked as CVE-2021-41274 has been found in solidus_auth_devise.
Attackers can target a specific entry point like solidus_auth_devise over the network to misuse the product.
Confidential information can be exposed externally.
What to do: upgrade solidus_auth_devise to 2.5.4 or later.
If unsure, ask your IT team or search "solidus_auth_devise CVE-2021-41274" on the vendor's site.
CVE-2021-41274 (solidus_auth_devise) — CWE-352
Attack vector: remote (network-reachable) / unauthenticated
Attack surface: solidus_auth_devise / protect_from_forgery / before_action / prepend_before_action
Patched: 2.5.4 — apply immediately
Plan: 1) Audit SBOM/dependencies, 2) Stage→prod upgrade, 3) Add WAF/proxy monitoring on affected endpoints, 4) Hunt IOCs in logs.
Refs: see the GHSA / vendor advisory / patched release linked on this page.
CSRF (CWE-352) exists in solidus_auth_devise. Attackers reach the vulnerable code path via solidus_auth_devise without authentication.
Check the vendor advisory for the affected versions of solidus_auth_devise. Attack surface: solidus_auth_devise / protect_from_forgery / before_action / prepend_before_action.
Severity: ?. Confidential information can be exposed externally.
Update to 2.5.4.
Until the patch is applied: disable the affected feature, apply WAF rules, or restrict access via network ACLs.
Search webserver/proxy logs for unusual request patterns matching this CVE's known IOCs. Run grep -r 'solidus_auth_devise' . against your dependency files (package-lock.json, requirements.txt, go.sum) to find affected services.
Response actions
Concrete steps and command examples for SOC/SRE teams to execute in order
-
1Identify exposure identify
grep -r 'solidus_auth_devise' . | grep -v node_modulesリポジトリと本番環境の依存ファイル (package-lock.json / requirements.txt / go.sum / Gemfile.lock 等) で
solidus_auth_deviseを grep し、稼働しているサービス・バージョンを把握する。 -
2Apply patch patch
Upgrade solidus_auth_devise to 2.5.4ステージング環境で 2.5.4 に上げて回帰テスト → 本番反映。回帰テストはアプリの主要ハッピーパスを含めること。
-
3Post-deployment verification verify
Confirm patched version is live in productionパッチ適用後、ステージングで PoC または同等の悪用パターンを再現して脆弱性が閉じたことを確認。本番ではアクセスログ・WAF でアラート再発が無いか継続監視。
Affected packages
References
- advisory nvd.nist.gov
- package github.com
- web github.com
- web github.com
- web github.com
- web github.com