Sponsored Content
Top Forums UNIX for Dummies Questions & Answers How to use GPG for myself on Thumb drive? Post 302249725 by siegfried on Wednesday 22nd of October 2008 01:44:14 AM
Old 10-22-2008
How to use GPG for myself on Thumb drive?

I have some sensitive data I would like to keep on a thumb drive.

Now I know this is a UNIX/Linux forum and I regret to say that I'm using windows but I'm hoping that is irrelevant.

So I install gpg on both windows machines: one at home and the other at work.

I encrypt some stuff on the home machine, export the keys and go to work and import the keys. No errors. But then I try to decrypt the data file and no luck: it did not even prompt me for my passphrase!
What do I have to do to be able to read my encrypted file at work?

Also: should I be concerned about piping the decrypted output from gpg to a hard drive where someone at the recycling center could eventually scavenge the disk. I was going to pipe it to the thumb drive but then I realized if I ever lost my thumb drive, someone could scavenge the decrypted deleted file?

So what can I do? Have a special thumb drive just for holding the deleted and decrypted data that I eventually destroy? Or maybe one cannot scavenge flash memory?

Thanks,
Siegfried
 

9 More Discussions You Might Find Interesting

1. What is on Your Mind?

USB Thumb Drives

I'm hunting around for thumb drives that aren't working. Something you may have kicking around in a drawer that you don't need any more. One you've upgraded and just don't need. I'm willing to pay a couple bucks for you to drop it into an envelope with a few stamps and send it along. I'm... (0 Replies)
Discussion started by: BOFH
0 Replies

2. UNIX for Dummies Questions & Answers

Gpg

Hi, I have imported the details given by my friend using gpg --import <file> Now i am using the encryption technique with my friend's key in the following way: gpg --output out.pgp --batch --encrypt --recipient "FRIEND_KEY" test and i am getting the follwoing error: gpg: 421E287E:... (4 Replies)
Discussion started by: risshanth
4 Replies

3. SCO

Occasional Core Dump with hot swap USB Thumb Drive

Hello Unix World, I've been having this issue for the longest time. Here is my setup OS: SCO OpenServer 6.0 with mp4, mp3 Server: Dell PowerEdge 840, 800, 2900 USB Stick: Patriot 16GB High Speed, and many other different brands. Occasinaly while system is running and USB is pluged in the... (0 Replies)
Discussion started by: miles556
0 Replies

4. Shell Programming and Scripting

Cannot see GPG installation

Hello all I have installed gpg key be executing command gpg --gen-key and followed the on screen prompts. I have done all this stuff from my home directory Now i am unable to see the results. Where are these keys stored. Doesn't it create a new folder in my home directory and create the... (1 Reply)
Discussion started by: vasuarjula
1 Replies

5. Solaris

Rule of the thumb for swap?

Hi, The general rule of thumb for assigning swap is double the RAM of the server, however, there are servers with 16GB or 32GB of RAM. Are we suppose to put aside 32GB and 64GB of swap respectively. Thanks (4 Replies)
Discussion started by: Mack1982
4 Replies

6. UNIX for Dummies Questions & Answers

How to move a directory from thumb drive to mac?

I do some scripting during lunch on the macbookpro at work. I have the necessary folders on a thumb drive from my mac at home, and move them with the mv command to the mbpro so I don't have to change the script itself to access the necessary files on the thumb drive, and then change the code again... (13 Replies)
Discussion started by: Straitsfan
13 Replies

7. Shell Programming and Scripting

Need help on File Encryption using gpg

Folks, Is there anyone to help on GPG file encryptions here. I got a public key from third party. I imported the key in server. I want to encrypt the public key. But without being signed , the key cannot be encrypted. When I try to sign the key using lsign command, I am getting the below... (1 Reply)
Discussion started by: dinesh1985
1 Replies

8. UNIX and Linux Applications

Using gpg

I am trying to use gig in linux but it is hanging. $ gpg --passphrase=test /tmp/test.sh Reading passphrase from file descriptor 0 ... When i press enter, it gives the below message: $ gpg --passphrase=test /tmp/test.sh Reading passphrase from file descriptor 0 ... gpg: no valid... (1 Reply)
Discussion started by: tcssk
1 Replies

9. Shell Programming and Scripting

PL/SQL stored proc from ksh just inserts thumb and does nothing

Greeting everyone. Ok, I have spent the past few days googling for this and I keep hitting a wall. Many results brought me here, but the solutions were not quite right for this. Basically my script (ksh) is run with an arg for a csv. My script so far appears to be storing the values from my... (4 Replies)
Discussion started by: dezdiggler
4 Replies
AESPIPE(1)                                                           COMMANDS                                                           AESPIPE(1)

NAME
aespipe - AES encrypting or decrypting pipe SYNOPSIS
aespipe [options] <inputfile >outputfile DESCRIPTION
aespipe reads from standard input and writes to standard output. It can be used to create and restore encrypted tar or cpio archives. It can be used to encrypt and decrypt loop-AES compatible encrypted disk images. aespipe encrypts and decrypts blocks of data. If you are looking for general purpose encrypting tool that preserves data size at byte granularity, then please take a look at GnuPG. The AES cipher is used in CBC (cipher block chaining) mode. Data is encrypted and decrypted in 512 byte chains. aespipe supports three key setup modes; single-key, multi-key-v2 and multi-key-v3 modes. Single-key mode uses simple sector IV and one AES key to encrypt and decrypt all data sectors. Multi-key-v2 mode uses cryptographically more secure MD5 IV and 64 different AES keys to encrypt and decrypt data sec- tors. In multi-key mode first key is used for first sector, second key for second sector, and so on. Multi-key-v3 is same as multi-key-v2 except is uses one extra 65th key as additional input to MD5 IV computation. See -K option for more information about how to enable multi- key-v3 mode. Recommended key setup mode is multi-key-v3, which is based on gpg encrypted key files. In this mode, the passphrase is protected against optimized dictionary attacks via salting and key iteration of gpg. Passphrase length should be 20 characters or more. Single-key mode preserves input size at 16 byte granularity. Multi-key mode preserves input size at 512 byte granularity. If input size is not multiple of 16 or 512 bytes, input data is padded with null bytes so that both input and output sizes are multiples of 16 or 512 bytes. If "ulimit -l" is set to "unlimited" then aespipe attempts to lock its RAM so that encryption keys do not leak to unencrypted swap. If "ulimit -l" is something other than "unlimited" then aespipe will proceed without locked RAM. OPTIONS
-A gpgAgentSocket Read passphrase of gpg encrypted key file from gpg-agent instead of the terminal. aespipe runs gpg to decrypt a key file, and gpg talks to gpg-agent using gpgAgentSocket. Usually this data is in GPG_AGENT_INFO environment variable. The environment that is passed to gpg is very minimal. Normally gpg passes some environment variables to gpg-agent, but in this case, there aren't any. For best results, you may want to configure gpg-agent so that it "keeps" and uses its own environment. Defining "keep-tty", "keep-display" and "pinentry-program" in $HOME/.gnupg/gpg-agent.conf configuration file is a good start. -C itercountk Runs hashed passphrase through itercountk thousand iterations of AES-256 before using it for data encryption. This consumes lots of CPU cycles at program start time but not thereafter. In combination with passphrase seed this slows down dictionary attacks. Itera- tion is not done in multi-key mode. -d Decrypt data. If this option is not specified, default operation is to encrypt data. -e encryption Following encryption types are recognized: AES128 (default), AES192 and AES256. Encryption type names are case insensitive. AES128 defaults to using SHA-256 passphrase hash, AES192 defaults to using SHA-384 passphrase hash, and AES256 defaults to using SHA-512 passphrase hash. -G gpghome Set gpg home directory to gpghome, so that gpg uses public/private keys on gpghome directory. This is only used when gpgkey file needs to be decrypted using public/private keys. If gpgkey file is encrypted with symmetric cipher only, public/private keys are not required and this option has no effect. -H phash Uses phash function to hash passphrase. Available hash functions are sha256, sha384, sha512 and rmd160. unhashed1 and unhashed2 functions also exist for compatibility with some obsolete implementations. Hash type names are case insensitive. -K gpgkey Passphrase is piped to gpg so that gpg can decrypt file gpgkey which contains the real keys that are used to encrypt data. If decryption requires public/private keys and gpghome is not specified, all users use their own gpg public/private keys to decrypt gpgkey. Decrypted gpgkey should contain 1 or 64 or 65 keys, each key at least 20 characters and separated by newline. If decrypted gpgkey contains 64 or 65 keys, then aespipe is put to multi-key mode. 65th key, if present, is used as additional input to MD5 IV computation. -O sectornumber Set IV offset in 512 byte units. Default is zero. Data is encrypted in 512 byte CBC chains and each 512 byte chain starts with IV whose computation depends on offset within the data. This option can be used to start encryption or decryption in middle of some existing encrypted disk image. -p fdnumber Read the passphrase from file descriptor fdnumber instead of the terminal. If -K option is not being used (no gpg key file), then aespipe attempts to read 65 keys from passwdfd, each key at least 20 characters and separated by newline. If aespipe successfully reads 64 or 65 keys, then aespipe is put to multi-key mode. If aespipe encounters end-of-file before 64 keys are read, then only first key is used in single-key mode. -P cleartextkey Read the passphrase from file cleartextkey instead of the terminal. If -K option is not being used (no gpg key file), then aespipe attempts to read 65 keys from cleartextkey, each key at least 20 characters and separated by newline. If aespipe successfully reads 64 or 65 keys, then aespipe is put to multi-key mode. If aespipe encounters end-of-file before 64 keys are read, then only first key is used in single-key mode. If both -p and -P options are used, then -p option takes precedence. These are equivalent: aespipe -p3 -K foo.gpg -e AES128 ... 3<someFileName aespipe -P someFileName -K foo.gpg -e AES128 ... In first line of above example, in addition to normal open file descriptors (0==stdin 1==stdout 2==stderr), shell opens the file and passes open file descriptor to started aespipe program. In second line of above example, aespipe opens the file itself. -q Be quiet and don't complain about write errors. -S pseed Sets encryption passphrase seed pseed which is appended to user supplied passphrase before hashing. Using different seeds makes dic- tionary attacks slower but does not prevent them if user supplied passphrase is guessable. Seed is not used in multi-key mode. -T Asks passphrase twice instead of just once. -v Verbose mode. Prints diagnostics to stderr about key length, single/multi key mode, and selected code optimizations (x86/amd64/pad- lock/intelaes). -w number Wait number seconds before asking passphrase. RETURN VALUE
aespipe returns 0 on success, nonzero on failure. AVAILABILITY
Source is available from http://loop-aes.sourceforge.net/ AUTHORS
Jari Ruusu LINUX February 23 2011 AESPIPE(1)
All times are GMT -4. The time now is 08:12 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy