Regardless of the motivation, sometimes you need an encrypted space to hide stuff and things. Linux has some fairly advanced disk encryption abilities provided by the dm-crypt module. dm-crypt is part of the device mapper suite that is more commonly associated with LVM. I’m assuming that you want to encrypt the first partition of your sdb disk for this tip and that you want to use AES encryption.
First, create the encrypted device.
cryptsetup -y create vault /dev/sdb1
You’ll be prompted to enter a passphrase twice. Next, put a file system on that device.
mkfs.ext3 /dev/mapper/vault
and lastly, mount it and use it!
dmsetup remove /dev/mapper/vault
Subsequent mounts will prompt you for a password. It really was just that simple. Enjoy!