[TYPO3-core] RFC #17471: Status "500 Internal Server Error" returned, if page is not found

Helmut Hummel helmut.hummel at typo3.org
Tue Feb 22 00:28:59 CET 2011


Hi,

On 21.02.11 21:33, Steffen Gebert wrote:

> 
> Solution:
> Check in the Exception Handler, whether a status code has already been sent.

With this change, the 500 status header in the exception handler is
never sent.

A simple test:

<?php
header('HTTP/1.0 404 Not Found');
var_dump(headers_list());
?>

reveals, that the status header is not included in the output of
headers_list(), at least not in the php versions I tested (5.2.13, 5.3.2).

So the only solution I could imagine is to use a dedicated exception
class (or at least a special Exception code), which the can be handled
accordingly in the exception handlers.
This would be cleaner anyway.

Kind regards,
Helmut

-- 
Helmut Hummel
TYPO3 Security Team Leader

TYPO3 .... inspiring people to share!
Get involved: typo3.org


More information about the TYPO3-team-core mailing list