I created my key pair many years ago and everything works fine using Debian 12 so far. Recently I created a new key pair for an other computer (using my system) and exported the private and public key in order to use it elsewhere. (It works fine there too.) Afterwards I deleted the key pair on my primary system because I don't need the public key from the other system. Nevertheless, I want to write encrypted emails to the other system. Therefore, I imported only the public key to my keyring. Surprisingly, the secret key keeps returning as soon as I import the public key.
I have checked several times that I didn't mess up the export files. (I in fact did import the public key and not by accident the secret key.)
When I am searching for secret GPG keys on my system in the command line I can find the second private key (that shouldn't even be there) after importing the public key. But when I attempt to delete it GPG claims that it doesn't exist. (I can also find it using the Seahorse/Passwords app and when I delete it there using the GUI it looks like it is gone. Even on the command line it doesn't show up any longer.) But each time I import the public key the secret key magically returns too.
Do you have an Idea what I could do to get rid of the somewhat obscure hidden secret key on my system?
I have checked several times that I didn't mess up the export files. (I in fact did import the public key and not by accident the secret key.)
When I am searching for secret GPG keys on my system in the command line I can find the second private key (that shouldn't even be there) after importing the public key. But when I attempt to delete it GPG claims that it doesn't exist. (I can also find it using the Seahorse/Passwords app and when I delete it there using the GUI it looks like it is gone. Even on the command line it doesn't show up any longer.) But each time I import the public key the secret key magically returns too.
Do you have an Idea what I could do to get rid of the somewhat obscure hidden secret key on my system?
Code:
$ gpg --list-secret-keys/home/user/.gnupg/pubring.kbx-------------------------------------sec rsa4096 2010-01-01 [SC] XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXuid [ultimate] Name <name@mail.com>ssb rsa4096 2010-01-01 [E]sec# rsa4096 2020-01-01 [SC] YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYuid [ultimate] Name2 <name2@mail.com>ssb rsa4096 2020-01-01 [E]$ gpg --delete-secret-key YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYgpg (GnuPG) 2.2.40; Copyright (C) 2022 g10 Code GmbHThis is free software: you are free to change and redistribute it.There is NO WARRANTY, to the extent permitted by law.gpg: key "YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY" not foundgpg: YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY: delete key failed: Not found
Statistics: Posted by Onsemeliot — 2024-04-28 14:43 — Replies 1 — Views 54