]> git.ipfire.org Git - thirdparty/openssh-portable.git/log
thirdparty/openssh-portable.git
8 weeks agoupstream: Save return value from sshbuf_len instead of calling it
dtucker@openbsd.org [Mon, 16 Jun 2025 08:49:27 +0000 (08:49 +0000)] 
upstream: Save return value from sshbuf_len instead of calling it

multiple times. Fixes Coverity CID 470521.

OpenBSD-Regress-ID: 356b8b43c8a232deaf445c1ff7526577b177a8e9

2 months agoupstream: Plug leak. Coverity CID 405058.
dtucker@openbsd.org [Fri, 13 Jun 2025 07:35:14 +0000 (07:35 +0000)] 
upstream: Plug leak. Coverity CID 405058.

OpenBSD-Regress-ID: 7fb2fce68d2cb063cdb94d5d66f84fa3a2902792

2 months agoupstream: Remove dead code flagged by Coverity CID 307783. ok djm@
dtucker@openbsd.org [Fri, 13 Jun 2025 07:23:07 +0000 (07:23 +0000)] 
upstream: Remove dead code flagged by Coverity CID 307783. ok djm@

OpenBSD-Regress-ID: e579f5ec2fd2eb2fe2bad654d16f2ba655a3e035

2 months agoupstream: Set user, host and path to NULL immediately before calling
dtucker@openbsd.org [Thu, 12 Jun 2025 10:09:39 +0000 (10:09 +0000)] 
upstream: Set user, host and path to NULL immediately before calling

parse_user_host_path in tests.  This ensures that we don't accidentally use
the previous value if the function under test doesn't set them Also fixes
Coverity CIDs 405056 405065 405066.

OpenBSD-Regress-ID: 43678ff59001712f32214fe303b1c21c163c2960

2 months agoupstream: Plug mem leak on error path here too.
dtucker@openbsd.org [Thu, 12 Jun 2025 09:26:57 +0000 (09:26 +0000)] 
upstream: Plug mem leak on error path here too.

Coverity CID 307781.

OpenBSD-Regress-ID: 18e053d9b661fbb4227d3db03172077c1216bb2e

2 months agoupstream: Plug mem leak on error path.
dtucker@openbsd.org [Thu, 12 Jun 2025 09:19:43 +0000 (09:19 +0000)] 
upstream: Plug mem leak on error path.

Coverity CID 307776.

OpenBSD-Regress-ID: c44246690973e1b8643e51079a2faa7ace26490c

2 months agoupstream: Remove dead code ternary. We always report at least
dtucker@openbsd.org [Wed, 11 Jun 2025 13:27:11 +0000 (13:27 +0000)] 
upstream: Remove dead code ternary. We always report at least

KB/s, so B/s is never used.  Coverity CID 291809, ok djm@

OpenBSD-Commit-ID: a67c5bcc9e19c8965bfeace0e337b13660efa058

2 months agoupstream: Improve termination condition of while loop to compare
dtucker@openbsd.org [Wed, 11 Jun 2025 13:24:05 +0000 (13:24 +0000)] 
upstream: Improve termination condition of while loop to compare

size_t's.  Assuming read() does what it's supposed to this shouldn't matter,
but should be more robust.  Flagged by Coverity CID 470514, ok djm@

OpenBSD-Commit-ID: d7b5ad60feb797b3464964b9ea67fd78fb9d6cc6

2 months agoReplace Windows 2019 runners with 2025 ones.
Darren Tucker [Tue, 10 Jun 2025 08:40:56 +0000 (18:40 +1000)] 
Replace Windows 2019 runners with 2025 ones.

The windows-2019 runners are being decomissioned.

2 months agoDisable _FORTIFY_SOURCE during snprintf test.
Darren Tucker [Wed, 4 Jun 2025 08:33:52 +0000 (18:33 +1000)] 
Disable _FORTIFY_SOURCE during snprintf test.

Prevents mistakenly detecting snprintf as broken on FreeBSD 15 with
_FORTIFY_SOURCE enabled.  bz#3809, patch from jlduran at gmail.com

2 months agoupstream: Fix x11_channel_used_recently() to return true when channel
dtucker@openbsd.org [Mon, 2 Jun 2025 14:09:34 +0000 (14:09 +0000)] 
upstream: Fix x11_channel_used_recently() to return true when channel

has been used within the last second, instead of more than a second ago.
Should fix ~5s delay on X client startup when ObscureKeystrokeTiming is
enabled. bz#3820, ok (& sigh) djm@

OpenBSD-Commit-ID: b741011e81fb3e3d42711d9bd3ed8a959924dee4

2 months agoupstream: When there's more than one x11 channel in use, return
dtucker@openbsd.org [Thu, 29 May 2025 13:27:27 +0000 (13:27 +0000)] 
upstream: When there's more than one x11 channel in use, return

lastused of most recently used x11 channel instead of the last one found. ok
djm@

OpenBSD-Commit-ID: 94a72bf988d40a5bae2e38608f4e117f712569fe

2 months agoupstream: replace xmalloc+memset(0) with xcalloc(); from AZero13 via
djm@openbsd.org [Sat, 24 May 2025 11:41:51 +0000 (11:41 +0000)] 
upstream: replace xmalloc+memset(0) with xcalloc(); from AZero13 via

GHPR417

OpenBSD-Commit-ID: 921079436a4900325d22bd3b6a90c8d0d54f62f8

2 months agoupstream: fix punctuation around host key fingerprints to make them
djm@openbsd.org [Sat, 24 May 2025 09:46:16 +0000 (09:46 +0000)] 
upstream: fix punctuation around host key fingerprints to make them

easier to copy and paste.

Patch from Till Maas via GHPR556; ok dtucker@

OpenBSD-Commit-ID: c0100182a30b6925c8cdb2225b18140264594b7b

2 months agoupstream: Replace strncmp + byte count with strprefix in Penalty
dtucker@openbsd.org [Sat, 24 May 2025 08:13:29 +0000 (08:13 +0000)] 
upstream: Replace strncmp + byte count with strprefix in Penalty

config parsing. ok kn@, djm@

OpenBSD-Commit-ID: 34a41bb1b9ba37fb6c7eb29a7ea909547bf02a5a

2 months agoupstream: Make the display number check relative to
dtucker@openbsd.org [Sat, 24 May 2025 08:09:32 +0000 (08:09 +0000)] 
upstream: Make the display number check relative to

X11DisplayOffset.

This will allows people to use X11DisplayOffset to configure much higher
port ranges if they really want, while not changing the default behaviour.
Patch from Roman Gubarev via github PR#559, ok djm@

OpenBSD-Commit-ID: e0926af5dc0c11e364452b624c3ad0cda88550b5

2 months agoRemove progressmeter.o from libssh.a.
Darren Tucker [Sat, 24 May 2025 07:20:57 +0000 (17:20 +1000)] 
Remove progressmeter.o from libssh.a.

It's now explicitly included by the binaries that need it (scp & sftp).
bz#3810, patch from jlduran at gmail.com

2 months agoupstream: Null out keys between test runs.
dtucker@openbsd.org [Sat, 24 May 2025 06:50:28 +0000 (06:50 +0000)] 
upstream: Null out keys between test runs.

BENCH_START and BENCH_FINISH are actually a while() loop in disguise,
so if sshkey_generate does not reset the key pointer on failure the test
may incorrectly pass.  It also confuses Coverity (CID 551234).

OpenBSD-Regress-ID: bf4d32079fc6df6dce1f26c2025f4ed492f13936

2 months agoupstream: add some verbosity
djm@openbsd.org [Sat, 24 May 2025 04:41:12 +0000 (04:41 +0000)] 
upstream: add some verbosity

OpenBSD-Regress-ID: 11c86cda4435b5f9ab6172c4742b95899666c977

2 months agoupstream: use start_ssh_agent() to ensure we get logging
djm@openbsd.org [Sat, 24 May 2025 04:41:03 +0000 (04:41 +0000)] 
upstream: use start_ssh_agent() to ensure we get logging

add some verbosity

OpenBSD-Regress-ID: a89bf64696b9fb1b91be318e6b8940c9ab21c616

2 months agoupstream: add a start_ssh_agent() function that sets up an agent
djm@openbsd.org [Sat, 24 May 2025 04:40:37 +0000 (04:40 +0000)] 
upstream: add a start_ssh_agent() function that sets up an agent

with logging

OpenBSD-Regress-ID: 7f9f30f9c64acbd4b418a5e1a19140cc988071a8

2 months agoupstream: Plug leak of startup_pollfd in debug and child paths.
dtucker@openbsd.org [Sat, 24 May 2025 06:43:37 +0000 (06:43 +0000)] 
upstream: Plug leak of startup_pollfd in debug and child paths.

Coverity CID 405024, ok djm@

OpenBSD-Commit-ID: db46047229253e9c4470c8bbf5f82706ac021377

2 months agossh-keygen changes were fixup'ed into single commit.
Darren Tucker [Sat, 24 May 2025 07:11:38 +0000 (17:11 +1000)] 
ssh-keygen changes were fixup'ed into single commit.

2 months agoauth-pam: Check the user didn't change during PAM transaction
Marco Trevisan (Treviño) [Mon, 30 Sep 2024 11:14:11 +0000 (13:14 +0200)] 
auth-pam: Check the user didn't change during PAM transaction

PAM modules can change the user during their execution, in such case ssh
would still use the user that has been provided giving potentially
access to another user with the credentials of another one.

So prevent this to happen, by ensuring that the final PAM user is
matching the one that initiated the transaction.

2 months agoupstream: Remove ssh-keygen's moduli screen -Omemory option.
dtucker@openbsd.org [Sat, 24 May 2025 03:37:40 +0000 (03:37 +0000)] 
upstream: Remove ssh-keygen's moduli screen -Omemory option.

This vaguely made sense 20 years ago, but these days you'd be hard
pressed to *find* a machine small enough to not support the maximum
(127MB), and no one is screening moduli on such machines anyway,
so just use the max.  This also fixes Coverity CID 470522 by deleting
code in question.  "kill it with fire" djm@.

OpenBSD-Commit-ID: 39036aa406a99f0a91923aa3a96afff1205558e6

2 months agoupstream: Fix compile error on 32bit platforms.
dtucker@openbsd.org [Sat, 24 May 2025 02:33:33 +0000 (02:33 +0000)] 
upstream: Fix compile error on 32bit platforms.

Spotted by & ok tb@

OpenBSD-Commit-ID: cbcf518247886f3c7518fc54cb3bd911ffc69db7

2 months agoupstream: Use pointer from strprefix in error message,
dtucker@openbsd.org [Sat, 24 May 2025 02:01:28 +0000 (02:01 +0000)] 
upstream: Use pointer from strprefix in error message,

missed in previous.

OpenBSD-Commit-ID: d2cdec6cf0fcd4b0ee25e4e3fad8bc8cf0ee657d

2 months agoupstream: Replace strncmp and strncasecmp with hand-counting bytes
dtucker@openbsd.org [Fri, 23 May 2025 12:52:45 +0000 (12:52 +0000)] 
upstream: Replace strncmp and strncasecmp with hand-counting bytes

with strprefix. nits lucas@, ok lucas@ djm@

OpenBSD-Commit-ID: f0888807f151ea2bdaf6fed36303ae81f259d1d4

2 months agoupstream: Include stdint.h for UINT32_MAX.
dtucker@openbsd.org [Fri, 23 May 2025 11:54:50 +0000 (11:54 +0000)] 
upstream: Include stdint.h for UINT32_MAX.

OpenBSD-Commit-ID: edc29ed67e8bd03bac729d9b4849066d1d3a8cb9

2 months agoupstream: Ensure args to nh_update() fit within uint32, which it
dtucker@openbsd.org [Fri, 23 May 2025 11:25:35 +0000 (11:25 +0000)] 
upstream: Ensure args to nh_update() fit within uint32, which it

should always anyway. Placates Coverity CID 470520.  While there, fix the
upstream URL.  ok djm@

OpenBSD-Commit-ID: 2478e89fde089a49fa02f9faf6287d35959c9f92

2 months agoupstream: Don't leak the args list. Coverity CIDs 481569 & 481570,
dtucker@openbsd.org [Fri, 23 May 2025 09:26:25 +0000 (09:26 +0000)] 
upstream: Don't leak the args list. Coverity CIDs 481569 & 481570,

ok job@ tb@.

OpenBSD-Commit-ID: becabcd00513d13d1435b68b7ccffa7151b72393

2 months agoupstream: Explictly set LC_ALL=C on each sort invocation.
dtucker@openbsd.org [Fri, 23 May 2025 08:40:13 +0000 (08:40 +0000)] 
upstream: Explictly set LC_ALL=C on each sort invocation.

Remove it from sshd_config (where it could be overridden by shell startup
scripts, eg on macos-15) causing random test failures.  with & ok djm@

OpenBSD-Regress-ID: ad0a6678964784096e9a9e6d15ead36beed92f18

2 months agoAllow setting LTESTS in repo variables.
Darren Tucker [Fri, 23 May 2025 06:39:18 +0000 (16:39 +1000)] 
Allow setting LTESTS in repo variables.

2 months agoRename debugging variable RUN_ONLY_TEST.
Darren Tucker [Fri, 23 May 2025 06:26:20 +0000 (16:26 +1000)] 
Rename debugging variable RUN_ONLY_TEST.

to RUN_ONLY_TARGET_CONFIG to make it more obvious what it matches.

2 months agochown regress logs before uploading.
Darren Tucker [Fri, 23 May 2025 06:11:48 +0000 (16:11 +1000)] 
chown regress logs before uploading.

2 months agoupstream: Import regenerated moduli.
dtucker@openbsd.org [Fri, 23 May 2025 01:14:35 +0000 (01:14 +0000)] 
upstream: Import regenerated moduli.

OpenBSD-Commit-ID: 07e29dc891e29b31e03e2e5493658b4a9ac19431

2 months agoupstream: use "const char * const" for malloc_options here also
deraadt@openbsd.org [Fri, 23 May 2025 00:40:45 +0000 (00:40 +0000)] 
upstream: use "const char * const" for malloc_options here also

OpenBSD-Commit-ID: 869715b9c7e1dd5b85efd07814e7e53f0286eea2

2 months agoupstream: Adjust debug message to prevent (unsigned) integer overflow.
dtucker@openbsd.org [Thu, 22 May 2025 12:14:19 +0000 (12:14 +0000)] 
upstream: Adjust debug message to prevent (unsigned) integer overflow.

Fixes Coverity CID 481110, ok djm@

OpenBSD-Commit-ID: 26178bf3b812707fb498ea85d076cadd1f2eb686

2 months agoupstream: Fix OpenBSD RCS ID typos. from Andrius V
bluhm@openbsd.org [Thu, 22 May 2025 04:34:18 +0000 (04:34 +0000)] 
upstream: Fix OpenBSD RCS ID typos. from Andrius V

OpenBSD-Regress-ID: 5c03a2ef5323969fc4978f2eec4f1a25c48c572a

2 months agoRemove debug change accidentally commited.
Darren Tucker [Thu, 22 May 2025 12:09:48 +0000 (22:09 +1000)] 
Remove debug change accidentally commited.

Fixes Coverity CID 481160.

2 months agoCollect all of regress dir on failure.
Darren Tucker [Thu, 22 May 2025 11:16:37 +0000 (21:16 +1000)] 
Collect all of regress dir on failure.

This may allow us to sort through its entrails and determine the cause
of some types of failures.

2 months agominimal shims for fstatat(2)/unlinkat(2) in agent
Damien Miller [Thu, 22 May 2025 08:42:44 +0000 (18:42 +1000)] 
minimal shims for fstatat(2)/unlinkat(2) in agent

Add some very minimal and task-specific replacements for
fstatat(2) and unlinkat(2) in the ssh-agent socket cleanup
loop, for platforms that lack these functions. ok dtucker@

2 months agoupstream: Output the current name for PermitRootLogin's
dtucker@openbsd.org [Thu, 22 May 2025 04:22:03 +0000 (04:22 +0000)] 
upstream: Output the current name for PermitRootLogin's

"prohibit-password" in sshd -T instead of its deprecated alias
"without-password".  bz#3788, patch from cjwatson at debian.org.

OpenBSD-Commit-ID: 2d5df18d5ad33a9b6c7547ec78a8e6ea13813df9

2 months agoupstream: Copy arg to be passed to dirname().
dtucker@openbsd.org [Thu, 22 May 2025 03:53:46 +0000 (03:53 +0000)] 
upstream: Copy arg to be passed to dirname().

POSIX allows dirname() to modify its args and return a pointer into it,
so this prevents an overlapping strlcpy.  bz#3819, patch from cjwatson
at debian.org

OpenBSD-Commit-ID: c32e496e6a1618aba31c8b7a9d4e1376c5ea6aa1

2 months agoupstream: Add $OpenBSD$ marker for easier syncing.
dtucker@openbsd.org [Thu, 22 May 2025 03:41:10 +0000 (03:41 +0000)] 
upstream: Add $OpenBSD$ marker for easier syncing.

OpenBSD-Commit-ID: 27ff3e1e2e6610d9981ebe43ae9b783236800035

2 months agoupstream: Correct FILES section to mention new default path to
djm@openbsd.org [Wed, 21 May 2025 12:12:20 +0000 (12:12 +0000)] 
upstream: Correct FILES section to mention new default path to

agent sockets. Spotted by / ok jmc@

OpenBSD-Commit-ID: 91d736d78d71a4276c9cbb075b1462bbc3df55a6

2 months agoFix nc install some more.
Darren Tucker [Thu, 22 May 2025 02:25:35 +0000 (12:25 +1000)] 
Fix nc install some more.

2 months agoFix cvs up of nc.
Darren Tucker [Thu, 22 May 2025 02:21:11 +0000 (12:21 +1000)] 
Fix cvs up of nc.

2 months agoInstall nc during upstream test.
Darren Tucker [Thu, 22 May 2025 01:34:04 +0000 (11:34 +1000)] 
Install nc during upstream test.

This ensures that the installed nc matches the expectations of the
regress tests.

2 months agoRemove 9.7 branch from CI status page.
Darren Tucker [Thu, 22 May 2025 00:52:31 +0000 (10:52 +1000)] 
Remove 9.7 branch from CI status page.

It's been obsolete long enough that github no longer reports its
status.

2 months agopull a small netcat SOCKS4A fix from upstream
Damien Miller [Wed, 21 May 2025 09:14:47 +0000 (19:14 +1000)] 
pull a small netcat SOCKS4A fix from upstream

2 months agoupstream: test SOCKS4A; ok tb
djm@openbsd.org [Wed, 21 May 2025 08:41:52 +0000 (08:41 +0000)] 
upstream: test SOCKS4A; ok tb

OpenBSD-Regress-ID: d880b75280295cd581a86e39bb0996d347f122d2

2 months agoupstream: remove log tarballing "it seemed like a good idea at the
djm@openbsd.org [Wed, 21 May 2025 08:36:39 +0000 (08:36 +0000)] 
upstream: remove log tarballing "it seemed like a good idea at the

time" - dtucker@

ensure that log files have correct perms when running under sudo/doas

ok dtucker@

OpenBSD-Regress-ID: 20588c14b05de9519f85d638b374b66ae0678c89

2 months agoupstream: use logit_f("...") instead of logit("func: ...")
djm@openbsd.org [Wed, 21 May 2025 06:44:24 +0000 (06:44 +0000)] 
upstream: use logit_f("...") instead of logit("func: ...")

OpenBSD-Commit-ID: c8d49eb39a9abff3cbcaeaf7df9d48468a5a0695

2 months agoupstream: function to make a sshbuf from a hex string; useful in
djm@openbsd.org [Wed, 21 May 2025 06:43:48 +0000 (06:43 +0000)] 
upstream: function to make a sshbuf from a hex string; useful in

tests

also constify some arguments

OpenBSD-Commit-ID: 00f9c25b256be0efd73f2d8268ff041bc45ffb2c

2 months agomerge netcat SOCKS4A support from OpenBSD
Damien Miller [Wed, 21 May 2025 08:47:46 +0000 (18:47 +1000)] 
merge netcat SOCKS4A support from OpenBSD

Not a full sync of this file as we have diverged substantially
from upstream (it has libtls support, etc.)

2 months agoInclude OpenSSL compat shim where needed.
Darren Tucker [Tue, 20 May 2025 12:17:02 +0000 (22:17 +1000)] 
Include OpenSSL compat shim where needed.

2 months agoRun all tests on Cygwin again.
Darren Tucker [Tue, 20 May 2025 09:28:55 +0000 (19:28 +1000)] 
Run all tests on Cygwin again.

... now that we've fixed ci-setup on Cygwin.

2 months agoUse USERNAME rather than LOGNAME on Cygwin.
Darren Tucker [Tue, 20 May 2025 08:48:23 +0000 (18:48 +1000)] 
Use USERNAME rather than LOGNAME on Cygwin.

LOGNAME is specified by POSIX, but Windows (or at least, github's
Windows images) don't set it.

2 months agoAdd debug output when setting up CI environment.
Darren Tucker [Tue, 20 May 2025 08:28:52 +0000 (18:28 +1000)] 
Add debug output when setting up CI environment.

2 months agoInclude openssl compat shims in test.
Darren Tucker [Tue, 20 May 2025 09:16:38 +0000 (19:16 +1000)] 
Include openssl compat shims in test.

Fixes tests on platforms using older LibreSSL releases prior to 3.4.

2 months agoAdd compat shims for EC_POINT affine_coordinates
Darren Tucker [Tue, 20 May 2025 08:14:06 +0000 (18:14 +1000)] 
Add compat shims for EC_POINT affine_coordinates

LibreSSL <3.4 does not have EC_POINT_[gs]et_affine_coordinates
but does have the now-deprecated _GFp variantes.  We still support
LibreSSL back as far as 3.2.x so add a compat shim.

2 months agoupstream: Use EC_POINT_[sg]et_affine_coordinates()
tb@openbsd.org [Mon, 12 May 2025 05:42:02 +0000 (05:42 +0000)] 
upstream: Use EC_POINT_[sg]et_affine_coordinates()

It is available in all supported OpenSSL flavors/versions and the _GFp
variants will be removed from LibreSSL.

ok hshoexer jsing

OpenBSD-Regress-ID: 66cf1561e7b6c49002978f2d6720956f33a882f0

2 months agoupstream: Use EC_POINT_[sg]et_affine_coordinates()
tb@openbsd.org [Mon, 12 May 2025 05:41:20 +0000 (05:41 +0000)] 
upstream: Use EC_POINT_[sg]et_affine_coordinates()

It is available in all supported OpenSSL flavors/versions and the _GFp
variants will be removed from LibreSSL.

ok hshoexer jsing

OpenBSD-Commit-ID: ecedca0e1ffa80e0c9ef7c787bc6a972882c596b

2 months agoupstream: make the progress-meter code safe against being called
djm@openbsd.org [Fri, 9 May 2025 02:42:03 +0000 (02:42 +0000)] 
upstream: make the progress-meter code safe against being called

when not initialised; spotted by tb@ feedback/ok tb@ deraadt@

OpenBSD-Commit-ID: a9fda1ee08a24c62e0981ff6d15ca93b63467038

2 months agoupstream: convert a last quad_t to int64_t. ok deraadt djm
tedu@openbsd.org [Thu, 8 May 2025 17:32:53 +0000 (17:32 +0000)] 
upstream: convert a last quad_t to int64_t. ok deraadt djm

OpenBSD-Commit-ID: 1c9e01ba1a9ccf442a9cdf10f222077f66885f1f

2 months agoSet runner pasword to random string.
Darren Tucker [Tue, 20 May 2025 05:01:29 +0000 (15:01 +1000)] 
Set runner pasword to random string.

The most recent version of the Github ubuntu-latest image sets the
password field to "!" which sshd considers to be a locked account,
breaking most of the tests.

3 months agoDebug log for why an account is considered locked.
Darren Tucker [Sun, 11 May 2025 12:54:13 +0000 (22:54 +1000)] 
Debug log for why an account is considered locked.

3 months agoMove debug log output into separate workflow step.
Darren Tucker [Sun, 11 May 2025 06:35:31 +0000 (16:35 +1000)] 
Move debug log output into separate workflow step.

Should reduce the need to scroll back to find out which test actually
failed.

3 months agoSkip sftp-perm on Cygwin too.
Darren Tucker [Sat, 10 May 2025 11:48:06 +0000 (21:48 +1000)] 
Skip sftp-perm on Cygwin too.

3 months agoRemove CYGWIN binmode as it's now obsolete.
Darren Tucker [Sat, 10 May 2025 00:23:30 +0000 (10:23 +1000)] 
Remove CYGWIN binmode as it's now obsolete.

3 months agoAlso skip sftp-cmds test on Cygwin.
Darren Tucker [Fri, 9 May 2025 23:25:18 +0000 (09:25 +1000)] 
Also skip sftp-cmds test on Cygwin.

Fails at the hardlink step.

3 months agoTell Cygwin to use native symlinks.
Darren Tucker [Fri, 9 May 2025 22:52:11 +0000 (08:52 +1000)] 
Tell Cygwin to use native symlinks.

3 months agoSkip keygen-knownhost test on Cygwin.
Darren Tucker [Fri, 9 May 2025 22:26:37 +0000 (08:26 +1000)] 
Skip keygen-knownhost test on Cygwin.

It fails but at this time it's not clear why.

3 months agoPass Cygwin setup location to CI setup.
Darren Tucker [Fri, 9 May 2025 21:59:44 +0000 (07:59 +1000)] 
Pass Cygwin setup location to CI setup.

(instead of hard coding it, wrongly).

3 months agoAdd RUN_ONLY_TEST to limit which tests are run.
Darren Tucker [Fri, 9 May 2025 20:37:24 +0000 (06:37 +1000)] 
Add RUN_ONLY_TEST to limit which tests are run.

For testing, you can set the repo variable RUN_ONLY_TEST in your repo
(Repo -> Settings -> Security -> Actions -> Variables) to run only that test.

3 months agoMove misc-agent.o to LIBSSH_OBJS.
Darren Tucker [Fri, 9 May 2025 09:32:06 +0000 (19:32 +1000)] 
Move misc-agent.o to LIBSSH_OBJS.

It's needed by the fuzzer.

3 months agoPut PRIV_ECDSA back, it's still used.
Darren Tucker [Fri, 9 May 2025 09:08:36 +0000 (19:08 +1000)] 
Put PRIV_ECDSA back, it's still used.

Should fix oss-fuzz test.

3 months agoSince it's unused, make dirfd() take void *.
Darren Tucker [Thu, 8 May 2025 08:56:39 +0000 (18:56 +1000)] 
Since it's unused, make dirfd() take void *.

Some platforms (eg Old BSDs) in some configurations define DIR to "void
*", which causes compile errors in the no-op implementation.

3 months agoAdd no-op implmentation of dirfd().
Darren Tucker [Thu, 8 May 2025 01:38:24 +0000 (11:38 +1000)] 
Add no-op implmentation of dirfd().

Fixes build on pre-POSIX.1 2008 systems.

3 months agossh-agent: exit 0 from SIGTERM under systemd socket-activation
Daniel Kahn Gillmor [Wed, 16 Apr 2025 00:18:34 +0000 (10:18 +1000)] 
ssh-agent: exit 0 from SIGTERM under systemd socket-activation

When the ssh-agent service is configured to be launched under systemd
socket-activation, the user can inspect the status of the agent with
something like:

    systemctl --user status ssh-agent.service

If the user does:

    systemctl --user stop ssh-agent.service

it causes the `systemd --user` supervisor to send a SIGTERM to the
agent, which terminates while leaving the systemd-managed socket in
place.  That's good, and as expected. (If the user wants to close the
socket, they can do "systemctl --user stop ssh-agent.socket" instead)

But because ssh-agent exits with code 2 in response to a SIGTERM, the
supervisor marks the service as "failed", even though the state of the
supervised service is exactly the same as during session startup (not
running, ready to launch when a client connects to the socket).

This change makes ssh-agent exit cleanly (code 0) in response to a
SIGTERM when launched under socket activation. This aligns the systemd
supervisor's understanding of the state of supervised ssh-agent with
reality.

Signed-off-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
3 months agoSkip d_type check on platforms that don't have it.
Darren Tucker [Wed, 7 May 2025 11:05:06 +0000 (21:05 +1000)] 
Skip d_type check on platforms that don't have it.

On those, the subsequent stat() should catch the sockets.

3 months agoupstream: Rename sockaddr_un sun -> sunaddr.
dtucker@openbsd.org [Wed, 7 May 2025 10:44:26 +0000 (10:44 +0000)] 
upstream: Rename sockaddr_un sun -> sunaddr.

This makes things easier in -portable, where on Solaris an derivatives
"sun" is defined to "1", causing compilation errors.  ok deraadt@.

OpenBSD-Commit-ID: 0669043afb49856b57b382f0489221bd98305d3b

3 months agoupstream: remove DSA from the regression/unit test suite too.
djm@openbsd.org [Tue, 6 May 2025 06:05:48 +0000 (06:05 +0000)] 
upstream: remove DSA from the regression/unit test suite too.

OpenBSD-Regress-ID: 4424d2eaf0bce3887318ef6d18de6c06f3617d6e

3 months agoupstream: another missing ifdef
djm@openbsd.org [Tue, 15 Apr 2025 05:31:24 +0000 (05:31 +0000)] 
upstream: another missing ifdef

OpenBSD-Regress-ID: 4f71f8f122eac4cbf7f1d2088a9be45317dd3e4a

3 months agoupstream: missing ifdef
djm@openbsd.org [Tue, 15 Apr 2025 05:00:13 +0000 (05:00 +0000)] 
upstream: missing ifdef

OpenBSD-Regress-ID: 7260fb672de5738c17dec06c71a5be0186bb2b09

3 months agoupstream: memory leak on error path; bz3821
djm@openbsd.org [Wed, 7 May 2025 04:10:21 +0000 (04:10 +0000)] 
upstream: memory leak on error path; bz3821

OpenBSD-Commit-ID: 65577596a15ad6dd9a1ab3fc24c1c31303ee6e2b

3 months agoupstream: test ssh-agent with the -T flag to force the old /tmp
deraadt@openbsd.org [Tue, 6 May 2025 15:15:05 +0000 (15:15 +0000)] 
upstream: test ssh-agent with the -T flag to force the old /tmp

location rather than inside the homedir.  During relink operation,
/.ssh/agent was created which is surprising.  This test sequence could use
some improvement so this is a temporary fix. observed by florian, change ok
semarie

OpenBSD-Commit-ID: c7246a6b519ac390ca550719f91acfdaef1fa0f0

3 months agoupstream: finally remove DSA signature support from OpenSSH.
djm@openbsd.org [Tue, 6 May 2025 05:40:56 +0000 (05:40 +0000)] 
upstream: finally remove DSA signature support from OpenSSH.

feedback/ok tb@, ok deraadt@

OpenBSD-Commit-ID: bfe6ee73c1b676c81a2901030c791f8ec888228f

3 months agoupstream: Now that there's an I-D for certificate keys, refer to
djm@openbsd.org [Mon, 5 May 2025 05:51:11 +0000 (05:51 +0000)] 
upstream: Now that there's an I-D for certificate keys, refer to

that instead of the much more basic format description we had previously.

OpenBSD-Commit-ID: cf01e0727a813fee8626ad7b3aa240621cc92014

3 months agoupstream: - add full stop to the text in -a - move the -U and -u
jmc@openbsd.org [Mon, 5 May 2025 05:47:28 +0000 (05:47 +0000)] 
upstream: - add full stop to the text in -a - move the -U and -u

text to the correct place

OpenBSD-Commit-ID: 2fb484337a0978c703f61983bb14bc5cbaf898c2

3 months agoAdd minimal implementations of fstatat and unlinkat.
Darren Tucker [Tue, 6 May 2025 09:01:00 +0000 (19:01 +1000)] 
Add minimal implementations of fstatat and unlinkat.

Fixes build on some pre-POSIX.1-2008 platforms.

3 months agoNew location of cygwin setup.
Darren Tucker [Mon, 5 May 2025 22:15:34 +0000 (08:15 +1000)] 
New location of cygwin setup.

3 months agoBoringssl now puts libcrypto in a different place.
Darren Tucker [Mon, 5 May 2025 22:07:23 +0000 (08:07 +1000)] 
Boringssl now puts libcrypto in a different place.

3 months agoHandle systems that don't have st_mtim.
Darren Tucker [Mon, 5 May 2025 10:45:42 +0000 (20:45 +1000)] 
Handle systems that don't have st_mtim.

Ignores nanoseconds, but it's checking for >1h old so a few nanoseconds
shouldn't matter much.  Fixes build on Mac OS X.

3 months agoSupply timespecsub if needed.
Darren Tucker [Mon, 5 May 2025 09:09:25 +0000 (19:09 +1000)] 
Supply timespecsub if needed.

3 months agoincludes.h for compat, time.h for clock_gettime.
Darren Tucker [Mon, 5 May 2025 09:08:48 +0000 (19:08 +1000)] 
includes.h for compat, time.h for clock_gettime.

3 months agoCygwin install in back on D:
Darren Tucker [Mon, 5 May 2025 08:51:34 +0000 (18:51 +1000)] 
Cygwin install in back on D:

3 months agodepend
Damien Miller [Mon, 5 May 2025 04:59:30 +0000 (14:59 +1000)] 
depend

3 months agoupstream: missing file in previous commit
djm@openbsd.org [Mon, 5 May 2025 03:35:06 +0000 (03:35 +0000)] 
upstream: missing file in previous commit

OpenBSD-Commit-ID: e526c97fcb2fd9f0b7b229720972426ab437d7eb