{"id":3910,"date":"2021-01-28T16:31:45","date_gmt":"2021-01-28T16:31:45","guid":{"rendered":"https:\/\/linuxways.net\/?p=3910"},"modified":"2021-01-28T16:54:32","modified_gmt":"2021-01-28T16:54:32","slug":"how-to-install-and-use-veracrypt-on-ubuntu-20-04","status":"publish","type":"post","link":"https:\/\/linuxways.net\/de\/ubuntu\/how-to-install-and-use-veracrypt-on-ubuntu-20-04\/","title":{"rendered":"How to Install and Use Veracrypt on Ubuntu 20.04"},"content":{"rendered":"<p>If you do not want others to have access to your data, then encryption is essential. When you encrypt your sensitive data, unauthorized persons cannot easily get to it.<\/p>\n<p>This how-to guide focuses on the installation and basic usage of Veracrypt disk encryption software on Ubuntu Linux. Veracrypt is an open-source software and it is free.<\/p>\n<h2>Install Veracrypt<\/h2>\n<p>As seen on the official downloads page (link: https:\/\/www.veracrypt.fr\/en\/Downloads.html), two options are available for using Veracrypt on Ubuntu Linux, namely: GUI and console. GUI means graphical-based and console means text-based(command-line.)<\/p>\n<h3>Install Veracrypt: GUI<\/h3>\n<p>Run the following command in the Ubuntu terminal to download the Veracrypt GUI installer package.<\/p>\n<pre>$<strong> sudo wget https:\/\/launchpad.net\/veracrypt\/trunk\/1.24-update7\/+download\/veracrypt-1.24-Update7-Ubuntu-20.04-amd64.deb<\/strong><\/pre>\n<p>Now, you may install the downloaded package as follows.<\/p>\n<pre>$ <strong>sudo apt-get install .\/veracrypt-1.24-Update7-Ubuntu-20.04-amd64.deb<\/strong><\/pre>\n<p>Enter <strong>y<\/strong> to continue with the installation if prompted.<\/p>\n<p>After a successful installation, you can launch Veracrypt from the Applications menu &gt; Accessories &gt; Veracrypt.<\/p>\n<h3>Install Veracrypt: Console<\/h3>\n<p>Run the following command in the Ubuntu terminal to download the Veracrypt console installer package.<\/p>\n<pre>$ <strong>sudo wget https:\/\/launchpad.net\/veracrypt\/trunk\/1.24-update7\/+download\/veracrypt-console-1.24-Update7-Ubuntu-20.04-amd64.deb<\/strong><\/pre>\n<p>You may now proceed to install the downloaded package. Run the command below.<\/p>\n<pre>$ <strong>dpkg -i .\/veracrypt-console-1.24-Update7-Ubuntu-20.04-amd64.deb<\/strong><\/pre>\n<p>When the installation completes successfully, you may begin to use Veracrypt in the Ubuntu terminal. To see usage info, run the following command.<\/p>\n<pre>$ <strong>veracrypt -h<\/strong><\/pre>\n<h2>Encrypt Your Sensitive Data<\/h2>\n<p>Let us imagine that you have a folder named folder1 on your Ubuntu desktop which contains sensitive documents. We are going to create an encrypted volume via the GUI and the console to serve as a personal vault for storing such sensitive documents.<\/p>\n<h3>GUI Method:<\/h3>\n<h4>Create an encrypted volume<\/h4>\n<p>1. Launch Veracrypt from the <strong>Applications<\/strong> menu &gt; <strong>Accessories<\/strong> &gt; <strong>Veracrypt<\/strong><\/p>\n<p>2.\u00a0 Click <strong>Create<\/strong><\/p>\n<p>3.\u00a0 In the Veracrypt volume creation wizard, choose <strong>Create an encrypted file container<\/strong><\/p>\n<p>4.\u00a0 Click <strong>Next<\/strong><\/p>\n<p><strong><img loading=\"lazy\" decoding=\"async\" width=\"791\" height=\"493\" class=\"wp-image-3911\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-485.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-485.png 791w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-485-300x187.png 300w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-485-768x479.png 768w\" sizes=\"auto, (max-width: 791px) 100vw, 791px\" \/><\/strong><\/p>\n<p><strong>Figure 1: <\/strong>Create an encrypted file container<\/p>\n<p>5.\u00a0 On the Volume Type page, choose the first option labeled<strong> Standard Veracrypt volume<\/strong><\/p>\n<p>6.\u00a0 Click<strong> Next<\/strong><\/p>\n<p>7.\u00a0 Under Volume Location, click <strong>Select File<\/strong><\/p>\n<p>8.\u00a0 Choose your desired location on the left and then enter a name for the encrypted file container at the top<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"687\" height=\"173\" class=\"wp-image-3912\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-486.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-486.png 687w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-486-300x76.png 300w\" sizes=\"auto, (max-width: 687px) 100vw, 687px\" \/><\/p>\n<p><strong>Figure 2:<\/strong> Name your new encrypted file container<\/p>\n<p>9.\u00a0 Click <strong>Save<\/strong> at the bottom of the window<\/p>\n<p>10.\u00a0 Back to the Volume Location page, click <strong>Next<\/strong><\/p>\n<p>11.\u00a0 Under Encryption Options, leave the default selections: AES and SHA-512, and click<strong> Next<\/strong><\/p>\n<p>12.\u00a0 Under Volume Size, enter the desired volume size. Click the drop-down menu to switch between Gigabytes, Megabytes and Kilobytes<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"547\" height=\"271\" class=\"wp-image-3913\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-487.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-487.png 547w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-487-300x149.png 300w\" sizes=\"auto, (max-width: 547px) 100vw, 547px\" \/><\/p>\n<p><strong>Figure 3:<\/strong> Specify the size of the encrypted file container<\/p>\n<p>13.\u00a0 Click <strong>Next<\/strong><\/p>\n<p>14.\u00a0 Under Volume Password, enter an encryption password<\/p>\n<p>15.\u00a0 Click <strong>Next<\/strong><\/p>\n<p>16.\u00a0 Under Format Options, you may choose Linux Ext3 from the drop-down menu<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"547\" height=\"285\" class=\"wp-image-3914\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-488.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-488.png 547w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-488-300x156.png 300w\" sizes=\"auto, (max-width: 547px) 100vw, 547px\" \/><\/p>\n<p><strong>Figure 4:<\/strong> Choose filesystem type for the encrypted volume<\/p>\n<p>17.\u00a0 Click <strong>Next<\/strong><\/p>\n<p>18.\u00a0 Under Cross-Platform Support, let us go with the default selection<\/p>\n<p>19.\u00a0 Click <strong>Next <\/strong>and then click <strong>OK<\/strong> when prompted<\/p>\n<p>20.\u00a0 Under Volume Format, begin to move your mouse randomly for at least 1 minute<\/p>\n<p><strong><img loading=\"lazy\" decoding=\"async\" width=\"541\" height=\"493\" class=\"wp-image-3915\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-489.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-489.png 541w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-489-300x273.png 300w\" sizes=\"auto, (max-width: 541px) 100vw, 541px\" \/><\/strong><\/p>\n<p><strong>Figure 5:<\/strong> Move your mouse randomly<\/p>\n<p>21.\u00a0 When you are done, click <strong>Format<\/strong><\/p>\n<p>22.\u00a0 When prompted, enter your Linux user password and click <strong>OK<\/strong><\/p>\n<p>23.\u00a0 Wait for a message indicating that your Veracrypt volume was successfully created<\/p>\n<p>24.\u00a0 Click <strong>OK<\/strong><\/p>\n<p>25.\u00a0 Click <strong>Exit<\/strong><\/p>\n<h4>Mount the encrypted volume<\/h4>\n<p>1.\u00a0 Back to the main VeraCrypt window, click any free slot in the list<\/p>\n<p>2.\u00a0 Click <strong>Select File<\/strong><\/p>\n<p>3.\u00a0 Choose the encrypted file container which you created earlier<\/p>\n<p>4.\u00a0 Click <strong>Open<\/strong> at the bottom of the Window<\/p>\n<p>5.\u00a0 Click <strong>Mount<\/strong><\/p>\n<p><strong><img loading=\"lazy\" decoding=\"async\" width=\"637\" height=\"229\" class=\"wp-image-3916\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-490.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-490.png 637w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-490-300x108.png 300w\" sizes=\"auto, (max-width: 637px) 100vw, 637px\" \/><\/strong><\/p>\n<p><strong>Figure 6: <\/strong>Mount encrypted volume<\/p>\n<p>6.\u00a0 When prompted, enter your encryption password and click <strong>OK<\/strong><\/p>\n<p>7.\u00a0 You should now see a new device icon on your desktop<\/p>\n<p>The mounted device will also be listed under <strong>Devices<\/strong> when you open File Manager by accessing your home directory for instance. Figure 7 below shows the default mount directory path.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"639\" height=\"207\" class=\"wp-image-3917\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-491.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-491.png 639w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-491-300x97.png 300w\" sizes=\"auto, (max-width: 639px) 100vw, 639px\" \/><\/p>\n<p><strong>Figure 7:<\/strong> Encrypted volume mount directory path<\/p>\n<p>You may now proceed to move your sensitive folder into your personal vault.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"643\" height=\"283\" class=\"wp-image-3918\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-492.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-492.png 643w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-492-300x132.png 300w\" sizes=\"auto, (max-width: 643px) 100vw, 643px\" \/><\/p>\n<p><strong>Figure 8:<\/strong> Mounted volume listed under devices<\/p>\n<h4>Dismount the encrypted volume<\/h4>\n<p>1.\u00a0 To dismount the encrypted volume, make sure that the appropriate slot is selected in the main Veracrypt window<\/p>\n<p>2.\u00a0 Click <strong>Dismount<\/strong><\/p>\n<p>3.\u00a0 The slot entry should now be blank<\/p>\n<p>4.\u00a0 Also, you should no longer see the encrypted volume on your desktop or listed under <strong>Devices<\/strong><\/p>\n<p><strong><img loading=\"lazy\" decoding=\"async\" width=\"631\" height=\"227\" class=\"wp-image-3919\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-493.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-493.png 631w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/01\/word-image-493-300x108.png 300w\" sizes=\"auto, (max-width: 631px) 100vw, 631px\" \/><\/strong><\/p>\n<p><strong>Figure 9: <\/strong>Dismount encrypted volume<\/p>\n<h3>Console Method:<\/h3>\n<h4>Create an encrypted volume<\/h4>\n<p>Run the command below in the Ubuntu terminal to begin creating your encrypted volume.<\/p>\n<pre>$ <strong>veracrypt --create<\/strong><\/pre>\n<p>When prompted to choose a volume type, enter <strong>1<\/strong> for a Normal volume<\/p>\n<table>\n<tbody>\n<tr>\n<td>\n<p>Volume type:<\/p>\n<p>1) Normal<\/p>\n<p>2) Hidden<\/p>\n<p>Select [1]: <strong>1<\/strong><\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>Next, you would be prompted to enter volume path and volume size. In the example below, the encrypted volume is called personal_vault and will be created in my home directory. The size of the personal vault will be 2 Gigabytes.<\/p>\n<table>\n<tbody>\n<tr>\n<td>\n<p>Enter volume path: <strong>\/home\/shola\/personal_vault<\/strong><\/p>\n<p>Enter volume size (sizeK\/size[M]\/sizeG): <strong>2G<\/strong><\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>For encryption algorithm and hash algorithm, the default AES and SHA-512 values are recommended. Enter <strong>1<\/strong> in both cases.<\/p>\n<table>\n<tbody>\n<tr>\n<td>\n<p>Encryption Algorithm:<\/p>\n<p>1) AES<\/p>\n<p>2) Serpent<\/p>\n<p>3) Twofish<\/p>\n<p>4) Camellia<\/p>\n<p>5) Kuznyechik<\/p>\n<p>6) AES(Twofish)<\/p>\n<p>7) AES(Twofish(Serpent))<\/p>\n<p>8) Camellia(Kuznyechik)<\/p>\n<p>9) Camellia(Serpent)<\/p>\n<p>10) Kuznyechik(AES)<\/p>\n<p>11) Kuznyechik(Serpent(Camellia))<\/p>\n<p>12) Kuznyechik(Twofish)<\/p>\n<p>13) Serpent(AES)<\/p>\n<p>14) Serpent(Twofish(AES))<\/p>\n<p>15) Twofish(Serpent)<\/p>\n<p>Select [1]: <strong>1<\/strong><\/p>\n<p>Hash algorithm:<\/p>\n<p>1) SHA-512<\/p>\n<p>2) Whirlpool<\/p>\n<p>3) SHA-256<\/p>\n<p>4) Streebog<\/p>\n<p>Select [1]: <strong>1<\/strong><\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>For filesystem, Linux Ext3 would suffice. You may enter <strong>4<\/strong> to choose that.<\/p>\n<table>\n<tbody>\n<tr>\n<td>\n<p>Filesystem:<\/p>\n<p>1) None<\/p>\n<p>2) FAT<\/p>\n<p>3) Linux Ext2<\/p>\n<p>4) Linux Ext3<\/p>\n<p>5) Linux Ext4<\/p>\n<p>6) NTFS<\/p>\n<p>7) exFAT<\/p>\n<p>8) Btrfs<\/p>\n<p>Select [2]: <strong>4<\/strong><\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>Now, it is time to choose a strong encryption password. You will get a warning if your chosen password is determined to be weak.<\/p>\n<p><strong>Note: <\/strong>Using a short password is NOT recommended.<\/p>\n<table>\n<tbody>\n<tr>\n<td>\n<p>Enter password:<\/p>\n<p>WARNING: Short passwords are easy to crack using brute force techniques!<\/p>\n<p>We recommend choosing a password consisting of 20 or more characters. Are you sure you want to use a short password? (y=Yes\/n=No) [No]: <strong>y<\/strong><\/p>\n<p>Re-enter password:<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>When you are prompted to enter PIM, press the enter key on your keyboard to accept the default value. Do the same when you are prompted to enter the keyfile path.<\/p>\n<p>PIM is a number that specifies how many times your password is hashed. A keyfile is used alongside a password, such that any volume that uses the keyfile cannot be mounted if the correct keyfile is not provided. As we are focusing on basic usage here, the default values would suffice.<\/p>\n<table>\n<tbody>\n<tr>\n<td>\n<p>Enter PIM:<\/p>\n<p>Enter keyfile path [none]:<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>Finally, you would need to randomly type on the keyboard for at least 1 minute and quite fast too. This is supposed to make the encryption stronger. Avoid the enter key while you type. Press Enter only when you are done typing and then wait for the encrypted volume to be created.<\/p>\n<table>\n<tbody>\n<tr>\n<td>\n<p>Please type at least 320 randomly chosen characters and then press Enter:<\/p>\n<p>Done: 100% Speed: 33 MiB\/s Left: 0 s<\/p>\n<p>The VeraCrypt volume has been successfully created.<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Mount the encrypted volume<\/h4>\n<p>To access the content of the encrypted volume, you need to first mount it. The default mount directory is \/media\/veracrypt1 but you can create yours if you wish.<\/p>\n<p>For example, the following command will create a mount directory under \/mnt.<\/p>\n<pre>$ <strong>sudo mkdir \/mnt\/personal_vault<\/strong><\/pre>\n<p>The next command below will begin mounting the encrypted volume.<\/p>\n<pre>$<strong> veracrypt --mount \/home\/shola\/personal_vault<\/strong><\/pre>\n<p>When you are prompted, either press the enter key to use the default mount directory or type your own mount directory path. You would be prompted to enter your encryption password next. For PIM, keyfile and protect hidden volume prompts, hit the enter key to use the default values.<\/p>\n<table>\n<tbody>\n<tr>\n<td>\n<p>Enter mount directory [default]: <strong>\/mnt\/personal_vault<\/strong><\/p>\n<p>Enter password for \/home\/shola\/personal_vault:<\/p>\n<p>Enter PIM for \/home\/shola\/personal_vault:<\/p>\n<p>Enter keyfile [none]:<\/p>\n<p>Protect hidden volume (if any)? (y=Yes\/n=No) [No]:<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>Run the following command to list mounted volumes.<\/p>\n<pre>$<strong> veracrypt --list<\/strong><\/pre>\n<table>\n<tbody>\n<tr>\n<td>\n<p>1: \/home\/shola\/personal_vault \/dev\/mapper\/veracrypt1 \/mnt\/personal_vault<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>You may now move your sensitive folder to your personal vault as follows.<\/p>\n<pre>$ <strong>sudo<\/strong> <strong>mv \/home\/shola\/folder1 \/mnt\/personal_vault<\/strong><\/pre>\n<p>To list the contents of your personal vault, run:<\/p>\n<pre>$ <strong>ls -l \/mnt\/personal_vault<\/strong><\/pre>\n<h4>Dismount the encrypted volume<\/h4>\n<p>The following command will dismount the encrypted volume.<\/p>\n<pre>$ <strong>veracrypt --dismount \/mnt\/personal_vault<\/strong><\/pre>\n<p>If you run <strong>veracrypt &#8211;list<\/strong> again, you should get a message indicating that no volume is mounted.<\/p>\n<h2>Conclusion<\/h2>\n<p>Veracrypt has some very advanced capabilities but we only covered the basics in this article. Feel free to share your experiences with us in the comments section.<\/p>\n\n\n<p><\/p>","protected":false},"excerpt":{"rendered":"<p>If you do not want others to have access to your data, then encryption is essential. When you encrypt your sensitive data, unauthorized persons cannot easily get to&hellip;<\/p>","protected":false},"author":28,"featured_media":3921,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2],"tags":[100,163],"class_list":["post-3910","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-ubuntu","tag-ubuntu-20-04","tag-veracrypt"],"_links":{"self":[{"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/posts\/3910","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/users\/28"}],"replies":[{"embeddable":true,"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/comments?post=3910"}],"version-history":[{"count":0,"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/posts\/3910\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/media\/3921"}],"wp:attachment":[{"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/media?parent=3910"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/categories?post=3910"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/tags?post=3910"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}