4.0medium
ntpkeygen can generate keys that ntpd fails to parse.
- Severity
- 4.0medium CVSS:3.1 by GitLab
- Exploit likelihood
- 0.52% (higher than 45% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- GitLab
Description
ntpkeygen can generate keys that ntpd fails to parse. NTPsec 1.2.0 allows ntpkeygen to generate keys with '#' characters. ntpd then either pads, shortens the key, or fails to load these keys entirely, depending on the key type and the placement of the '#'. This results in the administrator not being able to use the keys as expected or the keys are shorter than expected and easier to brute-force, possibly resulting in MITM attacks between ntp clients and ntp servers. For short AES128 keys, ntpd generates a warning that it is padding them.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| NTPsec ntpsec | =1.2.0, 1.2.0 | CVE List, NVD |
| fedoraproject fedora | 34 | NVD |
All scores
| GitLab | 4.0medium CVSS:3.1 | CVSS:3.1/AV:L/AC:H/PR:H/UI:R/S:U/C:N/I:H/A:N |
| NVD | 7.4high CVSS:3.1 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N |
| NVD | 5.8medium CVSS:2.0 | AV:N/AC:M/Au:N/C:P/I:P/A:N |
Classification
What each source says
CVE List
ntpkeygen can generate keys that ntpd fails to parse. NTPsec 1.2.0 allows ntpkeygen to generate keys with '#' characters. ntpd then either pads, shortens the key, or fails to load these keys entirely, depending on the key type and the placement of the '#'. This results in the administrator not being able to use the keys as expected or the keys are shorter than expected and easier to brute-force, possibly resulting in MITM attacks between ntp clients and ntp servers. For short AES128 keys, ntpd generates a warning that it is padding them.
NVD (es)
ntpkeygen puede generar claves que ntpd no puede analizar. NTPsec versión 1.2.0 permite a ntpkeygen generar claves con caracteres "#". ntpd entonces rellena, acorta la clave, o comete un fallo al cargar estas claves por completo, dependiendo del tipo de clave y la colocación del "#". Esto hace que el administrador no pueda usar las claves como se esperaba o que las claves sean más cortas de lo esperado y más fáciles de forzar, resultando posiblemente en ataques MITM entre clientes ntp y servidores ntp. Para claves AES128 cortas, ntpd genera una advertencia de que las está rellenando
References
| https://gitlab.com/NTPsec/ntpsec/-/issues/699 | issue-tracking, patch, third-party-advisory | |
| https://bugzilla.redhat.com/show_bug.cgi?id=1955859 | issue-tracking, patch, third-party-advisory | |
| https://gitlab.com/gitlab-org/cves/-/blob/master/2021/CVE-2021-22212.json | third-party-advisory | |
| https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/3GIT2HYL5BQXPGKI6ZDNG473IEQ5WQF2/ | vendor-advisory | |
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2021-22212 changed 2024-08-03 | CVE Terms of Use |
| NVD | CVE-2021-22212 changed 2026-06-17 | Public domain |