Valider 3eccaf41 rédigé par b_b's avatar b_b
Parcourir les fichiers

Ajout de l'entête "Connection: close" dans les réponses de l'écran

pour ne pas faire bénéficier du keep-alive aux éventuels attaquants

Ref https://core.spip.net/issues/4243
parent a741e3b7
Chargement en cours
Chargement en cours
Chargement en cours
Chargement en cours
+2 −0
Numéro de ligne d'origine Numéro de ligne de diff Ligne de diff
@@ -643,6 +643,7 @@ if (isset($ecran_securite_raison)) {
	header("Cache-Control: no-cache, must-revalidate");
	header("Pragma: no-cache");
	header("Content-Type: text/html");
	header("Connection: close");
	die("<html><title>Error 403: Forbidden</title><body><h1>Error 403</h1><p>You are not authorized to view this page ($ecran_securite_raison)</p></body></html>");
}

@@ -696,5 +697,6 @@ if (
	header("Cache-Control: no-cache, must-revalidate");
	header("Pragma: no-cache");
	header("Content-Type: text/html");
	header("Connection: close");
	die("<html><title>Status 429: Too Many Requests</title><body><h1>Status 429</h1><p>Too Many Requests (try again soon)</p></body></html>");
}