Page 1 of 1

Restricting script execution by domain

Posted: Wed Dec 28, 2005 1:53 pm
by jaymoore_299
I want to restrict a php script to a specific domain such that only from that domain can the script run. I want this restriction to be very hard to locate in the php files so that you can't just search http://www.domain.com in some file and change it to whatever you want. The purposes of this is so that I can sell the script as commercial product. Anyone know if this is possible?

Posted: Wed Dec 28, 2005 2:50 pm
by josh
You could hide it in the scripts using different types of encryption, your best bet is to have your script validate itself against some kind of lisencing server you control, and make this validation deeply integrated...


there is no foolproof way, you should also check out the different products zend offers all of which can be gotten around, some of their products encrypt the code and have it expire after certain amounts of time, or limit the script to certain domains like you said.