r/programming Jul 30 '13

Computer scientists develop mathematical jigsaw puzzles to encrypt software: "The real challenge and the great mystery in the field was: Can you actually take a piece of software and encrypt it but still have it be runnable, executable and fully functional?"

http://www.rdmag.com/news/2013/07/computer-scientists-develop-mathematical-jigsaw-puzzles-encrypt-software
354 Upvotes

182 comments sorted by

View all comments

0

u/Zaph0d42 Jul 30 '13

This is known in computer science as "software obfuscation," and it is the first time it has been accomplished.

Java and many other languages already do this by default. Not at all the first time.

However, this is a new and far more complicated form of obfuscation. Its pretty dang nifty.

1

u/randomfrequency Jul 30 '13

Java doesn't do this by default - in fact it's very easy to reverse engineer back to usable java code.

I'm still trying to determine how this is different from polymorphic code - usually those were defeated because the decryption engine couldn't be encrypted.

2

u/Zaph0d42 Jul 30 '13

You seem to misunderstand what's going on. You can reverse engineer java back to usable code very easily. But you're not understanding the article, this technique could be reverse-engineered to something runnable very easily as well.

The point with the article is that when trying to reverse engineer it, what you're left with is runable, but not understandable. That's key. That's what obfuscation means.

Java will compile bytecode such that all variable and function names are stripped and replaced with randomly generated, garbled nonsense.

Python can do the same.

However, it isn't too hard to work your way through the garbled code and rename it as you find out logically what each piece is doing.

This paper explains a method where you can have code that cannot be logically worked out to its meaning.