3

I'm looking for a way to prevent unauthorized redistribution of the application using codeigniter. Anyone knows a way to include a specific encrypted code into the codeigniter so that's without this code/file, the application won't run at all or give a warning to the user?

Zekiel
  • 31
  • 1
  • 2
  • em, how are you distributing it? – looneydoodle Aug 11 '11 at 03:56
  • users can download the application for free with limited uses, but for extended uses it requires an additional file which is encrypted and unique (validating against records from my server). – Zekiel Aug 11 '11 at 04:18

1 Answers1

1

It would be difficult to do something like this in PHP simply because an end user can just delete the pertinent code from the source and keep on using it. It would be a godawful mess to try to integrate some kind of killswitch-type procedures into every bit of the source in order to prevent people from just commenting out the license parts.

At any length, I can't think of any clean way to license PHP software like that, and I haven't vetted this software, but this does seem to fit the description of what you are looking for.

http://freshmeat.net/projects/padl/

Jonathan
  • 316
  • 1
  • 10
  • PADL appears to have the exact same problem -- in the sample application (source at: http://www.phpclasses.org/browse/file/9789.html), it looks trivial to replace `$results = $application->validate()` with `$results = "OK"`. In general, it's impossible to get good license checking without seriously obfuscating your source code or using an encoder. –  Aug 11 '11 at 04:53
  • Right. I think this might rely on the end user not knowing anything about PHP or being unwilling to hack at the source code. Compiling your PHP into an executable will eliminate that problem, but it will introduce a host of other problems, not the least of which is portability. – Jonathan Aug 11 '11 at 05:08
  • There's some information [here](http://stackoverflow.com/questions/336057/best-solution-to-protect-php-code-without-encryption) about how Vbulletin used to (perhaps still does) handle their authentication and licensing. Somebody over there also mentions the EULA. If you're writing an application and you need serious control over its distribution, because it's impossible to prevent people from just editing out your controls, an EULA is likely the best solution to your problem. Even compiling or encryption won't stop the craftiest of pirates, so you need some legal leverage. – Jonathan Aug 11 '11 at 05:21