Error on gpg key exported from linux to Mac
mgcyung at gmail.com
Sat Mar 18 21:23:43 CET 2023
I have exported a gpg key from linux to Mac. Exporting commands on linux
are as follows
gpg --export-secret-keys -a test_01.asc
gpg --export -a test_01_pub.asc
Importing commands on Mac are as follows
gpg --import test_01.asc
gpg --import test_01_pub.asc
But when decrypting with the imported key,
gpg -d -vvv test_01.gpg
gpg: using character set 'utf-8'
gpg: enabled compatibility flags:
# off=0 ctb=85 tag=1 hlen=3 plen=268
:pubkey enc packet: version 3, algo 1, keyid XXXXXXXXXXXXXXXX
data: [2048 bits]
gpg: public key is XXXXXXXXXXXXXXXX
# off=271 ctb=d2 tag=18 hlen=2 plen=62 new-ctb
:encrypted data packet:
gpg: using subkey XXXXXXXXXXXXXXXX instead of primary key XXXXXXXXXXXXXXXX
gpg: encrypted with rsa2048 key, ID XXXXXXXXXXXXXXXX, created xxxx-xx-xx
"xxx <xxx at xxx.com>"
gpg: public key decryption failed: Bad secret key
gpg: decryption failed: Bad secret key
And when I tried to change its passwd, gpg said
error getting keyinfo from agent: System error w/o errno
pKey has only stub or on-card key items - no passphrase to change.
The versions of gpgs on Linux and Mac are 2.2.41 and 2.4.0
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Gnupg-users