“Day 24: The Polyglot Poison — How I Turned a Resume Upload into a Remote Shell”
研究人员通过制作一个多头文件(同时为PDF和PHP脚本),成功绕过招聘平台的文件上传保护机制,实现远程代码执行并获得4000美元赏金。 2025-9-1 05:22:17 Author: infosecwriteups.com(查看原文) 阅读量:17 收藏

Bypassing Modern File Upload Protections with a Multi-Headed File

Aman Sharma

The target was a job recruitment platform. They allowed users to upload resumes, proudly displaying a banner: “All files are scanned for viruses!” I knew they’d be checking for .php and .exe extensions. My goal was deeper. I didn't want to upload a shell; I wanted to upload a resume that was also a shell. By crafting a perfectly malicious polyglot file—a PDF that was simultaneously a valid PHP script—I bypassed their entire security stack. The result was remote code execution and a $4000 bounty. This is the art of the file format polyglot.

free link

Press enter or click to view image in full size

Beyond the Extension: The Modern File Upload Landscape

Basic extension blacklists are obsolete. Modern defenses involve:

  • Content-Type Verification: Checking the Content-Type header (e.g., application/pdf).
  • Magic Number Validation: Reading the first few bytes of the file to verify its signature (e.g., %PDF- for PDFs).
  • Content Sanitization: Attempting to parse the file and remove potentially malicious elements.
  • Virus Scanning: Using AV engines to…

文章来源: https://infosecwriteups.com/day-24-the-polyglot-poison-how-i-turned-a-resume-upload-into-a-remote-shell-dc998722a328?source=rss----7b722bfd1b8d--bug_bounty
如有侵权请联系:admin#unsafe.sh