CVE-2026-58433: Go Legacy Cookie Csrf Protection

Legacy cookie-based CSRF protection using `NewCSRFProtector` or `CsrfOptions` is susceptible to cross-origin bypasses. Use modern origin-based cross-site request protection (`CrossOriginProtection`) instead.

Provally CuratedPublic repositoryMediumMedium confidenceVerifiedApache-2.0Go
greprules fetch cve-2026-58433-go-legacy-cookie-csrf-protection --engine opengrep

Description

Legacy cookie-based CSRF protection using `NewCSRFProtector` or `CsrfOptions` is susceptible to cross-origin bypasses. Use modern origin-based cross-site request protection (`CrossOriginProtection`) instead.