Page 1 of 1
Lock a Code
Posted: Wed Nov 20, 2013 5:19 pm
by itay1023
Hi,
How can i lock a LC code?
Re: Lock a Code
Posted: Wed Nov 20, 2013 5:25 pm
by Klaus
Set a password for your stack.
Re: Lock a Code
Posted: Wed Nov 20, 2013 5:43 pm
by itay1023
How to do it?
Re: Lock a Code
Posted: Wed Nov 20, 2013 5:45 pm
by Klaus
Check "password" (sic!

) in the dictionary.
Re: Lock a Code
Posted: Wed Nov 20, 2013 5:48 pm
by itay1023
I want to lock the stack code, not the hole stack...
Re: Lock a Code
Posted: Wed Nov 20, 2013 6:07 pm
by Klaus
Sorry, you can only lock the complete stack or nothing.
Re: Lock a Code
Posted: Wed Nov 20, 2013 6:30 pm
by dunbarx
What exactly are you trying to protect? Klaus assumes the stack itself, which is the normal concern.
Are you trying to lock out a particular script, (or perhaps a card and its objects) so that they cannot be tampered with? There are ways to do that if this is what you really wanted.
Craig Newman
Re: Lock a Code
Posted: Wed Nov 20, 2013 7:30 pm
by Klaus
Hi Craig,
dunbarx wrote:...
There are ways to do that if this is what you really wanted
tell me more about this, please
Best
Klaus
Re: Lock a Code
Posted: Wed Nov 20, 2013 7:54 pm
by FourthWorld
It may be useful to note that protecting a stack's source code can only be done with the Commercial edition of LiveCode. The Community edition is licensed under the GPL, which requires that making the source code available whenever the app itself is distributed to others.
Re: Lock a Code
Posted: Wed Nov 20, 2013 8:41 pm
by dunbarx
Klaus.
I am not sure how high the OP's expectations were.
I was thinking of shenanigans, like using a backscript or a plug-in, as opposed to a stack script, that might not be visible to a less that highly motivated LC hacker, or perhaps a stack in use that would have the same moderate camouflage. Or was he aware that making a standalone pretty much locks out any tampering.
or put this in a custom property of a button:
on mouseUp
get the xxx of me
do it
end mouseUp
and the custom property itself:
answer "need a random number?" with "OK" or "Cancel"
if it = "OK" then answer random(999)
You know, shenanigans.
On the object side, if there is one, maybe the OP did not know he could lock certain properties of objects, like their position.
And Richard makes a great point, but, again, not sure if this treads on the OP's scope or not. Does the Community Edition allow standAlones? These are pretty opaque as far as the source code goes.
Craig
Re: Lock a Code
Posted: Wed Nov 20, 2013 8:47 pm
by FourthWorld
dunbarx wrote:Does the Community Edition allow standAlones? These are pretty opaque as far as the source code goes.
The Community Edition can make standalones for all supported platforms except iOS, where Apple's App Store EULA is seen as logically incompatible with the GPL.
The only thing the Community Edition's standalone can't do is encrypt scripts, since that would also be logically incompatible with the GPL.
In addition, GPL compliance suggests posting the source stacks in a publicly-available place, and for the convenience of those in the community who might use your app it may be helpful to include a link to the source stacks on the same page where the app is downloaded.