# CVE-2021-3754: Keycloak's improper input validation allows using email as username

- Severity: Medium 5.3 (CVSS:3.1, scored by NVD) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 2.23%, higher than 83% of CVEs (2026-12-01)
- Published: 2022-08-26T15:25:40.000Z
- Modified: 2026-06-17T04:05:42.230Z
- Also known as: GHSA-4vc8-pg5c-vg4x
- Weaknesses: CWE-20, CWE-670
- Assigned by: redhat

## Description

A flaw was found in keycloak where an attacker is able to register himself with the username same as the email ID of any existing user. This may cause trouble in getting password recovery email in case the user forgets the password.

(As written by CVE List.)

## Affected

- keycloak: Not-Known
- org.keycloak:keycloak-services (Maven): before 24.0.1
- redhat keycloak: no versions given
- redhat single_sign-on: 7.0

## Every score

- GitHub: CVSS:3.1 3.7 Low `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L`
- NVD: CVSS:3.1 5.3 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L`

## References

- <https://bugzilla.redhat.com/show_bug.cgi?id=1999196> (issue-tracking, vendor-advisory, web)
- <https://access.redhat.com/security/cve/CVE-2021-3754> (vendor-advisory, web)
- <https://github.com/keycloak/keycloak/security/advisories/GHSA-4vc8-pg5c-vg4x> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2021-3754> (advisory)
- <https://github.com/keycloak/keycloak/commit/f9708037383aa98741e4850447de64dc4a0d4b4e> (web)
- <https://github.com/keycloak/keycloak> (package)

## Sources

- CVE List: [CVE-2021-3754](https://www.cve.org/CVERecord?id=CVE-2021-3754), CVE Terms of Use, modified 2024-08-03
- GitHub Advisory Database: [GHSA-4vc8-pg5c-vg4x](https://github.com/advisories/GHSA-4vc8-pg5c-vg4x), CC-BY-4.0, modified 2024-12-20
- NVD: [CVE-2021-3754](https://nvd.nist.gov/vuln/detail/CVE-2021-3754), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2021-3754 · Whole record: https://cve.day/CVE-2021-3754.json · Rebuilt by cve.day 2026-11-25T22:58:07.801Z
