Terrapin Attack (CVE-2023-48795)
Terrapin Attack (CVE-2023-48795) 是什么?
Terrapin Attack (CVE-2023-48795)A 2023 prefix-truncation flaw in the SSH transport protocol that allows an active network attacker to silently downgrade or strip extensions during the handshake, weakening features like keystroke timing protection.
The Terrapin attack (CVE-2023-48795), disclosed by Bäumer, Brinkmann, and Schwenk in December 2023, is a prefix-truncation flaw in the SSH binary packet protocol. By manipulating packet sequence numbers during the initial KEX handshake — specifically when ChaCha20-Poly1305 (`chacha20-poly1305@openssh.com`) or CBC-EtM ciphers are used — a man-in-the-middle attacker can truncate the secure channel's initial messages without the integrity check failing, causing both ends to disagree about which extensions were negotiated. The most cited practical impact is silently disabling extensions such as keystroke-timing obfuscation; the underlying primitive can also weaken implementation-specific authentication features (notably AsyncSSH's CVE-2023-46446). Terrapin spurred quick fixes: OpenSSH 9.6 introduced a strict KEX mode that resets sequence numbers, and most major SSH implementations (Dropbear, libssh, PuTTY, Bitvise, Cisco IOS) followed. Mitigation is to upgrade clients and servers so both negotiate `strict-kex`, and to prefer AES-GCM ciphers, which are unaffected.
● 示例
- 01
An attacker positioned between two SSH peers truncates the KEX handshake so a keystroke-timing extension never gets negotiated, then mounts a timing attack on the user's password.
- 02
An infrastructure team rolls out OpenSSH 9.6 across all jump hosts; the new `strict-kex` negotiation reports `kex_strict_s_v00@openssh.com` and blocks the truncation primitive.
● 常见问题
Terrapin Attack (CVE-2023-48795) 是什么?
A 2023 prefix-truncation flaw in the SSH transport protocol that allows an active network attacker to silently downgrade or strip extensions during the handshake, weakening features like keystroke timing protection. 它属于网络安全的 攻击与威胁 分类。
Terrapin Attack (CVE-2023-48795) 是什么意思?
A 2023 prefix-truncation flaw in the SSH transport protocol that allows an active network attacker to silently downgrade or strip extensions during the handshake, weakening features like keystroke timing protection.
Terrapin Attack (CVE-2023-48795) 是如何工作的?
The Terrapin attack (CVE-2023-48795), disclosed by Bäumer, Brinkmann, and Schwenk in December 2023, is a prefix-truncation flaw in the SSH binary packet protocol. By manipulating packet sequence numbers during the initial KEX handshake — specifically when ChaCha20-Poly1305 (`chacha20-poly1305@openssh.com`) or CBC-EtM ciphers are used — a man-in-the-middle attacker can truncate the secure channel's initial messages without the integrity check failing, causing both ends to disagree about which extensions were negotiated. The most cited practical impact is silently disabling extensions such as keystroke-timing obfuscation; the underlying primitive can also weaken implementation-specific authentication features (notably AsyncSSH's CVE-2023-46446). Terrapin spurred quick fixes: OpenSSH 9.6 introduced a strict KEX mode that resets sequence numbers, and most major SSH implementations (Dropbear, libssh, PuTTY, Bitvise, Cisco IOS) followed. Mitigation is to upgrade clients and servers so both negotiate `strict-kex`, and to prefer AES-GCM ciphers, which are unaffected.
如何防御 Terrapin Attack (CVE-2023-48795)?
针对 Terrapin Attack (CVE-2023-48795) 的防御通常结合技术控制与运营实践,详见上方完整定义。
Terrapin Attack (CVE-2023-48795) 还有哪些其他名称?
常见的别称包括: CVE-2023-48795, SSH prefix truncation。
● 相关术语
- network-security№ 1205
SSH
RFC 4251 定义、运行在 22 端口的加密网络协议,在不可信网络上提供经过身份验证、加密且完整性保护的远程登录、命令执行与隧道。
- attacks№ 724
中间人攻击 (MitM)
攻击者在通信双方之间秘密转发或篡改消息,而双方均以为是在直接对话的一种攻击。
- network-security№ 1280
TLS 握手
Transport Layer Security 协议建立连接时的初始交换,用于验证服务器(可选地验证客户端)并派生用于加密会话后续数据的对称密钥。
- cryptography№ 190
密码套件
由密钥交换、身份认证、数据加密和完整性算法组合而成的命名集合,由 TLS 等协议在每次会话中协商使用。
- cryptography№ 179
ChaCha20-Poly1305
由 ChaCha20 流密码与 Poly1305 一次性认证器组成的 AEAD 结构,在 RFC 8439 中标准化,用于 TLS 1.3 和 WireGuard。
- attacks№ 1211
SSL/TLS 降级攻击
主动型中间人攻击,强迫客户端与服务器协商较弱的协议版本、密码套件或密钥长度,从而为后续攻击铺路。