Link to home
Start Free TrialLog in
Avatar of TSG954
TSG954Flag for United States of America

asked on

pgp passphrase using command line

How can I retrieve a pgp passphrase using command line? I am trying to decrypt a file but keep getting this error. “no private key could be found for decryption.”
thanks,
Kenia
Avatar of btan
btan

PLs see this if hepful

http://www.symantec.com/connect/forums/not-able-decrypt-file

Most likely, the file wasn't encrypted to a key you possess.

If you run "pgp --list-keys" it will show you all the keys in your keyring.  Some of these are your prviate keys, and the others are the public keys of people you communicate with.

Run "pgp --verify file-to-verify" and it will tell you the KeyID of the recipient key.  The file should be encrypted to an encryption subkey.  You'll see a message like

file.pgp:verify (3144:data is encrypted to unknown ID 0x73357D11)
file.pgp:verify (1080:no private key could be found for decryption)
 
 

in which case you have no idea to whom the file was actually encrypted.  Or, you might see something like

file.pgp:verify (3093:data is encrypted to subkey ID 0x73357D11)
file.pgp:verify (3044:subkey ID 0x73357D11 belongs to 0xCF73E89C Jon Test <jt@eng.pgp.com>)
file.pgp:verify (1080:no private key could be found for decryption)
 
This tells you that you at least have the corresponding public key in your keyring.
Avatar of TSG954

ASKER

Thanks, getting this after the 'verify file' command. What does this mean?

C:\Documents and Settings\STEVE\Desktop>pgp --verify ws_test.txt.pgp
ws_test.txt.pgp:verify (3093:data is encrypted to subkey ID 0x4941B758)
ws_test.txt.pgp:verify (3044:subkey ID 0x4941B758 belongs to 0x26795D0E whateverWW
XXUNIT Mainframe PGP <fxrunit@whatever.com>)
ws_test.txt.pgp:verify (1080:no private key could be found for decryption)
ASKER CERTIFIED SOLUTION
Avatar of btan
btan

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of TSG954

ASKER

thanks,
Kenia