fix: DockerSecretsResolver - don't normalize absolute paths like /var/www/html/...
Some checks failed
Deploy Application / deploy (push) Has been cancelled

This commit is contained in:
2025-11-24 21:28:25 +01:00
parent 4eb7134853
commit 77abc65cd7
1327 changed files with 91915 additions and 9909 deletions

View File

@@ -202,6 +202,7 @@ final readonly class ResponseErrorRenderer implements ErrorRenderer
private function getTemplateName(int $statusCode): string
{
return match ($statusCode) {
403 => 'errors/403',
404 => 'errors/404',
500 => 'errors/500',
default => 'errors/error',
@@ -437,6 +438,14 @@ HTML;
*/
private function getHttpStatusCode(\Throwable $exception): int
{
// Map security exceptions to 403 Forbidden
// Check for specific security exceptions first
if ($exception instanceof \App\Framework\Exception\Security\CsrfValidationFailedException ||
$exception instanceof \App\Framework\Exception\Security\HoneypotTriggeredException ||
$exception instanceof \App\Framework\Exception\SecurityException) {
return 403;
}
// Use exception code if it's a valid HTTP status code
$code = $exception->getCode();
if ($code >= 400 && $code < 600) {