ADVISORIES

GitHub Advisory Database

GHSA-9wxp-w4px-32vh

Spring Boot's Mail Auto-Configuration Does Not Enable SSL Hostname Verification

Moderate CVE-2026-40992

Details

Spring Boot's Mail auto-configuration does not enable hostname verification. Applications that set the relevant JavaMail property, such as spring.mail.properties.mail.smtp.ssl.checkserveridentity=true, are not affected.

Affected versions: Spring Boot 4.0.0 through 4.0.6; 3.5.0 through 3.5.14; 3.4.0 through 3.4.16.

Affected packages

EcosystemPackageAffected versions
Mavenorg.springframework.boot:spring-boot-starter-mail
From 4.0.0 before 4.0.7 (fixed in 4.0.7)
Mavenorg.springframework.boot:spring-boot-starter-mail
From 3.5.0 before 3.5.15 (fixed in 3.5.15)
Mavenorg.springframework.boot:spring-boot-starter-mail
From 3.4.0 up to and including 3.4.16

References