Discoverability of user password hash in Statamic CMS
Published 29 Mar 2022 · Updated 16 Feb 2024
Affected packages
- Affected
- <3.2.39
- Fixed in
- 3.2.39
composer require statamic/cms:^3.2.39- Affected
- >=3.3.0 <3.3.2
- Fixed in
- 3.3.2
composer require statamic/cms:^3.3.2Details
Description
It was possible to confirm a single character of a user's password hash (just the hash, not the password) using a specially crafted regular expression filter in the users endpoint of the REST API. Many requests could eventually uncover the entire hash.
The hash would not be in the response, however the presence or absence of a result would confirm if the character was in the right position. It would take a long time since the API has throttling enabled by default.
Additionally, the REST API would need to be enabled, as well as the users endpoint. Both of which are disabled by default.
Resolution
Filtering by password or password hash has been disabled.
Credits
We would like to thank Thibaud Kehler for reporting the issue.
Is GHSA-qcgx-7p5f-hxvr in any of your client repos?
Checking one package by hand is fine. Checking it across forty client projects is not. NPMscan reads the lockfiles in every GitHub repo you pick, finds each project with an affected statamic/cms, and gives you the command that fixes it.
References
Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.