Files
snapcad-studio/apps/web/public/.htaccess
T
Enes Yakıştır ee28672e23
Build and Push Docker Images / build (push) Canceled after 0s
Desktop Release / Build linux desktop (push) Canceled after 0s
Desktop Release / Build windows desktop (push) Canceled after 0s
Desktop Release / Attach packages to release (push) Canceled after 0s
Desktop Release / Build macos desktop (push) Canceled after 0s
CI / Typecheck and unit tests (push) Canceled after 0s
release: SnapCAD Studio 1.0.10 (desktop menuler, macOS kisayollari, YakNet SSO)
2026-11-12 10:12:35 +03:00

60 lines
2.2 KiB
ApacheConf

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
DirectoryIndex index.html index.php
Options -Indexes
ServerSignature Off
<IfModule mod_mime.c>
AddType application/wasm .wasm
AddType application/javascript .js .mjs
AddType image/svg+xml .svg
AddType text/yaml .yml
AddType application/octet-stream .exe .blockmap
</IfModule>
<IfModule mod_headers.c>
Header always set X-Content-Type-Options "nosniff"
Header always set X-Frame-Options "SAMEORIGIN"
Header always set Referrer-Policy "strict-origin-when-cross-origin"
Header always set Permissions-Policy "camera=(), microphone=(), geolocation=(), payment=()"
Header always set Cross-Origin-Opener-Policy "same-origin-allow-popups"
# HSTS yalnızca HTTPS üzerinden sunulduğunda gönderilir.
Header always set Strict-Transport-Security "max-age=31536000; includeSubDomains" "expr=%{HTTPS} == 'on'"
</IfModule>
<FilesMatch "\.(html|htm)$">
<IfModule mod_headers.c>
Header set Cache-Control "no-cache, no-store, must-revalidate"
Header set Pragma "no-cache"
Header set Expires 0
</IfModule>
</FilesMatch>
# Service worker, manifest ve masaüstü güncelleme bildirimleri önbellekte takılı kalmasın.
<FilesMatch "^(sw\.js|manifest\.json|manifest\.webmanifest|latest\.yml)$">
<IfModule mod_headers.c>
Header set Cache-Control "no-cache, no-store, must-revalidate"
Header set Pragma "no-cache"
Header set Expires 0
</IfModule>
</FilesMatch>
# Gizli yapılandırma ve kaynak dosyalarına dışarıdan HTTP erişimini engelle
<FilesMatch "^\.(env|git|htaccess)|snap-config\.php$|composer\.(json|lock)$|package(-lock)?\.json$|\.(sql|log|bak|ini|sh|ps1)$">
Require all denied
</FilesMatch>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
# Kaynak kod, bağımlılık ve geliştirme klasörlerini dışarıya kapat
RewriteRule ^(?:vendor|node_modules|apps|scripts|tests|src|database|\.git|\.github|\.next-export)(?:/|$) - [F,L]
# Mevcut dosya (.php, .js, .wasm vb.) veya klasör varsa doğrudan sun
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
# SPA yönlendirmesi: bulunamayan rotaları index.html'e yönlendir
RewriteRule ^ index.html [L]
</IfModule>