В ядре Linux устранена следующая уязвимость:
crypto: tegra — исправлен расчет rctx->cryptlen в tegra_gcm_do_one_req()
Выполните расчет rctx->cryptlen в tegra_gcm_do_one_req() таким же образом.
это делается в tegra_ccm_crypt_init(). Существующие формулы могут привести к
сбой, если вызывающий абонент не вызывает tegra_gcm_setauthsize() и поэтому ctx->authsize
остается нулевым. Тогда операция дешифрования с неправильным rctx->cryptlen будет выполнена.
приведет к записи за пределы буфера rctx->dst_sg.
В качестве последующей очистки удалите поле struct tegra_aad_ctx->authsize, поскольку
он кажется совершенно неиспользованным. Также упростите tegra_ccm_setauthsize().
и tegra_gcm_setauthsize() соответственно.
Показать оригинальное описание (EN)
In the Linux kernel, the following vulnerability has been resolved: crypto: tegra - fix rctx->cryptlen calculation in tegra_gcm_do_one_req() Perform rctx->cryptlen calculation in tegra_gcm_do_one_req() the same way it is done in tegra_ccm_crypt_init(). The current formulae may lead to a crash if a caller does not call tegra_gcm_setauthsize() and so ctx->authsize remains zero. Then a decrypt operation with incorrect rctx->cryptlen will lead to a write beyound rctx->dst_sg buffer. As a follow-up cleanup delete struct tegra_aead_ctx->authsize field since it appears to be completely unused. Also simplify tegra_ccm_setauthsize() and tegra_gcm_setauthsize() functions respectively.
Характеристики атаки
Последствия
Строка CVSS v3.1