phpgurukul Online Shopping Portal Arbitrary File Upload Vulnerability Allowing Remote Code Execution

Vulnerability

A vulnerability allowing arbitrary file upload has been identified in phpGurukul Online Shopping Portal version 2.0. This issue arises in the admin 'insert-product.php' file, where uploaded files are not properly validated for their extensions. As a result, an admin user can upload malicious files, such as PHP scripts, which could be executed on the server, leading to remote code execution.

Impact

Exploitation of this vulnerability allows for arbitrary file upload, with the potential for remote code execution on the server.

Reproduction

To reproduce this vulnerability, log in as an admin user and navigate to the 'Insert Product' section. Fill out the required product information and upload a malicious PHP file disguised as an image. After the product is created, access the uploaded file through the product's image directory, appending a command parameter to execute commands on the server.

Remediation

To address this vulnerability, implement an extension whitelist to only allow safe file types, such as JPG, PNG, or PDF. Additionally, verify the actual content of uploaded files using MIME type and magic bytes, rather than relying on file extensions, which can be easily spoofed.

Added: Sep 3, 2025, 4:02 PM
Updated: Sep 3, 2025, 6:28 PM

Vulnerability Rating

Custom Algorithm
spread
1.0
impact
10.0
exploitability
6.3
remediation
0.0
relevance
0.5
threat
6.4
urgency
2.9
incentive
1.7

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.