Secure Text

A place for you to show off what you have made with LiveCode

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
Emily-Elizabeth
Posts: 126
Joined: Mon Jan 03, 2022 7:10 pm
Contact:

Secure Text

Post by Emily-Elizabeth » Sat Dec 06, 2025 1:46 am

This is a program (still in development) that will allow you to securely save text out as encrypted data. Right now it doesn't do anything, but am adding features all the time. Because it is built with the Community Edition of Livecode, it is under the GPLv3 license.

https://github.com/emily-elizabeth/SecureText_LC/

Emily-Elizabeth
Posts: 126
Joined: Mon Jan 03, 2022 7:10 pm
Contact:

Re: Secure Text

Post by Emily-Elizabeth » Sat Dec 06, 2025 6:24 pm

Built a test application for Linux and Windows (not tested by me as I only have macOS)

https://github.com/emily-elizabeth/Secu ... C/releases

Emily-Elizabeth
Posts: 126
Joined: Mon Jan 03, 2022 7:10 pm
Contact:

Re: Secure Text

Post by Emily-Elizabeth » Mon Dec 08, 2025 12:06 am

Here is the official 1.0.0 release of Secure Text.

This program allows you to enter text and save it in an encrypted format. You can also format the text using bold and italic. The encryption is "camellia-256-cbc" and is saved as a binary file so your data can't be read.

https://github.com/emily-elizabeth/Secu ... C/releases

stam
Posts: 3167
Joined: Sun Jun 04, 2006 9:39 pm

Re: Secure Text

Post by stam » Mon Dec 08, 2025 3:09 pm

Hi Emily, I was curious to try this, but there is an error - clicking any of the two buttons just generates an error, because it doesn't load SecureTextBackscript into the backscripts at startup.

I can see this is meant to load the script of this substack into the backscripts using the startup handler, which is placed in the mainstack's script - however the startup message is sent to the card, not the stack, so it doesn't fire, at least on LC10/Classic.

The fix is either to move this handler to the card, or - probably preferably - changing the handler from Startup to preOpenStack, which will run from the stack script. Certainly doing the latter fixed the issue for me.


My $0.02 regarding the app itself:

From the point of view of end-users:
As a proof of concept this works well, but from a usability point of view it's not that functional - for users you'd really need some kind of database to store the encrypted text with a date/name, otherwise they'd need to rely on the filesystem data (filepath/filename) to deduce what the encrypted text is. Would be nice to combine with an sqlite database to provide file metadata for the end-user.

Also, asking users for both a password and a salt, while more secure, is almost unknown to end-users. I suspect a system that uses a username or email as the salt would probably do just as well if not just using static text. In other words, end-users expect to enter 1, not 2 static passwords.

From the point of view of developers:
With a bit of fine-tuning you could make this into a very nice, simple library to load with "start using <stack>". Not sure it would need to run as a back script, but you could do this from "on libraryStack" if needed.
This would enable developers to easily store encrypted text anywhere in an app/sqlte, a simple function to return the encrypted text given parameters for password/salt is all that is really needed.
You could also go 1 step further and create a direct API for CRUD operation in SQLite with encrypted data, as this is not normally available in SQLite. Doing this well would be a wonderful thing!

Overall I would say very nice, but doesn't quite make it as an app for end-users or as a library for developers. However in either case minimal work is needed to get it there. Would really like to see an integrated solution for encrypted SQLite!

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10436
Joined: Wed May 06, 2009 2:28 pm

Re: Secure Text

Post by dunbarx » Mon Dec 08, 2025 3:27 pm

Stam, Emily.
however the startup message is sent to the card, not the stack, so it doesn't fire, at least on LC10/Classic.
Been that way forever, it is how LC works. Always use the card, or, as Stam mentions, "preopenStack".

Craig

Emily-Elizabeth
Posts: 126
Joined: Mon Jan 03, 2022 7:10 pm
Contact:

Re: Secure Text

Post by Emily-Elizabeth » Mon Dec 08, 2025 3:28 pm

That's right, the startUp message does not get fired in the IDE, so I'll change it to the preOpenStack message (thanks for the pointer).

Emily-Elizabeth
Posts: 126
Joined: Mon Jan 03, 2022 7:10 pm
Contact:

Re: Secure Text

Post by Emily-Elizabeth » Tue Dec 09, 2025 7:39 pm

Updated Secure Text to 1.1.0 and it now handles drops of text files and text.
https://github.com/emily-elizabeth/Secu ... C/releases

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10436
Joined: Wed May 06, 2009 2:28 pm

Re: Secure Text

Post by dunbarx » Tue Dec 09, 2025 9:21 pm

I think it just like Emily to add two enhancements while simply changing the residence of a handler. :wink:

Craig

Emily-Elizabeth
Posts: 126
Joined: Mon Jan 03, 2022 7:10 pm
Contact:

Re: Secure Text

Post by Emily-Elizabeth » Tue Dec 09, 2025 9:46 pm

Got to make it worthwhile :) Thanks for the kind words Craig.

Emily-Elizabeth
Posts: 126
Joined: Mon Jan 03, 2022 7:10 pm
Contact:

Re: Secure Text

Post by Emily-Elizabeth » Wed Dec 10, 2025 8:55 pm

Added RTF import. It only supports the subset that Livecode supports.
https://github.com/emily-elizabeth/SecureText_LC

Emily-Elizabeth
Posts: 126
Joined: Mon Jan 03, 2022 7:10 pm
Contact:

Re: Secure Text

Post by Emily-Elizabeth » Wed Dec 10, 2025 10:03 pm

If anyone downloaded the zipped or the tar.gz source code between my posting and this post, it contained old source code and did not have the RTF support (the applications did though). Downloading the source code from the main branch had the updated code.

Emily-Elizabeth
Posts: 126
Joined: Mon Jan 03, 2022 7:10 pm
Contact:

Re: Secure Text

Post by Emily-Elizabeth » Thu Dec 11, 2025 2:26 am


FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10078
Joined: Sat Apr 08, 2006 7:05 am
Contact:

Re: Secure Text

Post by FourthWorld » Thu Dec 11, 2025 6:50 am

Emily-Elizabeth wrote:
Thu Dec 11, 2025 2:26 am
Got reviewed on Softpedia https://www.softpedia.com/get/Office-to ... t-LC.shtml
And a very nice review at that. Congrats.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

Emily-Elizabeth
Posts: 126
Joined: Mon Jan 03, 2022 7:10 pm
Contact:

Re: Secure Text

Post by Emily-Elizabeth » Thu Dec 11, 2025 5:57 pm

FourthWorld wrote:
Thu Dec 11, 2025 6:50 am
And a very nice review at that. Congrats.
I thought so too, plus they gave a feature request without realizing it ;)

Updated to 1.3.0 now with a password generator. Thanks to AndyP (of this forum) for allowing me to use his code.
https://github.com/emily-elizabeth/SecureText_LC

Post Reply