Improper Restriction of Excessive Authentication Attempts in Sorcery
Description
In Sorcery before 0.15.0, there is a brute force vulnerability when using password authentication via Sorcery. The brute force protection submodule will prevent a brute force attack for the defined lockout period, but once expired, protection will not be re-enabled until a user or malicious actor logs in successfully. This does not affect users that do not use the built-in brute force protection submodule, nor users that use permanent account lockout. This has been patched in 0.15.0.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
sorceryRubyGems | < 0.15.0 | 0.15.0 |
Affected products
1Patches
10f116d223826Fix brute force vuln due to callbacks not being ran (#235)
1 file changed · +4 −4
lib/sorcery/model.rb+4 −4 modified@@ -102,10 +102,6 @@ def authenticate(*credentials, &block) set_encryption_attributes - unless user.valid_password?(credentials[1]) - return authentication_response(user: user, failure: :invalid_password, &block) - end - if user.respond_to?(:active_for_authentication?) && !user.active_for_authentication? return authentication_response(user: user, failure: :inactive, &block) end @@ -118,6 +114,10 @@ def authenticate(*credentials, &block) end end + unless user.valid_password?(credentials[1]) + return authentication_response(user: user, failure: :invalid_password, &block) + end + authentication_response(user: user, return_value: user, &block) end
Vulnerability mechanics
Generated by null/stub on May 9, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.
References
7- github.com/advisories/GHSA-jc8m-cxhj-668xghsaADVISORY
- nvd.nist.gov/vuln/detail/CVE-2020-11052ghsaADVISORY
- github.com/Sorcery/sorcery/commit/0f116d223826895a73b12492f17486e5d54ab7a7ghsax_refsource_MISCWEB
- github.com/Sorcery/sorcery/issues/231ghsax_refsource_MISCWEB
- github.com/Sorcery/sorcery/pull/235ghsax_refsource_MISCWEB
- github.com/Sorcery/sorcery/security/advisories/GHSA-jc8m-cxhj-668xghsax_refsource_CONFIRMWEB
- github.com/rubysec/ruby-advisory-db/blob/master/gems/sorcery/CVE-2020-11052.ymlghsaWEB
News mentions
0No linked articles in our index yet.