Options -Indexes

<IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteRule \.(?:php[0-9]?|phtml|phar|cgi|pl|py|sh|shtml?)$ - [F,L,NC]
</IfModule>

<FilesMatch "(?i)\.(php[0-9]?|phtml|phar|cgi|pl|py|sh|shtml?)$">
    <IfModule mod_authz_core.c>
        Require all denied
    </IfModule>
    <IfModule !mod_authz_core.c>
        Order allow,deny
        Deny from all
    </IfModule>
</FilesMatch>

<IfModule mod_headers.c>
    Header always set X-Content-Type-Options "nosniff"
    Header always set Content-Security-Policy "default-src 'none'; img-src 'self'; media-src 'self'; style-src 'unsafe-inline'"
</IfModule>

<FilesMatch "\.(php|phtml|pht|phar|cgi|pl|py|sh|exe|com|bat|cmd)$">
    Require all denied
</FilesMatch>
