How to block access to files without modifying .htaccess or ngnix config? [closed]

How to block access to files without modifying .htaccess or ngnix config? [closed]

error code: 523