Level 5
I am using below code in public folder htaccess
<FilesMatch "\.php$">
Order Allow,Deny
Deny from all
</FilesMatch>
<FilesMatch "index[0-9]?\.php$">
Order Allow,Deny
Allow from all
</FilesMatch>
1 like
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
I found one php file inside public folder
Path is like below,
public/userprofilephoto/123123213.php
that code has image validation in laravel where only jpg or png file is allowed now if users trues to access this file directly in browser he will get a access to that file. how to prevent this?
Please or to participate in this conversation.