Page MenuHome GnuPG

Primary ID not separated from pub record with --fixed-list-mode
Closed, ResolvedPublic

Description

Release: gpg (GnuPG) 1.4.2.2

Environment

Using Debian "gnupg" package:
Architecture: i386
Version: 1.4.2.2-1

Debian GNU+Linux "unstable".
$ ldd /usr/bin/gnupg

linux-gate.so.1 =>  (0xffffe000)
libz.so.1 => /usr/lib/libz.so.1 (0x4890e000)
libbz2.so.1.0 => /lib/libbz2.so.1.0 (0x4a339000)
libreadline.so.5 => /lib/libreadline.so.5 (0x48970000)
libdl.so.2 => /lib/tls/i686/cmov/libdl.so.2 (0x48813000)
libusb-0.1.so.4 => /usr/lib/libusb-0.1.so.4 (0x48819000)
libc.so.6 => /lib/tls/i686/cmov/libc.so.6 (0x486d9000)
libncurses.so.5 => /usr/lib/libncurses.so.5 (0x49e0b000)
/lib/ld-linux.so.2 (0x80000000)

Description

According to the file doc/DETAILS (/usr/share/doc/gnupg/DETAILS.gz in the Debian package), --fixed-list-mode should separate the primary uid from the public key. This does not occur.

$ gpg --with-colons /tmp/ted.key
pub:u:1024:17:C697B70DDDD11D8A:2005-07-25:::u:Ted Percival (midg3t) <ted@midg3t.net>:
uid:::::::::Ted Percival <t.percival@stpeters.qld.edu.au>:
uid:::::::::Ted Percival <ted.percival@quest.com>:
sub:u:1024:16:E7242EE71B8B973D:2005-07-25::::

$ gpg --with-colons --fixed-list-mode /tmp/ted.key
pub:u:1024:17:C697B70DDDD11D8A:1122277878:::u:Ted Percival (midg3t) <ted@midg3t.net>:
uid:::::::::Ted Percival <t.percival@stpeters.qld.edu.au>:
uid:::::::::Ted Percival <ted.percival@quest.com>:
sub:u:1024:16:E7242EE71B8B973D:1122277880::::

The date format is changed to a unix timestamp as described in the DETAILS file, however the primary uid is still combined with the public key on the first line. I have tested this with two different public keys, both as ASCII-armored text and as binary files.

How To Repeat

$ gpg --export -a KeyID | gpg --with-colons --fixed-list-mode

Fix

Unknown

Event Timeline

This kind of listing is done in mainproc.c and not in the regular keylisting.
We should eventually fix it there or better try to use the same code (not easy).