Skip to Content »

iRoss.net » Encrypt / Obfuscate PHP … Pointless.

 Encrypt / Obfuscate PHP … Pointless.

  • June 5th, 2008
  • 9:29 pm

I was asked recently by someone to investigate the security offered by obfuscation scripts such as the one at http://www.rightscripts.com/phpencode (also available as a paid-for download)

Obviously anything which relies on PHP itself to ‘encode’ the script, must have the means of decryption built into the script - if it doesn’t then it wouldn’t run.

Around 5 lines of code later, and you have this … http://www.iross.net/phpdecode … a simple proof of concept which reverses the code generated by http://www.rightscripts.com/phpencode (and one or two other sites that work in a similar way)

So is there any way to really secure your PHP code? Yes, systems such as IonCube or the ByteCode encoder which require a ‘loader’ to be installed on the server are substantially more secure as the code is compiled rather than just obfuscated - these provide a secure option :)

Of course, all my own freelance web development clients get the source code without any sort of obfuscation - since they have paid for it!

Want your say?

* Required fields. Your e-mail address will not be published on this site

You can use the following XHTML tags:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Your gravatar will be used if available.
If you don't have one - go get one - they're free!