# Disable execution of scripts in upload directories
<FilesMatch "\.(php|phtml|php3|php4|php5|php6|php7|php8|php9|phps|pl|py|cgi|asp|aspx|sh|shtml)$">
    <IfModule mod_authz_core.c>
        Require all denied
    </IfModule>
    <IfModule !mod_authz_core.c>
        Order deny,allow
        Deny from all
    </IfModule>
</FilesMatch>

# Prevent MIME type sniffing override
<IfModule mod_headers.c>
    Header set X-Content-Type-Options "nosniff"
</IfModule>
