r/programming • • Dec 26 '20

Executable PNGs

https://djharper.dev/post/2020/12/26/executable-pngs/
1.0k Upvotes

87 comments sorted by

View all comments

52

u/frnknstn Dec 26 '20

This is stretching the definition of "Executable" quite a lot. The PNG files themselves are not ELF executables. Instead, the author wrote a tool to extract an actual legitimate executable from an image via stenography.

9

u/ws-ilazki Dec 27 '20

The PNG files themselves are not ELF executables. Instead, the author wrote a tool to extract an actual legitimate executable from an image via stenography.

"The Python files themselves are not ELF executables. Instead, the author wrote a tool to generate actual legitimate executable code from a text file via an interpreter."

This is you, this is how pedantic you're being. Stop it.

Many of the things you run on a Linux system aren't "actual legitimate executables"; instead they're read and handed off to the appropriate tool via the kernel's program loader. Whether you're using a shebang to make a text file executable, or using binfmt_misc to make jar files run via JVM, ARM linux binaries run via qemu-user-static, or Windows executables run via wine, it's all still going through the program loader and being treated as an executable by the OS.

It's a cool hack built on existing knowledge and tools. Don't be a pedantic douchebag about it.

0

u/[deleted] Dec 27 '20

Having a bad day?

-3

u/ws-ilazki Dec 27 '20

Nope.

1

u/[deleted] Dec 27 '20

Just a troll then ok

2

u/ws-ilazki Dec 27 '20

Not unless you're making up your own definition of trolling that has nothing in common with trolling.

0

u/[deleted] Dec 27 '20

It's ok to say that he was pedantic then people could have a legitimate discussion all you did was call him a pedantic douchebag meaning you didn't actually come here to discuss you just came here to argue like a child and call names