From 04fdbecc1a749c648f170d3c91f16548725ddf4a Mon Sep 17 00:00:00 2001 From: Nathan Christopher McRae Date: Sun, 23 Nov 2025 12:51:48 -0800 Subject: [PATCH] Add readme example and some TODOs --- readme.txt | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/readme.txt b/readme.txt index 2734ab6..8a6139b 100644 --- a/readme.txt +++ b/readme.txt @@ -2,6 +2,44 @@ This simple script takes a file as an argument and prompts the user for a messag To verify that your message applies to the file they recieved, your recipient(s) would verify your signature of the script, and then run it (or merely inspect it if they don't trust you too much) which will confirm their file matches the one you wrote the message about. +Example: + +I have a file foo.txt, so I run (): + +`create-file-message.sh webpage.htm` + +When prompted, enter the message to associate with the file. + +Then sign the resulting webpage.htm.sh file + +`gpg --sign webpage.htm.sh` + +You will then have the following files which should be distributed together: + +* webpage.htm +* webpage.htm.sh +* webpage.htm.sh.sig + +Whoever wants to validate the file and the message will first import your public key, then they validate webpage.htm` + +When prompted, enter the message to associate with the file. + +Then sign the resulting webpage.htm.sh file + +`gpg --sign webpage.htm.sh` + +You will then have the following files which should be distributed together: + +* webpage.htm +* webpage.htm.sh +* webpage.htm.sh.sig + +Whoever wants to validate the file and the message will first import your public key, then they verify the script file with `gpg --verify webpage.htm.sh`, finally they run `./webpage.htm.sh` which will check whether the target file matches the stored hash and if so will display the message. + +TODO: example of making it a function in your profile + +TODO: guix package + Motivation: Signing a file typically means "I authored this", but sometimes you want to sign something else, for example to indicate that you retrieved something on a given date.