Standalone APP Encryption Question

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
JLGDBMD
Posts: 12
Joined: Wed Jul 04, 2012 6:13 pm

Standalone APP Encryption Question

Post by JLGDBMD » Wed Aug 01, 2012 8:19 pm

I have read a number of posts regarding "encrypting" livecode stacks.
I have run across conflicting information.

Entering a password protects the scripts but not the field contents when you are working
with a stack in the development environment.

When you create a standalone app and select encrypt with password is the entire
stack including the fields encrypted or only the scripts?

Thanks,

Jorge

mwieder
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3581
Joined: Mon Jan 22, 2007 7:36 am
Contact:

Re: Standalone APP Encryption Question

Post by mwieder » Wed Aug 01, 2012 9:12 pm

No, just the scripts. If you need to have field contents encrypted as well (although the why of it escapes me) you can put the information into a script and then have the opencard handler or something similar fill in the field contents.

JLGDBMD
Posts: 12
Joined: Wed Jul 04, 2012 6:13 pm

Re: Standalone APP Encryption Question

Post by JLGDBMD » Wed Aug 01, 2012 10:01 pm

Thanks for the reply. There is data in a hidden table field which
populates a data table when the correct log in password is entered.
It is the data in the hidden field that I would like to protect.

So if I understand this correctly - In a standalone app that is password
protected the data that is in fields (hidden though they may be) can
be accessed from an external script editor?

Jorge

JLGDBMD
Posts: 12
Joined: Wed Jul 04, 2012 6:13 pm

Re: Standalone APP Encryption Question

Post by JLGDBMD » Wed Aug 01, 2012 10:26 pm

I just found the baseencode64(myData) and the basedecode64(my data) in the
livecode dictionary. I think it will work. At least the data in the fld will be
encoded and not stored as readable text. - Thanks again for the prompt
response. - Jorge

I store my data in an fld encoded.
It is decoded when the app is opened and then populated to the data table.

on DataStore
put base64Encode(fld "datashow1") into fld "DCode"
put empty into fld "datashow1"
end DataStore

On ReclaimData
put fld "DCode" into hold
put base64decode(hold) into fld "datashow1"
put fld "DataShow1" into theText
put false into firstLineContainsColumnNames
set the dgText [ firstLineContainsColumnNames ] of group "DataShow" to theText
End ReclaimData

mwieder
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3581
Joined: Mon Jan 22, 2007 7:36 am
Contact:

Re: Standalone APP Encryption Question

Post by mwieder » Wed Aug 01, 2012 10:58 pm

OK. That should work for a first pass. You can also encrypt the data and/or compress it to make it even harder to identify.

JLGDBMD
Posts: 12
Joined: Wed Jul 04, 2012 6:13 pm

Re: Standalone APP Encryption Question

Post by JLGDBMD » Wed Aug 01, 2012 11:56 pm

Thanks for the great tip. Changed the code to following -

on DataStore
put base64Encode(fld "datashow1") into DataHold
put compress(DataHold) into fld "DCode"
put empty into fld "datashow1"
end DataStore

On ReclaimData
put fld "DCode" into hold
put decompress(hold) into DataHold
put base64decode(DataHold) into fld "datashow1"
put fld "DataShow1" into theText
put false into firstLineContainsColumnNames
set the dgText [ firstLineContainsColumnNames ] of group "DataShow" to theText
End ReclaimData

Regards,

Jorge

Post Reply