NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
lib/53012: ssh crashes due to openssl version mismatch
>Number: 53012
>Category: lib
>Synopsis: ssh crashes due to openssl version mismatch
>Confidential: no
>Severity: critical
>Priority: high
>Responsible: lib-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Mon Feb 12 12:10:00 +0000 2018
>Originator: Martin Husemann
>Release: NetBSD 8.99.12
>Organization:
The NetBSD Foundation, Inc.
>Environment:
System: NetBSD thirdstage.duskware.de 8.99.12 NetBSD 8.99.12 (MODULAR) #62: Mon Feb 12 12:18:53 CET 2018 martin%thirdstage.duskware.de@localhost:/usr/src/sys/arch/sparc64/compile/MODULAR sparc64
Architecture: sparc64
Machine: sparc64
>Description:
Running ssh against certain machines crashes on sparc64 after authentication:
debug1: Local version string SSH-2.0-OpenSSH_7.6 NetBSD_Secure_Shell-20171007
debug1: Remote protocol version 2.0, remote software version OpenSSH_6.8 NetBSD_Secure_Shell-20150403-hpn13v14-lpk
debug1: match: OpenSSH_6.8 NetBSD_Secure_Shell-20150403-hpn13v14-lpk pat OpenSSH* compat 0x04000000
debug1: Authenticating to xxxxx.xxxxxx.xxxx:22 as 'martin'
Program received signal SIGSEGV, Segmentation fault.
BN_num_bits (a=0x0)
at /usr/src/crypto/external/bsd/openssl.old/dist/crypto/bn/bn_lib.c:219
219 int i = a->top - 1;
#0 BN_num_bits (a=0x0)
at /usr/src/crypto/external/bsd/openssl.old/dist/crypto/bn/bn_lib.c:219
#1 0x0000000041f23f1c in sshkey_size (k=k@entry=0x42c18180)
at /usr/src/crypto/external/bsd/openssh/dist/sshkey.c:261
#2 0x0000000041f44990 in hostfile_read_key (cpp=0xffffffffffff6ef0,
bitsp=bitsp@entry=0xffffffffffff6ee0, ret=0x42c18180)
at /usr/src/crypto/external/bsd/openssh/dist/hostfile.c:183
#3 0x0000000041f45558 in hostkeys_foreach (
path=path@entry=0x42c4b280 "/etc/ssh/ssh_known_hosts",
callback=0x41f43e00 <record_hostkey>, ctx=ctx@entry=0xffffffffffffb0a8,
host=host@entry=0x42c22110 "cvs.netbsd.org", ip=ip@entry=0x0,
options=options@entry=3)
at /usr/src/crypto/external/bsd/openssh/dist/hostfile.c:780
#4 0x0000000041f45740 in load_hostkeys (hostkeys=hostkeys@entry=0x42c22120,
host=0x42c22110 "cvs.netbsd.org",
path=0x42c4b280 "/etc/ssh/ssh_known_hosts")
at /usr/src/crypto/external/bsd/openssh/dist/hostfile.c:281
#5 0x0000000000123528 in order_hostkeyalgs (port=<optimized out>,
hostaddr=0x242e78 <hostaddr>, host=0x42c22100 "cvs.netbsd.org")
at /usr/src/crypto/external/bsd/openssh/dist/sshconnect2.c:126
(gdb) up
#1 0x0000000041f23f1c in sshkey_size (k=k@entry=0x42c18180)
at /usr/src/crypto/external/bsd/openssh/dist/sshkey.c:261
261 return BN_num_bits(k->rsa->p);
(gdb) list
256 case KEY_RSA:
257 case KEY_RSA_CERT:
258 #if OPENSSL_VERSION_NUMBER >= 0x10100000UL
259 return RSA_bits(k->rsa);
260 #else
261 return BN_num_bits(k->rsa->p);
262 #endif
(gdb) p *k->rsa
$8 = {pad = 0, version = 0, meth = 0x4244f290, engine = 0x0, n = 0x42c4b4a0,
e = 0x42c4b480, d = 0x0, p = 0x0, q = 0x0, dmp1 = 0x0, dmq1 = 0x0,
iqmp = 0x0, ex_data = {sk = 0x0, dummy = 0}, references = 1, flags = 6,
_method_mod_n = 0x0, _method_mod_p = 0x0, _method_mod_q = 0x0,
bignum_data = 0x0, blinding = 0x0, mt_blinding = 0x0}
(gdb) p k->rsa->p
$9 = (BIGNUM *) 0x0
>How-To-Repeat:
Available on request. Basically: "ssh -v $somemachine" does it for me. Works
fine with other machines.
>Fix:
n/a
Home |
Main Index |
Thread Index |
Old Index