Skip to content
Info disclosure Disclosed report Beginner

Bug Report

The upload feature rejected a renamed PHP file in the browser, but sending the upload via post data allowed a PHP shell disguised as a PDF to be uploaded, which could be a risk to the web server.

1337_inj3c70r Follow

Originally disclosed on HackerOne

  • Triaged in under an hour
  • Fixed in 6 days
  • Paid in 6 days
  • Disclosed after 45 days

Sir,

I want to report a bug in your web which i have found in few minutes ago :)

I have registered In your website and i have found a upload option i want to upload some php files but its saying only .pdf file allowed so i have just change my (.php) file extension to (.pdf) first its saying not allowed its not a pdf file or file is corrupted... But when i try to upload it using post data i have successfully uploaded corrupted file

here is my proof:

https://85aa27de34e32ac9f9e0-e519cb8a62f48aa14df288cdc83ab719.ssl.cf5.rackcdn.com/hipaa_forms/2016/06/b193e25b-3218-4a09-8b09-b17bea6d5a18.pdf

its a php shell

if a attacker can change the value and successfully upload .php file using http request it can be risk for your webserver :)

Thanks

The original report as published on HackerOne, by 1337_inj3c70r. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the server relied on client-side validation and did not properly verify the file type or content on the server side.

Impact

An attacker could upload a PHP shell disguised as a PDF, which could be a risk to the web server.

What the attacker needed

A free account; ability to intercept HTTP requests

How it was found

  1. Register on the website and find the file upload feature.
  2. Attempt to upload a PHP file and observe that only .pdf files are allowed.
  3. Change the file extension from .php to .pdf and try to upload; the site rejects it as not a valid PDF.
  4. Send the upload using post data instead of the normal form.
  5. Successfully upload the PHP shell disguised as a PDF.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

A website allowed a file upload but rejected a renamed PHP file through the normal form. By sending the upload as post data, the attacker uploaded a malicious script that the server might execute.

What is Info disclosure?

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.

More by 1337_inj3c70r

View all

2 more disclosed reports, best first.

More from drchrono

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Information disclosure

The lesson behind this report.

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.