Reputation: 4107
Is there any chance to restrict a php script from being shared and used without license? The scripts are paid and I am thinking what could be a way to prevent "sharing" this php script from happening. Is this possible or impossible? Because the code is open and I can't encrypt all of it.
I came to a conclusion and not sure if this can work or no?
A. The script asks user to enter a LICENSE/KEY
B. The license is sent to my licensing server and check whether the license is a valid one. (http://.... ?license=X)
C. The license is checked and the result is sent back to client server.
D. The script won't execute if the LICENSE is not valid.
Is that practically possible? or no?
Problem remains that the user can remove the license check part right (Since the code is open) ? But I could maybe encrypt that file and make it part of a core file that wouldn't have to be edited by user but still required file that if it was removed, the script won't function probably.. hmm I am lost :)
Upvotes: 4
Views: 1786
Reputation: 12914
No, I do not think this is actually possible. If you can't encrypt it, then there is no way to prevent someone from just removing that portion of your script. You could try to make it a pain in the butt to remove. But no matter how hard to you make it, a determined coder could always remove the license check while leaving the primary script intact.
Upvotes: 4