Bug 176803

Summary: gpg --decrypt segfault
Product: [Fedora] Fedora Reporter: Warren Togami <wtogami>
Component: gnupgAssignee: Nalin Dahyabhai <nalin>
Status: CLOSED DUPLICATE QA Contact: Mike McLean <mikem>
Severity: medium Docs Contact:
Priority: medium    
Version: rawhide   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2006-01-03 16:29:22 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Warren Togami 2006-01-03 01:22:31 UTC
100% reproducible segfault when I attempt to use gpg --decrypt on this file.  It
requires my secret key so I cannot upload this example for reproduction.

gnupg-1.4.2-3.1

[warren@caprica cards]$ gdb gpg
GNU gdb Red Hat Linux (6.3.0.0-1.94rh)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-redhat-linux-gnu"...Using host libthread_db
library "/lib/libthread_db.so.1".

(gdb) run --decrypt boacheck.asc
Starting program: /usr/bin/gpg --decrypt boacheck.asc
Reading symbols from shared object read from target memory...done.
Loaded system supplied DSO at 0x111000

Program received signal SIGSEGV, Segmentation fault.
ctermid (s=0x0) at ../sysdeps/posix/ctermid.c:35
35        return strcpy (s, "/dev/tty");
(gdb) bt
#0  ctermid (s=0x0) at ../sysdeps/posix/ctermid.c:35
#1  0x008bd430 in tty_get_ttyname () at ttyio.c:103
#2  0x008bd4e7 in init_ttyfp () at ttyio.c:160
#3  0x008bd818 in tty_printf (fmt=0x8de32e "\n") at ttyio.c:223
#4  0x00865919 in passphrase_to_dek (keyid=0xbfd19a60, pubkey_algo=16,
cipher_algo=3, s2k=0x82ed430, mode=0,
    tryagain_text=0x0, canceled=0xbfd19a80) at passphrase.c:888
#5  0x008668a7 in check_secret_key (sk=0x82ed3f8, n=3) at seckey-cert.c:82
#6  0x0082e582 in get_seckey (sk=0x82ed3f8, keyid=0x82eadd0) at getkey.c:497
#7  0x008641c6 in get_session_key (k=0x82eadd0, dek=0xb7f14584) at pubkey-enc.c:84
#8  0x00833a27 in proc_pubkey_enc (c=0x82eac60, pkt=0x82eacb8) at mainproc.c:405
#9  0x008379ed in do_proc_packets (c=0x82eac60, a=0x82e6b30) at mainproc.c:1243
#10 0x00837c77 in proc_encryption_packets (anchor=0x0, a=0x82e6b30) at
mainproc.c:1152
#11 0x0087015f in decrypt_message (filename=0xbfd1b9e8 "boacheck.asc") at
decrypt.c:86
#12 0x00825468 in main (argc=1, argv=0xbfd1a17c) at g10.c:3182
(gdb)

Comment 1 Nalin Dahyabhai 2006-01-03 16:29:22 UTC

*** This bug has been marked as a duplicate of 176753 ***