VeraCrypt is free open-source disk encryption software. I use it predominantly for encrypting data on portable devices (see Backups for more details).
Installation
Arch Linux:
sudo pacman -S veracryptOther distributions: Download from https://veracrypt.io/en/Downloads.html
Usage
Create an encrypted volume
veracrypt -cFollow the interactive prompts to:
- Choose volume type (normal or hidden)
- Select volume location (file or device)
- Pick encryption algorithm (AES recommended)
- Set volume size
- Create password
Mount a volume
# Mount to /mnt/veracrypt1 (default slot 1)
veracrypt /path/to/volume /mnt/veracrypt1
# Mount with specific slot
veracrypt --slot=2 /path/to/volume /mnt/veracrypt2Dismount
# Dismount specific volume
veracrypt -d /mnt/veracrypt1
# Dismount all
veracrypt -dCommon Options
| Option | Description |
|---|---|
-c | Create new volume |
-d | Dismount |
--slot=N | Use slot N (1-64) |
-t | Text mode (no GUI) |
--non-interactive | For scripts |
-p PASSWORD | Provide password (insecure, avoid) |
Portable Drive Setup
For encrypted USB drives:
- Create a file-hosted volume on the drive
- Copy the portable VeraCrypt binary to the drive
- Now usable on any machine without installation
Tips
- Use keyfiles for additional security (combine with password)
- For full disk encryption on Linux, consider LUKS instead
- Hidden volumes provide plausible deniability
- Always safely eject before removing portable drives