اصلاح هدر ها برای نمایش ایفریم
Verify / test (push) Failing after 1m19s

This commit is contained in:
2026-11-09 12:05:03 +03:30
والد 68c3dc0e41
کامیت a599086c11
2فایلهای تغییر یافته به همراه10 افزوده شده و 4 حذف شده
+1 -1
مشاهده پرونده
@@ -75,7 +75,7 @@ async def security(request, call_next):
if settings().api_key and not authenticated(request.headers.get('x-api-key')):
return JSONResponse({'success': False, 'error': {'code': 'unauthorized', 'message': 'Provide a valid X-API-Key header'}}, 401)
response = await call_next(request)
is_viewer = request.url.path.startswith('/view/')
is_viewer = request.url.path.startswith(('/view/', '/compare/'))
frame_ancestors = "'self' https://git.sadentel.net" if is_viewer else "'none'"
response.headers.update({
'X-Content-Type-Options': 'nosniff', 'Referrer-Policy': 'no-referrer',