Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 58623 - keychain 2.3.3 states incorrect number of keys to add
Summary: keychain 2.3.3 states incorrect number of keys to add
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Hosted Projects
Classification: Unclassified
Component: Keychain (show other bugs)
Hardware: All Linux
: High trivial (vote)
Assignee: Keychain Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-07-27 22:07 UTC by Daniel Westermann-Clark
Modified: 2004-07-28 18:54 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
Patch against keychain 2.3.3 to correct count (keychain-2.3.3-key-count.patch,479 bytes, patch)
2004-07-27 22:11 UTC, Daniel Westermann-Clark
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel Westermann-Clark 2004-07-27 22:07:55 UTC
keychain 2.3.3 claims that it wants to add one more key than I'm feeding it.  When first started, keychain says "Adding 3 keys(s)...", when I'm telling it to use two.  However, it correctly adds the two keys.

I'll be attaching a patch after the initial bug submission, against keychain 2.3.3.

Reproducible: Always
Steps to Reproduce:
1. keychain ~/.ssh/identity ~/.ssh/id_rsa

Actual Results:  
keychain prints the following:

KeyChain 2.3.3; http://www.gentoo.org/projects/keychain
Copyright 2002-2004 Gentoo Technologies, Inc.; Distributed under the GPL

 * Initializing /home/dwc/.keychain/fortuna-sh file...
 * Initializing /home/dwc/.keychain/fortuna-csh file...
 * Starting ssh-agent
 * Adding 3 key(s)...
Enter passphrase for dwc@fortuna:
 * Identity added: /home/dwc/.ssh/identity (dwc@fortuna)
 * Identity added: /home/dwc/.ssh/id_rsa (/home/dwc/.ssh/id_rsa)

Expected Results:  
KeyChain 2.3.3; http://www.gentoo.org/projects/keychain
Copyright 2002-2004 Gentoo Technologies, Inc.; Distributed under the GPL

 * Initializing /home/dwc/.keychain/fortuna-sh file...
 * Initializing /home/dwc/.keychain/fortuna-csh file...
 * Starting ssh-agent
 * Adding 2 key(s)...
Enter passphrase for dwc@fortuna:
 * Identity added: /home/dwc/.ssh/identity (dwc@fortuna)
 * Identity added: /home/dwc/.ssh/id_rsa (/home/dwc/.ssh/id_rsa)

Portage 2.0.50-r9 (default-x86-2004.2, gcc-3.3.3, glibc-2.3.3.20040420-r0, 2.6.7)
=================================================================
System uname: 2.6.7 i686 AMD Athlon(tm) XP 2000+
Gentoo Base System version 1.4.16
distcc 2.13 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [enabled]
Autoconf: sys-devel/autoconf-2.59-r3
Automake: sys-devel/automake-1.8.3
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-mcpu=athlon-xp -O2 -fomit-frame-pointer -pipe"
CHOST="i686-pc-linux-gnu"
COMPILER="gcc3"
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config
/usr/kde/3.1/share/config /usr/kde/3.2/share/config /usr/kde/3/share/config
/usr/lib/mozilla/defaults/pref /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-mcpu=athlon-xp -O2 -fomit-frame-pointer -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache distcc sandbox userpriv"
GENTOO_MIRRORS="http://open-systems.ufl.edu/mirrors/gentoo
ftp://ftp.ussg.iu.edu/pub/linux/gentoo ftp://ftp.gtlib.cc.gatech.edu/pub/gentoo
http://gentoo.oregonstate.edu"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://dwc.homedns.org/gentoo-portage"
USE="3dnow X aalib acpi alsa apm avi berkdb cdr crypt cups divx4linux dvd encode
fbcon foomaticdb gdbm gif gnome gpm gtk gtk2 gtkhtml guile imlib java jpeg kde
libg++ libwww mad maildir mikmod mmx motif mozilla mpeg ncurses nls oggvorbis
opengl oss pam pda pdflib perl png python qt quicktime readline sasl sdl slang
spell ssl svga tcpd tiff truetype x86 xml xml2 xmms xv xvid zlib"
Comment 1 Daniel Westermann-Clark 2004-07-27 22:11:51 UTC
Created attachment 36302 [details, diff]
Patch against keychain 2.3.3 to correct count

There may be a better way to accomplish this, but I couldn't come up with one. 
The patch makes a minor modification to the listmissing function.  When a new
key is found (i.e. one not already added to the agent), the patched function
tests if $lm_missing is zero-length, and only concatenates if $lm_missing
already contains something.
Comment 2 Aron Griffis (RETIRED) gentoo-dev 2004-07-28 18:54:32 UTC
Thanks Daniel, fixed in 2.3.5 released today