Instructions on how to encrypt files and folders on Ubuntu

Ubuntu possesses many advanced security features that users may not know about. For example, LibreOffice users can encrypt files and folders on Ubuntu extremely simply but extremely securely. So what is that feature and how to use it on Ubuntu for files and folders?

If you are familiar with Ubuntu, you will see that there are many things on Ubuntu that are many times better than Windows 7 and 10. Of course we are not talking about games because there is no operating system better suited for gaming than Windows. However, the way to encrypt files and folders on Ubuntu is different. On Ubuntu there are many security methods to help you protect your privacy to the maximum.

Instructions for encrypting files and folders on Ubuntu

Step 1: To encrypt files and folders on Ubuntu, we first need to install Gnupg on Ubuntu, download Gnupg here.

Picture 1 of Instructions on how to encrypt files and folders on Ubuntu

Step 2: Click on the Gnupg folder to extract it on Ubuntu.

Picture 2 of Instructions on how to encrypt files and folders on Ubuntu

Step 3: Continue clicking Install to install this software on Ubuntu. After installation is complete you can close it.

Picture 3 of Instructions on how to encrypt files and folders on Ubuntu

Step 4: In case you cannot install Gnupg, press the key combination Ctrl + ALT + T to open the Terminal window, here you type: sudo apt install gnupg2

Picture 4 of Instructions on how to encrypt files and folders on Ubuntu

Type the password before confirming the installation. When typing the password, the characters will not appear.

Picture 5 of Instructions on how to encrypt files and folders on Ubuntu

Step 5: If the system asks if you want to continue> press Y then enter to continue the installation.

Picture 6 of Instructions on how to encrypt files and folders on Ubuntu

Step 6: After installation is complete, to see the list of encryption methods, run the command below: gpg2 --version

Picture 7 of Instructions on how to encrypt files and folders on Ubuntu

The AES algorithm in this list is AES128 . You can select another encryption algorithm as the default by adding a line to configure the file that GnuPG uses when running. The configuration file is called gpg.conf, located in a hidden folder called .gnupg in the Home directory.

Picture 8 of Instructions on how to encrypt files and folders on Ubuntu

Step 7: The next step now is to edit the configuration file in gedit, run the command below in the Terminal window: gedit -/.gnupg/gpg.conf

Picture 9 of Instructions on how to encrypt files and folders on Ubuntu

Step 8: When it opens, type ciphe - algo AES256 and save it.

Picture 10 of Instructions on how to encrypt files and folders on Ubuntu

Step 9: Now we start encrypting files and folders on Ubuntu, for example encrypting with file -/Documents/Taimienphi.vn/Taimienphi.vn.txt

Picture 11 of Instructions on how to encrypt files and folders on Ubuntu

>> Type the command gpg --symmetric --cipher-algo AES256 -/Documents/Taimienphi.vn/Taimienphi.vn.txt

Picture 12 of Instructions on how to encrypt files and folders on Ubuntu

Then enter the password twice to confirm the password for that encrypted file.

Picture 13 of Instructions on how to encrypt files and folders on Ubuntu

Step 10: After encrypting files and folders on Ubuntu, we can add a password to that encrypted file with the command gpg --symmetric -/Documents/Taimienphi.vn/Taimienphi.vn.txt

Picture 14 of Instructions on how to encrypt files and folders on Ubuntu

Step 11: Then enter the password to complete the process of encrypting files and folders on Ubuntu.

Picture 15 of Instructions on how to encrypt files and folders on Ubuntu

Inside the encrypted folder, you will now see another file appear with the *gpg extension, which means the encryption of Files and folders on Ubuntu has been completed.

Picture 16 of Instructions on how to encrypt files and folders on Ubuntu

Step 12: To rename the encrypted file, type the command gpg -o Taimienphivn.enc --symmetric -/Documents/Taimienphi.vn/Taimienphi.vn.txt

Where > Taimienphivn.enc is the new file name.

>>Taimienphi.vn.txt is the original file name.

Picture 17 of Instructions on how to encrypt files and folders on Ubuntu

Above is all the information that users need to know when researching file and folder encryption on Ubuntu. With the instructions for encrypting files and folders on Ubuntu, we can encrypt files ourselves as desired. And there are many other tips we want to share with you about Ubuntu, but TipsMake would like to see you in the next articles on the TipsMake page.


With the above trick, we know another way to encrypt data in Ubuntu. Indeed, data encryption is not as simple as Windows, but in terms of security features, it is not inferior. One thing to note is that readers must check the version of Ubuntu they are using because not all versions support it. To avoid having to check the Ubuntu version , another way is to always update it to the latest version.

Update 16 June 2024
Category

System

Mac OS X

Hardware

Game

Tech info

Technology

Science

Life

Application

Electric

Program

Mobile