Problema mudando a senha para a chave gpg

0

Eu exportei minha chave gpg da máquina em que foram criadas para outro servidor.

No novo servidor, tentei usar a chave importada para descriptografar alguns arquivos que recebi, mas recebi o seguinte erro:

gpg: encrypted with 1024-bit RSA key, ID 0A83CFB1, created 2014-09-09
      "App Eng <[email protected]>"
gpg: public key decryption failed: Bad passphrase
gpg: decryption failed: No secret key

Tenho certeza de que a frase secreta que usei está correta. Eu então tentei editar minha chave e mudar a frase-senha:

gpg --list-keys

/home/dx/.gnupg/pubring.gpg
-------------------------------
pub   2048R/DB437C11 2016-04-29 [expires: 2018-04-29]
uid       [ unknown] App Eng (ibm keys) <[email protected]>
sub   2048R/0AC6B02C 2016-04-29 [expires: 2018-04-29]

pub   1024R/AADE6532 2014-09-09
uid       [ unknown] App Eng <[email protected]>
sub   1024R/0A83CFB1 2014-09-09

gpg --edit-key AADE6532
gpg (GnuPG) 2.0.28; Copyright (C) 2015 Free Software Foundation, Inc.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Secret key is available.

pub  1024R/AADE6532  created: 2014-09-09  expires: never       usage: SC  
                     trust: unknown       validity: unknown
sub  1024R/0A83CFB1  created: 2014-09-09  expires: never       usage: E   
[ unknown] (1). App Eng <[email protected]>

gpg> passwd
Key is protected.

You need a passphrase to unlock the secret key for
user: "App Eng <[email protected]>"
1024-bit RSA key, ID AADE6532, created 2014-09-09

gpg: cancelled by user
Can't edit this key: Operation cancelled

Isso me faz pensar que houve algum problema com a importação das chaves. Alguém pode entender por que não consigo descriptografar meus arquivos com a chave instalada? Obrigado!

    
por AlessioG 22.06.2016 / 11:59

1 resposta

0

Este link tem a resposta: link  

The special user which runs the apps on this host, doesn't have the proper TTY rights when I sudo to it. So, gpg being unable to show the TTY GUI, just fails without giving the real reason. In order to be able to do this I had to exit my navsrv sudo session, and make the following call:
chmod o+rw 'tty' && sudo -i -u navsrv gpg --edit-key 8267977F

Next, I entered the navsrv login password. Then, at the gpg command prompt, when I did "passwd", I got the Enter Passphrase GUI.

    
por 15.11.2017 / 06:29

Tags