*Görünmeyenin Tehlikesi: CVE-2021–22204, Metadata Manipülasyonu ve RCE*
ExifTool versions before 12.24 mishandled DjVu file metadata, allowing an attacker to embed Perl code that would be executed when ExifTool parsed the file. This could lead to remote code execution on servers that process uploaded files with ExifTool, such as GitLab.
Published on medium.com
Siber güvenlikteki bazı zafiyetler, sistemin kapısını doğrudan kırarak içeri girmez; aksine, kimsenin şüphelenmediği noktalardan sızarlar. Bu noktalar genellikle log dosyaları, parser (ayrıştırıcı) kütüphaneleri veya görsel dosyaların metadata bilgileri gibi “zararsız” görünen bileşenlerdir.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Impact
An attacker could execute arbitrary code on the server, potentially leading to full compromise, and in some GitLab configurations this could be done without authentication.
What the attacker needed
Server uses ExifTool <12.24; attacker can upload a file; file processed by ExifTool
The fix
The vulnerability was fixed in ExifTool version 12.24; additionally, sandboxing and sanitising metadata are recommended.
How it was found
- Find a file upload point that accepts images or documents.
- Create a DjVu file with malicious Perl code in its metadata.
- Rename the file to a common image extension like .jpg to bypass extension checks.
- Upload the file; the server processes it with ExifTool, triggering the code.
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 write-up has not been written yet. The Original tab links to the source.
ExifTool is a tool that reads hidden information (metadata) from files like photos. A bug in how it read a certain file type (DjVu) let an attacker hide harmful computer code in that metadata. When the tool read the file, the code ran on the server, giving the attacker control.
What is RCE?
Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.