Skip to content
OpenAdvisories
Unscored GO-2026-7029

Unbounded memory allocation during BDAT transaction in github.com/emersion/go-smtp

Published Nov 23, 2026 · Updated Nov 23, 2026 · Assigned by GO

Description

Conn.handleBdat disables the line length limit on the connection reader while reading a BDAT chunk and only restored it on error or on the final BDAT LAST chunk. A remote client that sends another command between two BDAT commands in a transaction bypasses Server.MaxLineLength, allowing unbounded memory allocation and denial of service.

Affected packages

EcosystemPackageAffectedFixedRecord
Go github.com/emersion/go-smtp >= 0.15.0, < 0.25.1 0.25.1 GO-2026-7029

References