This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
doublequestionmark's profile picture

EncryptFS -- Secure Full Disk Encryption For ComputerCraft

Started by doublequestionmark, 23 May 2016 - 10:51 PM
doublequestionmark #1
Posted 24 May 2016 - 12:51 AM
EncryptFS

Encrypt all the things


Protecting your computer with a password is great and all, but that doesn't work to well against floppy disks.
What if there was a way to protect your computer AND the files on it? Meet EncryptFS.

EncryptFS automatically encrypts/decrypts in memory whenever they are written/read (using SquidDev's implementation of AES)

How does it work?EncryptFS overwrites the fs api, specifically fs.open(), to allow for on the fly encryption/decryption.

When you first run EncryptFS, you will be prompted for a passphrase. This passphrase will be used to encrypt a short string and that string will be saved to a file (.encryptfs). When you boot the computer, you will be prompted for the passphrase established earlier. This passphrase will be used to decrypt .encryptfs and, if the original string is returned, continue boot and encrypt/decrypt files as needed on the fly.

The passphrase is never written to a file

When a program calls fs.open(), EncryptFS will decrypt the requested file (keeping the plain-text copy in memory) and pass it to the caller. When a program writes to a file, EncryptFS will automatically encrypt the file.

Note: Plain-Text versions of files are never written to a file, only kept in memory


Screenshots






Download:

pastebin get MFFkEXfD startup
Edited on 09 July 2016 - 06:27 PM
thecrimulo #2
Posted 18 July 2016 - 01:15 AM
I like it! Is there any way this can be an API so it can be just called as a function in startup? I mean, no interface. It would be really cool, since it'll integrate in the startup file instead of replacing it.
doublequestionmark #3
Posted 18 July 2016 - 02:17 AM
I like it! Is there any way this can be an API so it can be just called as a function in startup? I mean, no interface. It would be really cool, since it'll integrate in the startup file instead of replacing it.
OK, I've made a slight modification, and you should be able to call it with os.loadAPI("[filename]") without it overwriting the startup file
Edited on 18 July 2016 - 12:27 AM
Xerxes #4
Posted 18 July 2016 - 02:31 AM
This is very cool. It reminds me a lot of TrueCrypt, and it seems to work very well.
Mumbai #5
Posted 18 July 2016 - 09:06 PM
Broken at CC 1.7. Weird.
doublequestionmark #6
Posted 18 July 2016 - 09:07 PM
Broken at CC 1.7. Weird.

Is it giving an error?
Mumbai #7
Posted 18 July 2016 - 09:19 PM
NEver mind! Originally it stated

startup : attempting to index nil

This occured after I typed in the wrong pass

Now it works fine…Weird.