This commit is contained in:
mcoder 2026-04-14 20:31:12 +03:30
parent 3c8cefc60f
commit 4f694777e5

View File

@ -24,7 +24,9 @@ public function handle(Request $request, Closure $next): Response
if ($request->has('allow_framing')) {
$response->headers->remove('X-Frame-Options');
} else {
$response->headers->set('X-Frame-Options', 'DENY');
// برای تست Clickjacking موقتاً این خط را کامنت می‌کنیم تا ریدایرکت‌ها هم مسدود نشوند
// $response->headers->set('X-Frame-Options', 'DENY');
$response->headers->remove('X-Frame-Options');
}
// ۳. خاموش کردن محافظت پیش‌فرض XSS