]> git.ipfire.org Git - thirdparty/openssh-portable.git/log
thirdparty/openssh-portable.git
8 years agosync fmt_scaled.c with OpenBSD
Damien Miller [Sat, 11 Mar 2017 23:48:14 +0000 (10:48 +1100)] 
sync fmt_scaled.c with OpenBSD

revision 1.13
date: 2017/03/11 23:37:23;  author: djm;  state: Exp;  lines: +14 -1;  commitid: jnFKyHkB3CEiEZ2R;
fix signed integer overflow in scan_scaled. Found by Nicolas Iooss
using AFL against ssh_config. ok deraadt@ millert@
----------------------------
revision 1.12
date: 2013/11/29 19:00:51;  author: deraadt;  state: Exp;  lines: +6 -5;
fairly simple unsigned char casts for ctype
ok krw
----------------------------
revision 1.11
date: 2012/11/12 14:07:20;  author: halex;  state: Exp;  lines: +4 -2;
make scan_scaled set errno to EINVAL rather than ERANGE if it encounters
an invalid multiplier, like the man page says it should

"looks sensible" deraadt@, ok ian@
----------------------------
revision 1.10
date: 2009/06/20 15:00:04;  author: martynas;  state: Exp;  lines: +4 -4;
use llabs instead of the home-grown version;  and some comment changes
ok ian@, millert@
----------------------------

8 years agoupstream commit
djm@openbsd.org [Fri, 10 Mar 2017 05:01:13 +0000 (05:01 +0000)] 
upstream commit

When updating hostkeys, accept RSA keys if
HostkeyAlgorithms contains any RSA keytype. Previously, ssh could ignore RSA
keys when any of the ssh-rsa-sha2-* methods was enabled in HostkeyAlgorithms
nit ssh-rsa (SHA1 signatures) was not. bz#2650 reported by Luis Ressel; ok
dtucker@

Upstream-ID: c5e8cfee15c42f4a05d126158a0766ea06da79d2

8 years agoupstream commit
djm@openbsd.org [Fri, 10 Mar 2017 04:24:55 +0000 (04:24 +0000)] 
upstream commit

make hostname matching really insensitive to case;
bz#2685, reported by Petr Cerny; ok dtucker@

Upstream-ID: e467622ff154269e36ba8b6c9e3d105e1c4a9253

8 years agoupstream commit
djm@openbsd.org [Fri, 10 Mar 2017 03:52:48 +0000 (03:52 +0000)] 
upstream commit

reword a comment to make it fit 80 columns

Upstream-ID: 4ef509a66b96c7314bbcc87027c2af71fa9d0ba4

8 years agoupstream commit
djm@openbsd.org [Fri, 10 Mar 2017 04:27:32 +0000 (04:27 +0000)] 
upstream commit

better match sshd config parser behaviour: fatal() if
line is overlong, increase line buffer to match sshd's; bz#2651 reported by
Don Fong; ok dtucker@

Upstream-ID: b175ae7e0ba403833f1ee566edf10f67443ccd18

8 years agoupstream commit
djm@openbsd.org [Fri, 10 Mar 2017 04:26:06 +0000 (04:26 +0000)] 
upstream commit

ensure hostname is lower-case before hashing it;
bz#2591 reported by Griff Miller II; ok dtucker@

Upstream-ID: c3b8b93804f376bd00d859b8bcd9fc0d86b4db17

8 years agoupstream commit
djm@openbsd.org [Fri, 10 Mar 2017 04:24:55 +0000 (04:24 +0000)] 
upstream commit

make hostname matching really insensitive to case;
bz#2685, reported by Petr Cerny; ok dtucker@

Upstream-ID: e632b7a9bf0d0558d5ff56dab98b7cca6c3db549

8 years agoupstream commit
dtucker@openbsd.org [Fri, 10 Mar 2017 04:11:00 +0000 (04:11 +0000)] 
upstream commit

Remove old null check from config dumper.  Patch from
jjelen at redhat.com vi bz#2687, ok djm@

Upstream-ID: 824ab71467b78c4bab0dd1b3a38e8bc5f63dd528

8 years agoupstream commit
djm@openbsd.org [Fri, 10 Mar 2017 04:07:20 +0000 (04:07 +0000)] 
upstream commit

fix regression in 7.4 server-sig-algs, where we were
accidentally excluding SHA2 RSA signature methods. bz#2680, patch from Nuno
Goncalves; ok dtucker@

Upstream-ID: 81ac8bfb30960447740b9b8f6a214dcf322f12e8

8 years agoupstream commit
dtucker@openbsd.org [Fri, 10 Mar 2017 03:53:11 +0000 (03:53 +0000)] 
upstream commit

Check for NULL return value from key_new.  Patch from
jjelen at redhat.com via bz#2687, ok djm@

Upstream-ID: 059e33cd43cba88dc8caf0b1936fd4dd88fd5b8e

8 years agoupstream commit
djm@openbsd.org [Fri, 10 Mar 2017 03:52:48 +0000 (03:52 +0000)] 
upstream commit

reword a comment to make it fit 80 columns

Upstream-ID: b4b48b4487c0821d16e812c40c9b09f03b28e349

8 years agoupstream commit
dtucker@openbsd.org [Fri, 10 Mar 2017 03:48:57 +0000 (03:48 +0000)] 
upstream commit

Check for NULL argument to sshkey_read.  Patch from
jjelen at redhat.com via bz#2687, ok djm@

Upstream-ID: c2d00c2ea50c4861d271d0a586f925cc64a87e0e

8 years agoupstream commit
dtucker@openbsd.org [Fri, 10 Mar 2017 03:45:40 +0000 (03:45 +0000)] 
upstream commit

Plug some mem leaks mostly on error paths.  From jjelen
at redhat.com via bz#2687, ok djm@

Upstream-ID: 3fb030149598957a51b7c8beb32bf92cf30c96f2

8 years agoupstream commit
dtucker@openbsd.org [Fri, 10 Mar 2017 03:24:48 +0000 (03:24 +0000)] 
upstream commit

Plug mem leak on GLOB_NOMATCH case.  From jjelen at
redhat.com via bz#2687, ok djm@

Upstream-ID: 8016a7ae97719d3aa55fb723fc2ad3200058340d

8 years agoupstream commit
dtucker@openbsd.org [Fri, 10 Mar 2017 03:22:40 +0000 (03:22 +0000)] 
upstream commit

Plug descriptor leaks of auth_sock.  From jjelen at
redhat.com via bz#2687, ok djm@

Upstream-ID: 248acb99a5ed2fdca37d1aa33c0fcee7be286d88

8 years agoupstream commit
djm@openbsd.org [Fri, 10 Mar 2017 03:18:24 +0000 (03:18 +0000)] 
upstream commit

correctly hash hosts with a port number. Reported by Josh
Powers in bz#2692; ok dtucker@

Upstream-ID: 468e357ff143e00acc05bdd2803a696b3d4b6442

8 years agoupstream commit
djm@openbsd.org [Fri, 10 Mar 2017 03:15:58 +0000 (03:15 +0000)] 
upstream commit

don't truncate off \r\n from long stderr lines; bz#2688,
reported by Brian Dyson; ok dtucker@

Upstream-ID: cdfdc4ba90639af807397ce996153c88af046ca4

8 years agoupstream commit
dtucker@openbsd.org [Fri, 10 Mar 2017 02:59:51 +0000 (02:59 +0000)] 
upstream commit

Validate digest arg in ssh_digest_final; from jjelen at
redhat.com via bz#2687, ok djm@

Upstream-ID: dbe5494dfddfe523fab341a3dab5a79e7338f878

8 years agoCheck for NULL from malloc.
Darren Tucker [Fri, 10 Mar 2017 02:40:18 +0000 (13:40 +1100)] 
Check for NULL from malloc.

Part of bz#2687, from jjelen at redhat.com.

8 years agoIf OSX is using launchd, remove screen no.
Darren Tucker [Fri, 10 Mar 2017 02:22:32 +0000 (13:22 +1100)] 
If OSX is using launchd, remove screen no.

Check for socket with and without screen number.  From Apple and Jakob
Schlyter via bz#2341, with contributions from Ron Frederick, ok djm@

8 years agoupstream commit
djm@openbsd.org [Wed, 8 Mar 2017 12:07:47 +0000 (12:07 +0000)] 
upstream commit

quote [host]:port in generated ProxyJump commandline; the
[ / ] characters can confuse some shells (e.g. zsh). Reported by Lauri
Tirkkonen via bugs@

Upstream-ID: 65cdd161460e1351c3d778e974c1c2a4fa4bc182

8 years agoupstream commit
dtucker@openbsd.org [Mon, 6 Mar 2017 02:03:20 +0000 (02:03 +0000)] 
upstream commit

Check l->hosts before dereferencing; fixes potential null
pointer deref. ok djm@

Upstream-ID: 81c0327c6ec361da794b5c680601195cc23d1301

8 years agoupstream commit
dtucker@openbsd.org [Mon, 6 Mar 2017 00:44:51 +0000 (00:44 +0000)] 
upstream commit

linenum is unsigned long so use %lu in log formats.  ok
deraadt@

Upstream-ID: 9dc582d9bb887ebe0164e030d619fc20b1a4ea08

8 years agoupstream commit
djm@openbsd.org [Fri, 3 Mar 2017 06:13:11 +0000 (06:13 +0000)] 
upstream commit

fix ssh-keygen -H accidentally corrupting known_hosts that
contained already-hashed entries. HKF_MATCH_HOST_HASHED is only set by
hostkeys_foreach() when hostname matching is in use, so we need to look for
the hash marker explicitly.

Upstream-ID: da82ad653b93e8a753580d3cf5cd448bc2520528

8 years agoupstream commit
djm@openbsd.org [Tue, 28 Feb 2017 06:10:08 +0000 (06:10 +0000)] 
upstream commit

small memleak: free fd_set on connection timeout (though
we are heading to exit anyway). From Tom Rix in bz#2683

Upstream-ID: 10e3dadbb8199845b66581473711642d9e6741c4

8 years agoupstream commit
jmc@openbsd.org [Mon, 27 Feb 2017 14:30:33 +0000 (14:30 +0000)] 
upstream commit

errant dot; from klemens nanni

Upstream-ID: 83d93366a5acf47047298c5d3ebc5e7426f37921

8 years agoupstream commit
djm@openbsd.org [Fri, 24 Feb 2017 03:16:34 +0000 (03:16 +0000)] 
upstream commit

might as well set the listener socket CLOEXEC

Upstream-ID: 9c538433d6a0ca79f5f21decc5620e46fb68ab57

8 years agoupstream commit
djm@openbsd.org [Sun, 19 Feb 2017 00:11:29 +0000 (00:11 +0000)] 
upstream commit

add test cases for C locale; ok schwarze@

Upstream-Regress-ID: 783d75de35fbc923d46e2a5e6cee30f8f381ba87

8 years agoupstream commit
djm@openbsd.org [Sun, 19 Feb 2017 00:10:57 +0000 (00:10 +0000)] 
upstream commit

Add a common nl_langinfo(CODESET) alias for US-ASCII
"ANSI_X3.4-1968" that is used by Linux. Fixes mprintf output truncation for
non-UTF-8 locales on Linux spotted by dtucker@; ok deraadt@ schwarze@

Upstream-ID: c6808956ebffd64066f9075d839f74ff0dd60719

8 years agoupstream commit
dtucker@openbsd.org [Tue, 7 Feb 2017 23:03:11 +0000 (23:03 +0000)] 
upstream commit

Remove deprecated SSH1 options RSAAuthentication and
RhostsRSAAuthentication from regression test sshd_config.

Upstream-Regress-ID: 8066b753d9dce7cf02ff87af5c727ff680d99491

8 years agoupstream commit
dtucker@openbsd.org [Fri, 17 Feb 2017 02:32:05 +0000 (02:32 +0000)] 
upstream commit

Do not show rsa1 key type in usage when compiled without
SSH1 support.

Upstream-ID: 068b5c41357a02f319957746fa4e84ea73960f57

8 years agoupstream commit
dtucker@openbsd.org [Fri, 17 Feb 2017 02:31:14 +0000 (02:31 +0000)] 
upstream commit

ifdef out "rsa1" from the list of supported keytypes when
compiled without SSH1 support.  Found by kdunlop at guralp.com, ok djm@

Upstream-ID: cea93a26433d235bb1d64b1d990f19a9c160a70f

8 years agoupstream commit
djm@openbsd.org [Fri, 17 Feb 2017 02:04:15 +0000 (02:04 +0000)] 
upstream commit

For ProxyJump/-J, surround host name with brackets to
allow literal IPv6 addresses. From Dick Visser; ok dtucker@

Upstream-ID: 3a5d3b0171250daf6a5235e91bce09c1d5746bf1

8 years agoupstream commit
jsg@openbsd.org [Wed, 15 Feb 2017 23:38:31 +0000 (23:38 +0000)] 
upstream commit

Fix memory leaks in match_filter_list() error paths.

ok dtucker@ markus@

Upstream-ID: c7f96ac0877f6dc9188bbc908100a8d246cc7f0e

8 years agoupstream commit
djm@openbsd.org [Wed, 15 Feb 2017 01:46:47 +0000 (01:46 +0000)] 
upstream commit

fix division by zero crash in "df" output when server
returns zero total filesystem blocks/inodes. Spotted by Guido Vranken; ok
dtucker@

Upstream-ID: 6fb6c2ae6b289aa07b6232dbc0be54682ef5419f

8 years agoifdef out EVP_R_PRIVATE_KEY_DECODE_ERROR
Darren Tucker [Sun, 12 Feb 2017 04:45:15 +0000 (15:45 +1100)] 
ifdef out EVP_R_PRIVATE_KEY_DECODE_ERROR

EVP_R_PRIVATE_KEY_DECODE_ERROR was added in OpenSSL 1.0.0 so ifdef out
for the benefit of OpenSSL versions prior to that.

8 years agoupstream commit
djm@openbsd.org [Fri, 10 Feb 2017 04:34:50 +0000 (04:34 +0000)] 
upstream commit

bring back r1.34 that was backed out for problems loading
public keys:

translate OpenSSL error codes to something more
meaninful; bz#2522 reported by Jakub Jelen, ok dtucker@

with additional fix from Jakub Jelen to solve the backout.
bz#2525 bz#2523 re-ok dtucker@

Upstream-ID: a9d5bc0306f4473d9b4f4484f880e95f3c1cc031

8 years agoupstream commit
djm@openbsd.org [Fri, 10 Feb 2017 03:36:40 +0000 (03:36 +0000)] 
upstream commit

Sanitise escape sequences in key comments sent to printf
but preserve valid UTF-8 when the locale supports it; bz#2520 ok dtucker@

Upstream-ID: e8eed28712ba7b22d49be534237eed019875bd1e

8 years agoupstream commit
millert@openbsd.org [Wed, 8 Feb 2017 20:32:43 +0000 (20:32 +0000)] 
upstream commit

Avoid printf %s NULL.  From semarie@, OK djm@

Upstream-ID: 06beef7344da0208efa9275d504d60d2a5b9266c

8 years agoupstream commit
djm@openbsd.org [Mon, 6 Feb 2017 09:22:51 +0000 (09:22 +0000)] 
upstream commit

Restore \r\n newline sequence for server ident string. The CR
got lost in the flensing of SSHv1. Pointed out by Stef Bon

Upstream-ID: 5333fd43ce5396bf5999496096fac5536e678fac

8 years agoupstream commit
djm@openbsd.org [Fri, 3 Feb 2017 23:01:42 +0000 (23:01 +0000)] 
upstream commit

unit test for match_filter_list() function; still want a
better name for this...

Upstream-Regress-ID: 840ad6118552c35111f0a897af9c8d93ab8de92a

8 years agoupstream commit
djm@openbsd.org [Fri, 3 Feb 2017 23:05:57 +0000 (23:05 +0000)] 
upstream commit

use ssh_packet_set_log_preamble() to include connection
username in packet log messages, e.g.

Connection closed by invalid user foo 10.1.1.1 port 44056 [preauth]

ok markus@ bz#113

Upstream-ID: 3591b88bdb5416d6066fb3d49d8fff2375bf1a15

8 years agoupstream commit
djm@openbsd.org [Fri, 3 Feb 2017 23:03:33 +0000 (23:03 +0000)] 
upstream commit

add ssh_packet_set_log_preamble() to allow inclusion of a
preamble string in disconnect messages; ok markus@

Upstream-ID: 34cb41182cd76d414c214ccb01c01707849afead

8 years agoupstream commit
djm@openbsd.org [Fri, 3 Feb 2017 23:01:19 +0000 (23:01 +0000)] 
upstream commit

support =- for removing methods from algorithms lists,
e.g. Ciphers=-*cbc; suggested by Cristian Ionescu-Idbohrn in bz#2671 "I like
it" markus@

Upstream-ID: c78c38f9f81a963b33d0eade559f6048add24a6d

8 years agoupstream commit
djm@openbsd.org [Fri, 3 Feb 2017 05:05:56 +0000 (05:05 +0000)] 
upstream commit

allow form-feed characters at EOL; bz#2431 ok dtucker@

Upstream-ID: 1f453afaba6da2ae69d6afdf1ae79a917552f1a2

8 years agoprefer to use ldns-config to find libldns
Damien Miller [Fri, 3 Feb 2017 05:01:22 +0000 (16:01 +1100)] 
prefer to use ldns-config to find libldns

Should fix bz#2603 - "Build with ldns and without kerberos support
fails if ldns compiled with kerberos support" by including correct
cflags/libs

ok dtucker@

8 years agoupstream commit
dtucker@openbsd.org [Fri, 3 Feb 2017 02:56:00 +0000 (02:56 +0000)] 
upstream commit

Make ssh_packet_set_rekey_limits take u32 for the number of
seconds until rekeying (negative values are rejected at config parse time).
This allows the removal of some casts and a signed vs unsigned comparison
warning.

rekey_time is cast to int64 for the comparison which is a no-op
on OpenBSD, but should also do the right thing in -portable on
anything still using 32bit time_t (until the system time actually
wraps, anyway).

some early guidance deraadt@, ok djm@

Upstream-ID: c9f18613afb994a07e7622eb326f49de3d123b6c

8 years agoupstream commit
jsg@openbsd.org [Thu, 2 Feb 2017 10:54:25 +0000 (10:54 +0000)] 
upstream commit

In vasnmprintf() return an error if malloc fails and
don't set a function argument to the address of free'd memory.

ok djm@

Upstream-ID: 1efffffff2f51d53c9141f245b90ac23d33b9779

8 years agoupstream commit
dtucker@openbsd.org [Wed, 1 Feb 2017 02:59:09 +0000 (02:59 +0000)] 
upstream commit

Return true reason for port forwarding failures where
feasible rather than always "administratively prohibited".  bz#2674, ok djm@

Upstream-ID: d901d9887951774e604ca970e1827afaaef9e419

8 years agoupstream commit
dtucker@openbsd.org [Mon, 30 Jan 2017 23:27:39 +0000 (23:27 +0000)] 
upstream commit

Small correction to the known_hosts section on when it is
updated. Patch from lkppo at free.fr some time ago, pointed out by smallm at
sdf.org

Upstream-ID: 1834d7af179dea1a12ad2137f84566664af225d5

8 years agoRemove _XOPEN_SOURCE from wide char detection.
Darren Tucker [Fri, 3 Feb 2017 03:10:34 +0000 (14:10 +1100)] 
Remove _XOPEN_SOURCE from wide char detection.

Having _XOPEN_SOURCE unconditionally causes problems on some platforms
and configurations, notably Solaris 64-bit binaries.  It was there for
the benefit of Linux put the required bits in the *-*linux* section.

Patch from yvoinov at gmail.com.

8 years agoupstream commit
djm@openbsd.org [Mon, 30 Jan 2017 05:22:14 +0000 (05:22 +0000)] 
upstream commit

fully unbreak: some $SSH invocations did not have -F
specified and could pick up the ~/.ssh/config of the user running the tests

Upstream-Regress-ID: f362d1892c0d3e66212d5d3fc02d915c58ef6b89

8 years agoupstream commit
djm@openbsd.org [Mon, 30 Jan 2017 04:54:07 +0000 (04:54 +0000)] 
upstream commit

partially unbreak: was not specifying hostname on some
$SSH invocations

Upstream-Regress-ID: bc8a5e98e57bad0a92ef4f34ed91c1d18294e2cc

8 years agoupstream commit
djm@openbsd.org [Mon, 30 Jan 2017 01:03:00 +0000 (01:03 +0000)] 
upstream commit

revise keys/principals command hang fix (bz#2655) to
consume entire output, avoiding sending SIGPIPE to subprocesses early; ok
dtucker@

Upstream-ID: 7cb04b31a61f8c78c4e48ceededcd2fd5c4ee1bc

8 years agoupstream commit
djm@openbsd.org [Mon, 30 Jan 2017 00:38:50 +0000 (00:38 +0000)] 
upstream commit

small cleanup post SSHv1 removal:

remove SSHv1-isms in commented examples

reorder token table to group deprecated and compile-time conditional tokens
better

fix config dumping code for some compile-time conditional options that
weren't being correctly skipped (SSHv1 and PKCS#11)

Upstream-ID: f2e96b3cb3158d857c5a91ad2e15925df3060105

8 years agoupstream commit
djm@openbsd.org [Mon, 30 Jan 2017 00:34:01 +0000 (00:34 +0000)] 
upstream commit

some explicit NULL tests when dumping configured
forwardings; from Karsten Weiss

Upstream-ID: 40957b8dea69672b0e50df6b4a91a94e3e37f72d

8 years agoupstream commit
djm@openbsd.org [Mon, 30 Jan 2017 00:32:28 +0000 (00:32 +0000)] 
upstream commit

misplaced braces in test; from Karsten Weiss

Upstream-ID: f7b794074d3aae8e35b69a91d211c599c94afaae

8 years agoupstream commit
djm@openbsd.org [Mon, 30 Jan 2017 00:32:03 +0000 (00:32 +0000)] 
upstream commit

don't dereference authctxt before testing != NULL, it
causes compilers to make assumptions; from Karsten Weiss

Upstream-ID: 794243aad1e976ebc717885b7a97a25e00c031b2

8 years agoupstream commit
djm@openbsd.org [Fri, 6 Jan 2017 02:51:16 +0000 (02:51 +0000)] 
upstream commit

use correct ssh-add program; bz#2654, from Colin Watson

Upstream-Regress-ID: 7042a36e1bdaec6562f6e57e9d047efe9c7a6030

8 years agoupstream commit
dtucker@openbsd.org [Fri, 6 Jan 2017 02:26:10 +0000 (02:26 +0000)] 
upstream commit

Account for timeouts in the integrity tests as failures.

If the first test in a series for a given MAC happens to modify the low
bytes of a packet length, then ssh will time out and this will be
interpreted as a test failure.  Patch from cjwatson at debian.org via
bz#2658.

Upstream-Regress-ID: e7467613b0badedaa300bc6fc7495ec2f44e2fb9

8 years agoupstream commit
dtucker@openbsd.org [Fri, 6 Jan 2017 02:09:25 +0000 (02:09 +0000)] 
upstream commit

Make forwarding test less racy by using unix domain
sockets instead of TCP ports where possible.  Patch from cjwatson at
debian.org via bz#2659.

Upstream-Regress-ID: 4756375aac5916ef9d25452a1c1d5fa9e90299a9

8 years agoupstream commit
dtucker@openbsd.org [Sun, 29 Jan 2017 21:35:23 +0000 (21:35 +0000)] 
upstream commit

Fix typo in ~C error message for bad port forward
cancellation. bz#2672, from Brad Marshall via Colin Watson and Ubuntu's
bugtracker.

Upstream-ID: 0d4a7e5ead6cc59c9a44b4c1e5435ab3aada09af

8 years agoupstream commit
guenther@openbsd.org [Sat, 21 Jan 2017 11:32:04 +0000 (11:32 +0000)] 
upstream commit

The POSIX APIs that that sockaddrs all ignore the s*_len
field in the incoming socket, so userspace doesn't need to set it unless it
has its own reasons for tracking the size along with the sockaddr.

ok phessler@ deraadt@ florian@

Upstream-ID: ca6e49e2f22f2b9e81d6d924b90ecd7e422e7437

8 years agoupstream commit
jmc@openbsd.org [Fri, 6 Jan 2017 16:28:12 +0000 (16:28 +0000)] 
upstream commit

keep the tokens list sorted;

Upstream-ID: b96239dae4fb3aa94146bb381afabcc7740a1638

8 years agoupstream commit
djm@openbsd.org [Fri, 6 Jan 2017 09:27:52 +0000 (09:27 +0000)] 
upstream commit

fix previous

Upstream-ID: c107d6a69bc22325d79fbf78a2a62e04bcac6895

8 years agoupstream commit
djm@openbsd.org [Fri, 6 Jan 2017 03:53:58 +0000 (03:53 +0000)] 
upstream commit

show a useful error message when included config files
can't be opened; bz#2653, ok dtucker@

Upstream-ID: f598b73b5dfe497344cec9efc9386b4e5a3cb95b

8 years agoupstream commit
djm@openbsd.org [Fri, 6 Jan 2017 03:45:41 +0000 (03:45 +0000)] 
upstream commit

sshd_config is documented to set
GSSAPIStrictAcceptorCheck=yes by default, so actually make it do this.
bz#2637 ok dtucker

Upstream-ID: 99ef8ac51f17f0f7aec166cb2e34228d4d72a665

8 years agoupstream commit
djm@openbsd.org [Fri, 6 Jan 2017 03:41:58 +0000 (03:41 +0000)] 
upstream commit

Avoid confusing error message when attempting to use
ssh-keyscan built without SSH protocol v.1 to scan for v.1 keys; bz#2583

Upstream-ID: 5d214abd3a21337d67c6dcc5aa6f313298d0d165

8 years agoupstream commit
dtucker@openbsd.org [Fri, 6 Jan 2017 02:34:54 +0000 (02:34 +0000)] 
upstream commit

Re-add '%k' token for AuthorizedKeysCommand which was
lost during the re-org in rev 1.235.  bz#2656, from jboning at gmail.com.

Upstream-ID: 2884e203c02764d7b3fe7472710d9c24bdc73e38

8 years agoupstream commit
djm@openbsd.org [Wed, 4 Jan 2017 05:37:40 +0000 (05:37 +0000)] 
upstream commit

unbreak Unix domain socket forwarding for root; ok
markus@

Upstream-ID: 6649c76eb7a3fa15409373295ca71badf56920a2

8 years agoRemove LOGIN_PROGRAM.
Darren Tucker [Sun, 15 Jan 2017 22:08:32 +0000 (09:08 +1100)] 
Remove LOGIN_PROGRAM.

UseLogin is gone, remove leftover.  bz#2665, from cjwatson at debian.org

8 years agoupstream commit
djm@openbsd.org [Wed, 4 Jan 2017 02:21:43 +0000 (02:21 +0000)] 
upstream commit

relax PKCS#11 whitelist a bit to allow libexec as well as
lib directories.

Upstream-ID: cf5617958e2e2d39f8285fd3bc63b557da484702

8 years agoupstream commit
djm@openbsd.org [Tue, 3 Jan 2017 05:46:51 +0000 (05:46 +0000)] 
upstream commit

check number of entries in SSH2_FXP_NAME response; avoids
unreachable overflow later. Reported by Jann Horn

Upstream-ID: b6b2b434a6d6035b1644ca44f24cd8104057420f

8 years agoupstream commit
djm@openbsd.org [Fri, 30 Dec 2016 22:08:02 +0000 (22:08 +0000)] 
upstream commit

fix deadlock when keys/principals command produces a lot of
output and a key is matched early; bz#2655, patch from jboning AT gmail.com

Upstream-ID: e19456429bf99087ea994432c16d00a642060afe

8 years agoRe-add missing "Prerequisites" header and fix typo
Darren Tucker [Tue, 20 Dec 2016 01:16:11 +0000 (12:16 +1100)] 
Re-add missing "Prerequisites" header and fix typo

Patch from HARUYAMA Seigo <haruyama at unixuser org>.

8 years agoupstream commit
djm@openbsd.org [Mon, 19 Dec 2016 22:35:23 +0000 (22:35 +0000)] 
upstream commit

use standard /bin/sh equality test; from Mike Frysinger

Upstream-Regress-ID: 7b6f0b63525f399844c8ac211003acb8e4b0bec2

8 years agocrank version numbers for release V_7_4_P1
Damien Miller [Mon, 19 Dec 2016 04:59:26 +0000 (15:59 +1100)] 
crank version numbers for release

8 years agoupstream commit
djm@openbsd.org [Mon, 19 Dec 2016 04:55:51 +0000 (04:55 +0000)] 
upstream commit

openssh-7.4

Upstream-ID: 1ee404adba6bbe10ae9277cbae3a94abe2867b79

8 years agoupstream commit
djm@openbsd.org [Mon, 19 Dec 2016 04:55:18 +0000 (04:55 +0000)] 
upstream commit

remove testcase that depends on exact output and
behaviour of snprintf(..., "%s", NULL)

Upstream-Regress-ID: cab4288531766bd9593cb556613b91a2eeefb56f

8 years agoupstream commit
dtucker@openbsd.org [Mon, 19 Dec 2016 03:32:57 +0000 (03:32 +0000)] 
upstream commit

Use LOGNAME to get current user and fall back to whoami if
not set. Mainly to benefit -portable since some platforms don't have whoami.

Upstream-Regress-ID: e3a16b7836a3ae24dc8f8a4e43fdf8127a60bdfa

8 years agoupstream commit
dtucker@openbsd.org [Fri, 16 Dec 2016 03:51:19 +0000 (03:51 +0000)] 
upstream commit

Add regression test for AllowUsers and DenyUsers.  Patch from
Zev Weiss <zev at bewilderbeest.net>

Upstream-Regress-ID: 8f1aac24d52728398871dac14ad26ea38b533fb9

8 years agoAdd missing monitor.h include.
Darren Tucker [Fri, 16 Dec 2016 04:02:24 +0000 (15:02 +1100)] 
Add missing monitor.h include.

Fixes warning pointed out by Zev Weiss <zev at bewilderbeest.net>

8 years agoupstream commit
djm@openbsd.org [Fri, 16 Dec 2016 02:48:55 +0000 (02:48 +0000)] 
upstream commit

revert to rev1.2; the new bits in this test depend on changes
to ssh that aren't yet committed

Upstream-Regress-ID: 828ffc2c7afcf65d50ff2cf3dfc47a073ad39123

8 years agoupstream commit
dtucker@openbsd.org [Fri, 16 Dec 2016 01:06:27 +0000 (01:06 +0000)] 
upstream commit

Move the "stop sshd" code into its own helper function.
Patch from Zev Weiss <zev at bewilderbeest.net>, ok djm@

Upstream-Regress-ID: a113dea77df5bd97fb4633ea31f3d72dbe356329

8 years agoupstream commit
djm@openbsd.org [Fri, 16 Dec 2016 01:01:07 +0000 (01:01 +0000)] 
upstream commit

regression test for certificates along with private key
with no public half. bz#2617, mostly from Adam Eijdenberg

Upstream-Regress-ID: 2e74dc2c726f4dc839609b3ce045466b69f01115

8 years agoupstream commit
dtucker@openbsd.org [Thu, 15 Dec 2016 23:50:37 +0000 (23:50 +0000)] 
upstream commit

Use $SUDO to read pidfile in case root's umask is
restricted.  From portable.

Upstream-Regress-ID: f6b1c7ffbc5a0dfb7d430adb2883344899174a98

8 years agoupstream commit
dtucker@openbsd.org [Thu, 15 Dec 2016 21:29:05 +0000 (21:29 +0000)] 
upstream commit

Add missing braces in DenyUsers code.  Patch from zev at
bewilderbeest.net, ok deraadt@

Upstream-ID: d747ace338dcf943b077925f90f85f789714b54e

8 years agoupstream commit
dtucker@openbsd.org [Thu, 15 Dec 2016 21:20:41 +0000 (21:20 +0000)] 
upstream commit

Fix text in error message.  Patch from zev at
bewilderbeest.net.

Upstream-ID: deb0486e175e7282f98f9a15035d76c55c84f7f6

8 years agoupstream commit
djm@openbsd.org [Wed, 14 Dec 2016 00:36:34 +0000 (00:36 +0000)] 
upstream commit

disable Unix-domain socket forwarding when privsep is
disabled

Upstream-ID: ab61516ae0faadad407857808517efa900a0d6d0

8 years agoupstream commit
djm@openbsd.org [Fri, 9 Dec 2016 03:04:29 +0000 (03:04 +0000)] 
upstream commit

log connections dropped in excess of MaxStartups at
verbose LogLevel; bz#2613 based on diff from Tomas Kuthan; ok dtucker@

Upstream-ID: 703ae690dbf9b56620a6018f8a3b2389ce76d92b

8 years agoGet default of TEST_SSH_UTF8 from environment.
Darren Tucker [Tue, 13 Dec 2016 02:51:32 +0000 (13:51 +1100)] 
Get default of TEST_SSH_UTF8 from environment.

8 years agoRemove commented-out includes.
Darren Tucker [Tue, 13 Dec 2016 01:56:40 +0000 (12:56 +1100)] 
Remove commented-out includes.

These commented-out includes have "Still needed?" comments.  Since
they've been commented out for ~13 years I assert that they're not.

8 years agoAdd prototype for strcasestr in compat library.
Darren Tucker [Tue, 13 Dec 2016 01:54:23 +0000 (12:54 +1100)] 
Add prototype for strcasestr in compat library.

8 years agoAdd strcasestr to compat library.
Darren Tucker [Mon, 12 Dec 2016 23:23:03 +0000 (10:23 +1100)] 
Add strcasestr to compat library.

Fixes build on (at least) Solaris 10.

8 years agoForce Turkish locales back to C/POSIX; bz#2643
Damien Miller [Mon, 12 Dec 2016 02:57:10 +0000 (13:57 +1100)] 
Force Turkish locales back to C/POSIX; bz#2643

Turkish locales are unique in their handling of the letters 'i' and
'I' (yes, they are different letters) and OpenSSH isn't remotely
prepared to deal with that. For now, the best we can do is to force
OpenSSH to use the C/POSIX locale and try to preserve the UTF-8
encoding if possible.

ok dtucker@

8 years agoexit is in stdlib.h not unistd.h (that's _exit).
Darren Tucker [Fri, 9 Dec 2016 01:52:02 +0000 (12:52 +1100)] 
exit is in stdlib.h not unistd.h (that's _exit).

8 years agoInclude <unistd.h> for exit in utf8 locale test.
Darren Tucker [Fri, 9 Dec 2016 01:33:25 +0000 (12:33 +1100)] 
Include <unistd.h> for exit in utf8 locale test.

8 years agoCheck for utf8 local support before testing it.
Darren Tucker [Thu, 8 Dec 2016 04:48:34 +0000 (15:48 +1100)] 
Check for utf8 local support before testing it.

Check for utf8 local support and if not found, do not attempt to run the
utf8 tests.  Suggested by djm@

8 years agoUse AC_PATH_TOOL for krb5-config.
Darren Tucker [Thu, 8 Dec 2016 01:57:24 +0000 (12:57 +1100)] 
Use AC_PATH_TOOL for krb5-config.

This will use the host-prefixed version when cross compiling; patch from
david.michael at coreos.com.

8 years agoupstream commit
djm@openbsd.org [Tue, 6 Dec 2016 07:48:01 +0000 (07:48 +0000)] 
upstream commit

make IdentityFile successfully load and use certificates that
have no corresponding bare public key. E.g. just a private id_rsa and
certificate id_rsa-cert.pub (and no id_rsa.pub).

bz#2617 ok dtucker@

Upstream-ID: c1e9699b8c0e3b63cc4189e6972e3522b6292604