Well, after some hacking, I think I'd found the answer to manuplate the secret key UID now. I think this worths sharing. It may not be the intension of the authors, but at the meanwhile while secret key UID management is not available, this should provide some solution. This method should work for people want to add a secret key UID, delete a secret key UID, or bla bla bla. Though, GnuPG itself should provide some way to synchronize the secret key UID with the public key UID, or drop the secret key UID completely.
I got the idea from this article: http://lists.gnupg.org/pipermail/gnupg-devel/2000-January/016247.html > The user IDs are actually not needed in the secret key but they are > normally created to make the listening easier. If the secret key UID is "only" created to make the listening easier, I can reasonably assume that it is irrevelent to the corresponding public key UID. Then, if I backup and drop the original public key UID that has many signatures, create a new dummy public/secret key UID pair with exactly the same name, e-mail and comment, and replace the dummy new public key UID with my original, backuped one, the new secret key UID should be paired with the original, signed public key UID. Then, I'll have a new secret key UID to use. This works. Here is the actual steps involved. ==================================== [EMAIL PROTECTED] ~ % gpg --edit 30B94B5C gpg (GnuPG) 1.4.1; Copyright (C) 2005 Free Software Foundation, Inc. This program comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions. See the file COPYING for details. Secret key is available. pub 1024D/30B94B5C created: 2002-07-04 expires: never usage: CS trust: ultimate validity: ultimate sub 4096g/266EF40E created: 2002-07-04 expires: never usage: E [ultimate] (1). 依瑪貓 (imacat) <[EMAIL PROTECTED]> [ultimate] (2) 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> check uid 依瑪貓 (imacat) <[EMAIL PROTECTED]> sig!3 30B94B5C 2005-05-16 [self-signature] sig!3 30B94B5C 2005-05-16 [self-signature] sig! 11C02382 2005-05-25 Ying-Chieh Liao <[EMAIL PROTECTED]> uid 依瑪貓 (imacat) <[EMAIL PROTECTED]> sig!3 30B94B5C 2005-05-16 [self-signature] sig! 11C02382 2005-05-25 Ying-Chieh Liao <[EMAIL PROTECTED]> Command> toggle sec 1024D/30B94B5C created: 2002-07-04 expires: never ssb 4096g/266EF40E created: 2002-07-04 expires: never (1) 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> toggle pub 1024D/30B94B5C created: 2002-07-04 expires: never usage: CS trust: ultimate validity: ultimate sub 4096g/266EF40E created: 2002-07-04 expires: never usage: E [ultimate] (1). 依瑪貓 (imacat) <[EMAIL PROTECTED]> [ultimate] (2) 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> quit [EMAIL PROTECTED] ~ % cp .gnupg/pubring.gpg .gnupg/pubring.gpg-bak [EMAIL PROTECTED] ~ % gpg --edit 30B94B5C gpg (GnuPG) 1.4.1; Copyright (C) 2005 Free Software Foundation, Inc. This program comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions. See the file COPYING for details. Secret key is available. pub 1024D/30B94B5C created: 2002-07-04 expires: never usage: CS trust: ultimate validity: ultimate sub 4096g/266EF40E created: 2002-07-04 expires: never usage: E [ultimate] (1). 依瑪貓 (imacat) <[EMAIL PROTECTED]> [ultimate] (2) 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> check uid 依瑪貓 (imacat) <[EMAIL PROTECTED]> sig!3 30B94B5C 2005-05-16 [self-signature] sig!3 30B94B5C 2005-05-16 [self-signature] sig! 11C02382 2005-05-25 Ying-Chieh Liao <[EMAIL PROTECTED]> uid 依瑪貓 (imacat) <[EMAIL PROTECTED]> sig!3 30B94B5C 2005-05-16 [self-signature] sig! 11C02382 2005-05-25 Ying-Chieh Liao <[EMAIL PROTECTED]> Command> toggle sec 1024D/30B94B5C created: 2002-07-04 expires: never ssb 4096g/266EF40E created: 2002-07-04 expires: never (1) 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> toggle pub 1024D/30B94B5C created: 2002-07-04 expires: never usage: CS trust: ultimate validity: ultimate sub 4096g/266EF40E created: 2002-07-04 expires: never usage: E [ultimate] (1). 依瑪貓 (imacat) <[EMAIL PROTECTED]> [ultimate] (2) 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> uid 2 pub 1024D/30B94B5C created: 2002-07-04 expires: never usage: CS trust: ultimate validity: ultimate sub 4096g/266EF40E created: 2002-07-04 expires: never usage: E [ultimate] (1). 依瑪貓 (imacat) <[EMAIL PROTECTED]> [ultimate] (2)* 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> deluid Really remove this user ID? (y/N) y pub 1024D/30B94B5C created: 2002-07-04 expires: never usage: CS trust: ultimate validity: ultimate sub 4096g/266EF40E created: 2002-07-04 expires: never usage: E [ultimate] (1). 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> check uid 依瑪貓 (imacat) <[EMAIL PROTECTED]> sig!3 30B94B5C 2005-05-16 [self-signature] sig!3 30B94B5C 2005-05-16 [self-signature] sig! 11C02382 2005-05-25 Ying-Chieh Liao <[EMAIL PROTECTED]> Command> toggle sec 1024D/30B94B5C created: 2002-07-04 expires: never ssb 4096g/266EF40E created: 2002-07-04 expires: never (1) 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> toggle pub 1024D/30B94B5C created: 2002-07-04 expires: never usage: CS trust: ultimate validity: ultimate sub 4096g/266EF40E created: 2002-07-04 expires: never usage: E [ultimate] (1). 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> adduid Real name: 依瑪貓 Email address: [EMAIL PROTECTED] Comment: imacat You are using the `utf-8' character set. You selected this USER-ID: "依瑪貓 (imacat) <[EMAIL PROTECTED]>" Change (N)ame, (C)omment, (E)mail or (O)kay/(Q)uit? o You need a passphrase to unlock the secret key for user: "依瑪貓 (imacat) <[EMAIL PROTECTED]>" 1024-bit DSA key, ID 30B94B5C, created 2002-07-04 pub 1024D/30B94B5C created: 2002-07-04 expires: never usage: CS trust: ultimate validity: ultimate sub 4096g/266EF40E created: 2002-07-04 expires: never usage: E [ultimate] (1). 依瑪貓 (imacat) <[EMAIL PROTECTED]> [ultimate] (2) 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> check uid 依瑪貓 (imacat) <[EMAIL PROTECTED]> sig!3 30B94B5C 2005-05-16 [self-signature] sig!3 30B94B5C 2005-05-16 [self-signature] sig! 11C02382 2005-05-25 Ying-Chieh Liao <[EMAIL PROTECTED]> uid 依瑪貓 (imacat) <[EMAIL PROTECTED]> sig!3 30B94B5C 2005-05-25 [self-signature] Command> toggle sec 1024D/30B94B5C created: 2002-07-04 expires: never ssb 4096g/266EF40E created: 2002-07-04 expires: never (1) 依瑪貓 (imacat) <[EMAIL PROTECTED]> (2) 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> toggle pub 1024D/30B94B5C created: 2002-07-04 expires: never usage: CS trust: ultimate validity: ultimate sub 4096g/266EF40E created: 2002-07-04 expires: never usage: E [ultimate] (1). 依瑪貓 (imacat) <[EMAIL PROTECTED]> [ultimate] (2) 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> save [EMAIL PROTECTED] ~ % cp .gnupg/pubring.gpg-bak .gnupg/pubring.gpg cp: overwrite `.gnupg/pubring.gpg'? y [EMAIL PROTECTED] ~ % gpg --edit 30B94B5C gpg (GnuPG) 1.4.1; Copyright (C) 2005 Free Software Foundation, Inc. This program comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions. See the file COPYING for details. Secret key is available. gpg: checking the trustdb gpg: 3 marginal(s) needed, 1 complete(s) needed, PGP trust model gpg: depth: 0 valid: 2 signed: 45 trust: 0-, 0q, 0n, 0m, 0f, 2u gpg: depth: 1 valid: 45 signed: 0 trust: 5-, 0q, 0n, 40m, 0f, 0u gpg: next trustdb check due at 2005-10-22 pub 1024D/30B94B5C created: 2002-07-04 expires: never usage: CS trust: ultimate validity: ultimate sub 4096g/266EF40E created: 2002-07-04 expires: never usage: E [ultimate] (1). 依瑪貓 (imacat) <[EMAIL PROTECTED]> [ultimate] (2) 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> check uid 依瑪貓 (imacat) <[EMAIL PROTECTED]> sig!3 30B94B5C 2005-05-16 [self-signature] sig!3 30B94B5C 2005-05-16 [self-signature] sig! 11C02382 2005-05-25 Ying-Chieh Liao <[EMAIL PROTECTED]> uid 依瑪貓 (imacat) <[EMAIL PROTECTED]> sig!3 30B94B5C 2005-05-16 [self-signature] sig! 11C02382 2005-05-25 Ying-Chieh Liao <[EMAIL PROTECTED]> Command> toggle sec 1024D/30B94B5C created: 2002-07-04 expires: never ssb 4096g/266EF40E created: 2002-07-04 expires: never (1) 依瑪貓 (imacat) <[EMAIL PROTECTED]> (2) 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> toggle pub 1024D/30B94B5C created: 2002-07-04 expires: never usage: CS trust: ultimate validity: ultimate sub 4096g/266EF40E created: 2002-07-04 expires: never usage: E [ultimate] (1). 依瑪貓 (imacat) <[EMAIL PROTECTED]> [ultimate] (2) 依瑪貓 (imacat) <[EMAIL PROTECTED]> Command> quit [EMAIL PROTECTED] ~ % -- Best regards, imacat ^_*' <[EMAIL PROTECTED]> PGP Key: http://www.imacat.idv.tw/me/pgpkey.txt <<Woman's Voice>> News: http://www.wov.idv.tw/ Tavern IMACAT's: http://www.imacat.idv.tw/ TLUG List Manager: http://www.linux.org.tw/mailman/listinfo/tlug
pgpFlalmvSw29.pgp
Description: PGP signature
_______________________________________________ Gnupg-users mailing list Gnupg-users@gnupg.org http://lists.gnupg.org/mailman/listinfo/gnupg-users