Неправильная уязвимость Verification уязвимости Cryptographic Signature в командно-алембическом AshAuthentication позволяет вызывающему действие отзыва токена нейтрализовать отзыв или записать произвольные строки в ресурс токена. AshAuthentication.TokenResource.RevokeTokenChange.change/3 считывает аргумент :token и декодирует его с помощью AshAuthentication.Jwt.peek/1, который делегирует Joken.peek_claims/1 и не выполняет проверку подписи, в отличие от Jwt.verify/4. Заявления jti, exp и sub, которые он возвращает, записываются прямо в запись отзыва, защищенную только byte_size(token) > 0. Поскольку expires_at происходит от выбранного злоумышленником exp, поддельная копия подлинного токена, которая сохраняет реальный jti, но даты назад exp, дает строку отзыва, которая уже истекла: expunge_expired удаляет ее, и подлинное токен проходит аннулирование? снова.
Произвольные значения jti и sub могут быть вставлены одинаково. Эта проблема затрагивает ash_authentication: от 0.2.0 до 4.15.0 и от 5.0.0-rc.0 до 5.0.0-rc.14.
Показать оригинальное описание (EN)
Improper Verification of Cryptographic Signature vulnerability in team-alembic AshAuthentication allows a caller of the token revocation action to neutralise a revocation or write arbitrary rows into the token resource. AshAuthentication.TokenResource.RevokeTokenChange.change/3 reads the :token argument and decodes it with AshAuthentication.Jwt.peek/1, which delegates to Joken.peek_claims/1 and performs no signature check, unlike Jwt.verify/4. The jti, exp and sub claims it returns are written straight onto the revocation record, guarded only by byte_size(token) > 0. Because expires_at derives from the attacker-chosen exp, a forged copy of a genuine token that keeps the real jti but backdates exp yields a revocation row that is already expired: expunge_expired removes it and the genuine token passes revoked? again. Arbitrary jti and sub values can be inserted the same way. This issue affects ash_authentication: from 0.2.0 before 4.15.0 and from 5.0.0-rc.0 before 5.0.0-rc.14.
Характеристики атаки
Последствия
Строка CVSS v4.0