Live data from Hacker News

Malware Hidden Inside JPG EXIF Headers

blog.sucuri.net

1–10 of 65 posts

Re: Malware Hidden Inside JPG EXIF Headers

#3
As malicious as this may be it is pure genius. It should include a message as such:

Elk Cloner: The program with a personality It will get on all your disks It will infiltrate your chips Yes, it's Cloner! It will stick to you like glue It will modify RAM too Send in the Cloner!

Re: Malware Hidden Inside JPG EXIF Headers

#5
Seems like itt was possible to hide it so well due to an oversight in the API for preg_replace. In-band signaling in general makes it easy for people to accidentally add security holes. What they should have done is pass the regex options as a separate parameter, then it would have been obvious that something fishy was going on here.

Re: Malware Hidden Inside JPG EXIF Headers

#8

From PHP documentation ( http://php.net/manual/en/function.preg-replace.php ) 5.5.0 The /e modifier is deprecated. Use preg_replace_callback() instead.

True, but most value hosting platforms run anything between 5.2.x and 5.4.x. with no option to upgrade.

Re: Malware Hidden Inside JPG EXIF Headers

#10
So the real hole is in `preg_replace` which can execute arbitrary strings on the server if the /e flag is found? Why does this exist?

Any how, this seems to be a genius exploit! If a site lets users upload photos and they use this function, a user could do this.

Basically a good frame work should have 'safe' functions that are designed to accept 'user input' i.e arbitrary strings and never set up a situation where these strings are executed

Post reply on HN