Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Security Fix for XSS - huntr.dev #511

Merged
merged 2 commits into from Mar 22, 2021

Conversation

huntr-helper
Copy link
Contributor

@purecarnage (https://huntr.dev/users/purecarnage) has fixed a potential XSS vulnerability in your repository 馃敤. For more information, visit our website (https://huntr.dev/) or click the bounty URL below...

Q | A
Version Affected | *
Bug Fix | YES
Original Pull Request | 418sec#1

If you are happy with this disclosure, we would love to get a CVE assigned to the vulnerability. Feel free to credit @purecarnage, the discloser found in the bounty URL (below) and @huntr-helper.

User Comments:

馃搳 Metadata

Bounty URL: https://www.huntr.dev/bounties/1-other-tinyfilemanager/

鈿欙笍 Description

An XSS vulnearbility was reported in huntr.dev at the link given above.
This was fixed by using fm_enc() function to encode html characters.

馃捇 Technical Description

The issue was caused at three locations (sinks). The fix was simple, wrap the output string with fm_enc()

馃悰 Proof of Concept (PoC)

  • Just upload a file with filename: "><img src=x onerror=alert(222)>.png.
  • Go back to homepage, you'll see three alert boxes.

Here's a GIF by the reporter: https://drive.google.com/file/d/1t2afWVrLu_mb_S69n6d4SbLHOziuEeuZ/view?usp=sharing

馃敟 Proof of Fix (PoF)

I've replayed the same payload, it will not pop an alert box as before.

tfm-fix

@prasathmani prasathmani merged commit 03c3f6d into prasathmani:master Mar 22, 2021
ner00 pushed a commit to ner00/tinyfilemanager that referenced this pull request May 7, 2023
Co-authored-by: Vaibhav Shinde <vaibhavkshinde20@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants