Posted: . At: 1:18 PM. This was 2 years ago. Post ID: 16575
Page permalink. WordPress uses cookies, or tiny pieces of information stored on your computer, to verify who you are. There are cookies for logged in users and for commenters.
These cookies expire two weeks after they are set.



Sponsored



How to create a simple encrypted message using the command line on Linux.


How to create a simple encrypted message using the command line on Linux.

The example below is how to create a simple encrypted file using the command line on Linux. This uses OpenSSL to encrypt a stream of text into a text file, this contains AES-256 encrypted text using a passkey to allow access.

jason@jason-Lenovo-H50-55:~$ ls -hula --sort=size | head -n 8 | openssl enc -e -aes-256-cbc -a -iter 8 > me2.sl
enter aes-256-cbc encryption password:
Verifying - enter aes-256-cbc encryption password:

To decrypt the file, this is how you do it.

jason@jason-Lenovo-H50-55:~$ cat me2.sl | openssl enc -d -aes-256-cbc -a -iter 8
enter aes-256-cbc decryption password:
total 20M
-rw-rw-r--  1 jason jason  16M Sep 15  2020 annex.Altis.pbo
-rwxrwxr-x  1 jason jason 1.7M Jul 23  2020 youtube-dl
-rw-rw-r--  1 jason jason 1.3M Mar  5 14:30 SAMSUNG_LEAK.torrent
-rw-rw-r--  1 jason jason 779K Oct  3  2020 MP_Warlords_01_large.Altis.pbo
-rw-------  1 jason jason  98K Aug 22 10:05 .bash_history
-rw-r--r--  1 jason jason  21K Jul 27 08:40 .xorgxrdp.11.log
-rw-r--r--  1 jason jason  20K Apr 18 09:46 .xorgxrdp.10.log

This is a simple way to transfer encrypted messages, the only problem is how to share the passkey securely. But this is the only issue. And this is best left up to the reader. Unless you agreed on one beforehand or had a favourite saying or something and the passkey could be guessed from that. But this is not impossible.

Simpsons computer users.
Simpsons computer users.

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.