This time the bug isn’t in your code, it’s in PHP itself.
PHP2Shell: two CVEs in the runtime, unauthenticated RCE, PHP 5.4 to 8.x, exploited before patches shipped.
Fix: 8.5.12 / 8.4.27 / 8.3.36 / 8.2.35. Config mitigations reduce the risk, they don’t remove it.
