Options -Indexes
DirectoryIndex index.php

<IfModule mod_rewrite.c>
  RewriteEngine On
  # This app is installed directly in the domain root. /public is not needed.
  RewriteRule ^public/?$ / [R=301,L]
  RewriteRule ^public/(.*)$ /$1 [R=301,L]
</IfModule>

<IfModule mod_headers.c>
  Header always set X-Frame-Options "SAMEORIGIN"
  Header always set X-Content-Type-Options "nosniff"
  Header always set Referrer-Policy "strict-origin-when-cross-origin"
</IfModule>

<FilesMatch "^(config|layout)\.php$">
  Require all denied
</FilesMatch>
