CVE-2026-40477: Thymeleaf Ssti Incomplete Expression Recognizer

Detected an under-specified Thymeleaf expression-opener recognizer that checks only '$', '*', '#', '@', '~' but does NOT also check the preprocessing opener '_' (for "__...__") nor the literal-substitution opener '|' (for "|...|"). This is the CVE-2026-40477 (Thymeleaf <= 3.1.3.RELEASE) SSTI-bypass shape: SpringRequestUtils.containsExpression() fails to flag

Provally CuratedPublic repositoryHighMedium confidenceVerifiedApache-2.0Java
greprules fetch cve-2026-40477-thymeleaf-ssti-incomplete-expression-recognizer --engine opengrep

Description

Detected an under-specified Thymeleaf expression-opener recognizer that checks only '$', '*', '#', '@', '~' but does NOT also check the preprocessing opener '_' (for "__...__") nor the literal-substitution opener '|' (for "|...|"). This is the CVE-2026-40477 (Thymeleaf <= 3.1.3.RELEASE) SSTI-bypass shape: SpringRequestUtils.containsExpression() fails to flag