Ask Your Question
1

how password protect usb drive

asked 2013-09-30 15:32:47 -0500

seighalani gravatar image

hi everyone

how can i protect a usb drive (thunbnail drive) by password? is there any multiplatform solution? thanks in advance

edit retag flag offensive close merge delete

4 Answers

Sort by » oldest newest most voted
2

answered 2013-09-30 17:00:43 -0500

Gareth Jones gravatar image

updated 2013-09-30 20:24:31 -0500

LUKS is the native Linux method. It can be used in Windows with FreeOTF. There are other cross-platform methods like TrueCrypt.

Assuming that you know the device name (for this example, I’ll use /dev/sdb), to use LUKS:

# Be root.
cd /dev
su -        # Or “sudo -s”.

# Make sure that the device is not mounted.
umount sdb*

# Format the device for encryption.
cryptsetup luksFormat --cipher aes-xts-plain64 --hash sha512 --key-size 512 \
                      --use-random --verify-passphrase sdb
cryptsetup luksOpen sdb luks-sdb
shred -n 1 mapper/luks-sdb

# Create a file-system.
mkfs -t ext4 -L "FILE_SYSTEM_LABEL" mapper/luks-sdb         # Linux Ext4, or
mkfs -t ntfs -L "FILE_SYSTEM_LABEL" mapper/luks-sdb         # Windows NTFS.

# If using Ext4, make sure that you can write to it.
# Not needed for NTFS (unless you use NTFS-3G Windows–Linux user-mapping).
mount mapper/luks-sdb /mnt
chown your_user_name: /mnt
umount /mnt

# Clean up.
cryptsetup luksClose mapper/luks-sdb
sync

Then next time you plug the device into Fedora, you’ll be prompted for the pass-phrase, and your chosen FILE_SYSTEM_LABEL will be used to identify the device in the file manager. On Windows you’ll need FreeOTF, and one of the Ext4 drivers if you use Ext4 (recommended; see here for an Ext4 on Windows summary article).

I don’t know about TrueCrypt, but I’m sure someone else can tell you about that.

edit flag offensive delete link more

Comments

1

If you create a ext4 filesystem, it would be necessary to change the permissions (using chown) in order to use the usb drive as a regular user.

nonamedotc gravatar imagenonamedotc ( 2013-09-30 18:23:20 -0500 )edit

Good point nonamedotc. Answer updated.

Gareth Jones gravatar imageGareth Jones ( 2013-09-30 20:21:12 -0500 )edit
0

answered 2013-12-13 10:10:38 -0500

hmaarrfk gravatar image

You do NOT need the command line to achieve any of this in Fedora with Gnome Shell.

Try out the Disks utility (open up the overview and type 'disks' without the quotes).

From there, you will want to create a new LUKS partition.

Play around with it. Make sure you are selecting the right drive though :D.

edit flag offensive delete link more
0

answered 2013-12-17 23:01:42 -0500

seighalani gravatar image

thanks everyone

edit flag offensive delete link more
0

answered 2013-12-13 01:06:24 -0500

  1. Click right mouse to see if there is "bitlocker". If so, you can use this password protect your USB driver free.
  2. "TrueCrypt" is a good choice if you don't want to spend money and don't care complex .
  3. Use this folder protector: http://www.kakasoft.com/folder-protect/ , it's so easy but safety enough.
edit flag offensive delete link more

Question Tools

Stats

Asked: 2013-09-30 15:32:47 -0500

Seen: 1,879 times

Last updated: Dec 17 '13