Exploits / Vulnerability Discovered : 2020-05-12 |
Type : webapps |
Platform : php
This exploit / vulnerability Qdpm 9.1 arbitrary file upload is for educational purposes only and if it is used you will do on your own risk!
When a normal user tries to update their profile, they can arbitrarily
upload files to the user_photo area. Because there are no file extension
controls. Additionally, the .htaccess file has some protection against
malicious .php file. But, the developer writes the wrong regex. So, the
Attacker can change extension as (.PHP) and run code on the server
.htaccess file content:
----------------------------------------------
# This is used to restrict access to this folder to anything other
# than images
# Prevents any script files from being accessed from the images folder
<FilesMatch "\.(php([0-9]|s)?|s?p?html|cgi|pl|exe)$">
Order Deny,Allow
Deny from all
</FilesMatch>