]> git.ipfire.org Git - thirdparty/openssh-portable.git/log
thirdparty/openssh-portable.git
4 weeks agoUpdate pledge() interface to match current OpenBSD.
Darren Tucker [Thu, 25 Sep 2025 08:06:55 +0000 (18:06 +1000)] 
Update pledge() interface to match current OpenBSD.

ok djm@

4 weeks agoMerge all putty tests into a single test.
Darren Tucker [Tue, 23 Sep 2025 12:12:19 +0000 (22:12 +1000)] 
Merge all putty tests into a single test.

The lets us reuse the built OpenSSH binaries and replaces 12*4min of
tests with a single 14min one.

4 weeks agoAdd #ifdefs in pwfree to match those in pwcopy.
Darren Tucker [Thu, 25 Sep 2025 08:20:53 +0000 (18:20 +1000)] 
Add #ifdefs in pwfree to match those in pwcopy.

Fixes build on many platforms.

4 weeks agoupstream: fix some one-off leaks in ssh.c; ok dtucker@
djm@openbsd.org [Thu, 25 Sep 2025 07:05:11 +0000 (07:05 +0000)] 
upstream: fix some one-off leaks in ssh.c; ok dtucker@

OpenBSD-Commit-ID: bf3c27ffe4b3cccb6553b554ec4c04929065a2bc

4 weeks agoupstream: fix some one-off leaks in ssh-keygen; ok dtucker@
djm@openbsd.org [Thu, 25 Sep 2025 07:04:38 +0000 (07:04 +0000)] 
upstream: fix some one-off leaks in ssh-keygen; ok dtucker@

OpenBSD-Commit-ID: 32f51289c93246474659aa49067926fcab9e02e8

4 weeks agoupstream: fix some leaks in ssh-add; feedback/ok dtucker@
djm@openbsd.org [Thu, 25 Sep 2025 07:00:43 +0000 (07:00 +0000)] 
upstream: fix some leaks in ssh-add; feedback/ok dtucker@

OpenBSD-Commit-ID: 441302917de31a128c1d6d63acccc67042fcf349

4 weeks agoupstream: fix some leaks; feedback/ok dtucker@
djm@openbsd.org [Thu, 25 Sep 2025 06:57:54 +0000 (06:57 +0000)] 
upstream: fix some leaks; feedback/ok dtucker@

OpenBSD-Commit-ID: 05bdbc2e494b87a4a79e509020bd8249c86a4ff0

4 weeks agoupstream: wait for the unprivileged sshd-auth process to exit
djm@openbsd.org [Thu, 25 Sep 2025 06:45:50 +0000 (06:45 +0000)] 
upstream: wait for the unprivileged sshd-auth process to exit

before closing the fd it uses to report log messages

This avoids a race where the child process notices the
fd was closed before exiting and spams the logs.

ok dtucker@

OpenBSD-Commit-ID: 7cddaa41be3b955e6bed570900db7ab8817b1e76

4 weeks agoupstream: add some functions to free various structs, including
djm@openbsd.org [Thu, 25 Sep 2025 06:33:19 +0000 (06:33 +0000)] 
upstream: add some functions to free various structs, including

channels data and packet state; ok dtucker@ tb@

OpenBSD-Commit-ID: a8b3705309d632cdae370d4147a03e703087b0d1

4 weeks agoupstream: fix leaks of config objects in
djm@openbsd.org [Thu, 25 Sep 2025 06:31:42 +0000 (06:31 +0000)] 
upstream: fix leaks of config objects in

mm_decode_activate_server_options ok dtucker@ tb@

OpenBSD-Commit-ID: 211f4d7d02e847bd1bcb460f6beb11658809a742

4 weeks agoupstream: clarify intent and avoid (harmess, defined behaviour)
djm@openbsd.org [Thu, 25 Sep 2025 06:25:38 +0000 (06:25 +0000)] 
upstream: clarify intent and avoid (harmess, defined behaviour)

unsigned underflow. ok tb@

OpenBSD-Commit-ID: b73bf5f1f381c3e4561a6cc706fb1cd77c939cd8

4 weeks agoupstream: consistently use NULL for null pointer constants found
jsg@openbsd.org [Thu, 25 Sep 2025 06:23:19 +0000 (06:23 +0000)] 
upstream: consistently use NULL for null pointer constants found

with sparse, ok djm@

OpenBSD-Commit-ID: 1067504b63732d809d0d57ad4bc626818d112772

4 weeks agoupstream: remove unneeded externs ok djm@
jsg@openbsd.org [Thu, 25 Sep 2025 02:15:39 +0000 (02:15 +0000)] 
upstream: remove unneeded externs ok djm@

OpenBSD-Commit-ID: fe553193e910a122505142a4e1db7358cc1ae653

4 weeks agoupstream: remove prototype for removed ssh_packet_set_tos() ok
jsg@openbsd.org [Thu, 25 Sep 2025 02:12:16 +0000 (02:12 +0000)] 
upstream: remove prototype for removed ssh_packet_set_tos() ok

djm@

OpenBSD-Commit-ID: 396f82995074ef4d7b9ce44168266ef4640d9985

4 weeks agoupstream: spelling; ok dtucker@
jsg@openbsd.org [Wed, 24 Sep 2025 00:51:28 +0000 (00:51 +0000)] 
upstream: spelling; ok dtucker@

OpenBSD-Commit-ID: 93870117b0153859dd8baa80b97e44d4558c786b

5 weeks agoMerge VM tests into a single workflow file.
Darren Tucker [Tue, 23 Sep 2025 06:51:34 +0000 (16:51 +1000)] 
Merge VM tests into a single workflow file.

Should make it easier to manage, although it may cause a few extra runs.

5 weeks agoTest openssl-3.6 branch not beta1.
Darren Tucker [Tue, 23 Sep 2025 06:38:45 +0000 (16:38 +1000)] 
Test openssl-3.6 branch not beta1.

5 weeks agoTest openssl-3.6.0-beta1.
Darren Tucker [Tue, 23 Sep 2025 05:51:14 +0000 (15:51 +1000)] 
Test openssl-3.6.0-beta1.

5 weeks agoSpecify rpath when building OpenSSL.
Darren Tucker [Tue, 23 Sep 2025 01:32:57 +0000 (11:32 +1000)] 
Specify rpath when building OpenSSL.

5 weeks agoFactor out OpenSSL install and test more versions.
Darren Tucker [Mon, 22 Sep 2025 05:26:17 +0000 (15:26 +1000)] 
Factor out OpenSSL install and test more versions.

Move OpenSSL installation into its own script with a "-a" option to
install the "next" version to test for ABI compatibility.

5 weeks agoExclude generated openbsd-compat/include directory.
Darren Tucker [Mon, 22 Sep 2025 06:55:49 +0000 (16:55 +1000)] 
Exclude generated openbsd-compat/include directory.

5 weeks agoAdd OpenSSL 3.x ABI cross-compatibility test.
Darren Tucker [Sat, 20 Sep 2025 05:07:36 +0000 (15:07 +1000)] 
Add OpenSSL 3.x ABI cross-compatibility test.

5 weeks agoAdd tests for OpenSSL 3.4 and 3.5 versions.
Darren Tucker [Sat, 20 Sep 2025 05:05:19 +0000 (15:05 +1000)] 
Add tests for OpenSSL 3.4 and 3.5 versions.

5 weeks agoBuild OpenSSL with -j4 to speed it up.
Darren Tucker [Sat, 20 Sep 2025 05:53:04 +0000 (15:53 +1000)] 
Build OpenSSL with -j4 to speed it up.

5 weeks agoRerun tests if run_tests.sh changes.
Darren Tucker [Sat, 20 Sep 2025 05:16:30 +0000 (15:16 +1000)] 
Rerun tests if run_tests.sh changes.

5 weeks agoupstream: log at level INFO when PerSourcePenalties actually blocks
djm@openbsd.org [Fri, 19 Sep 2025 01:32:45 +0000 (01:32 +0000)] 
upstream: log at level INFO when PerSourcePenalties actually blocks

access to a source address range. Previously this was logged at level
VERBOSE, which hid enforcement actions under default config settings.

ok dtucker, markus

OpenBSD-Commit-ID: ea2b0d7c2253ff5205719d74b526cf2870df894d

6 weeks agoWhitespace.
Darren Tucker [Wed, 17 Sep 2025 07:41:41 +0000 (17:41 +1000)] 
Whitespace.

6 weeks agoMove Gihub VMs to their own status line.
Darren Tucker [Wed, 17 Sep 2025 07:33:25 +0000 (17:33 +1000)] 
Move Gihub VMs to their own status line.

6 weeks agoUse relative URLs for status
Darren Tucker [Tue, 16 Sep 2025 13:00:14 +0000 (23:00 +1000)] 
Use relative URLs for status

6 weeks agoAdd VM test targets via vmaction on Github.
Darren Tucker [Mon, 15 Sep 2025 07:21:15 +0000 (17:21 +1000)] 
Add VM test targets via vmaction on Github.

6 weeks agoupstream: memory leaks in unit tests
djm@openbsd.org [Mon, 15 Sep 2025 03:00:22 +0000 (03:00 +0000)] 
upstream: memory leaks in unit tests

OpenBSD-Regress-ID: af11ac7b8034b99ca324af4dae1ef5cd7700b273

6 weeks agoupstream: fix leaks of struct sftp_conn in scp; ok dtucker@
djm@openbsd.org [Mon, 15 Sep 2025 05:17:37 +0000 (05:17 +0000)] 
upstream: fix leaks of struct sftp_conn in scp; ok dtucker@

OpenBSD-Commit-ID: 76bea50b5b87b750c3771bf80feb6067d994a9d2

6 weeks agoupstream: leak of principals file lines; ok dtucker@
djm@openbsd.org [Mon, 15 Sep 2025 04:52:41 +0000 (04:52 +0000)] 
upstream: leak of principals file lines; ok dtucker@

OpenBSD-Commit-ID: 918bf1b70e5a969059300f3c23d45911690d9015

6 weeks agoupstream: leak of authentication options at exit; ok dtucker@
djm@openbsd.org [Mon, 15 Sep 2025 04:52:12 +0000 (04:52 +0000)] 
upstream: leak of authentication options at exit; ok dtucker@

OpenBSD-Commit-ID: ba559799c2ff9b10afc3abefb1797c0843a6ff24

6 weeks agoupstream: memleak of keys not used for authentication; ok
djm@openbsd.org [Mon, 15 Sep 2025 04:51:35 +0000 (04:51 +0000)] 
upstream: memleak of keys not used for authentication; ok

dtucker@

OpenBSD-Commit-ID: ddfda79d243150fbd382d8f2cd75a90a072b3669

6 weeks agoupstream: memleak of certificate path; ok dtucker@
djm@openbsd.org [Mon, 15 Sep 2025 04:50:42 +0000 (04:50 +0000)] 
upstream: memleak of certificate path; ok dtucker@

OpenBSD-Commit-ID: 90dc5390f2756ba339e2e6df54d4b8651d64c1e7

6 weeks agoupstream: memleak of hostkey when downgrading host cert->key; ok
djm@openbsd.org [Mon, 15 Sep 2025 04:49:41 +0000 (04:49 +0000)] 
upstream: memleak of hostkey when downgrading host cert->key; ok

dtucker

OpenBSD-Commit-ID: f6f1f38a8ec144fb615434f6877066cf4610b826

6 weeks agoupstream: memleak of editline history; ok dtucker@
djm@openbsd.org [Mon, 15 Sep 2025 04:49:00 +0000 (04:49 +0000)] 
upstream: memleak of editline history; ok dtucker@

OpenBSD-Commit-ID: a244c54eb074cf7fbe28f7ac4f03ace270f7a999

6 weeks agoupstream: memleak of rfwd callback context; ok dtucker@
djm@openbsd.org [Mon, 15 Sep 2025 04:48:29 +0000 (04:48 +0000)] 
upstream: memleak of rfwd callback context; ok dtucker@

OpenBSD-Commit-ID: 70b2aafeaace90703dd16a44a2a0b723d9155f33

6 weeks agoupstream: memleaks of request packet and hostkeys blob; ok
djm@openbsd.org [Mon, 15 Sep 2025 04:47:49 +0000 (04:47 +0000)] 
upstream: memleaks of request packet and hostkeys blob; ok

dtucker@

OpenBSD-Commit-ID: 313b13a8e36b4ca8e064ee56792e67e0670a386a

6 weeks agoupstream: memleak of KRL revoked certs struct; ok dtucker
djm@openbsd.org [Mon, 15 Sep 2025 04:41:20 +0000 (04:41 +0000)] 
upstream: memleak of KRL revoked certs struct; ok dtucker

OpenBSD-Commit-ID: f319868e0b2de49c41c735e75b87c403f009f5f9

6 weeks agoupstream: memleak of kex->server_sig_algs; ok dtucker@
djm@openbsd.org [Mon, 15 Sep 2025 04:40:34 +0000 (04:40 +0000)] 
upstream: memleak of kex->server_sig_algs; ok dtucker@

OpenBSD-Commit-ID: 41a3f64edd2c9b8addb2e445514ae25c24819e2c

6 weeks agoupstream: fix memleak of channel forwarding permissions; ok
djm@openbsd.org [Mon, 15 Sep 2025 04:39:58 +0000 (04:39 +0000)] 
upstream: fix memleak of channel forwarding permissions; ok

dtucker@

OpenBSD-Commit-ID: 069745547109bc8fcc09fab5b19c53599cae99fd

6 weeks agoupstream: when merging auth options into the active set, don't
djm@openbsd.org [Mon, 15 Sep 2025 04:39:15 +0000 (04:39 +0000)] 
upstream: when merging auth options into the active set, don't

leak the old struct sshauthopt; ok dtucker@

OpenBSD-Commit-ID: c6bfd7bc2932e37f811b3c53272c3b919d33e75b

6 weeks agoupstream: fix memleak when applying certificate options; ok
djm@openbsd.org [Mon, 15 Sep 2025 04:38:00 +0000 (04:38 +0000)] 
upstream: fix memleak when applying certificate options; ok

dtucker

OpenBSD-Commit-ID: 36c219dcc05f4df82a0f9c500bdf5dbfea925289

6 weeks agoupstream: disable ssh-add autoexpiry of certificates when testing
djm@openbsd.org [Thu, 11 Sep 2025 07:23:32 +0000 (07:23 +0000)] 
upstream: disable ssh-add autoexpiry of certificates when testing

expired certificates

OpenBSD-Regress-ID: 64aadd23d37fd0b3a06498151f2cf83be7ac342c

6 weeks agoupstream: correct getopt() string
djm@openbsd.org [Thu, 11 Sep 2025 07:22:37 +0000 (07:22 +0000)] 
upstream: correct getopt() string

OpenBSD-Commit-ID: 05ef9581a3dab32ec93aa5b9c3349ed1e7da9ec8

7 weeks agoupstream: need time.h for time(3)
djm@openbsd.org [Thu, 11 Sep 2025 03:29:58 +0000 (03:29 +0000)] 
upstream: need time.h for time(3)

OpenBSD-Commit-ID: 530964039cccab679432b6c5b28d2b0aa9760b00

7 weeks agoupstream: When adding certificates to an agent, set the expiry to
djm@openbsd.org [Thu, 11 Sep 2025 02:54:42 +0000 (02:54 +0000)] 
upstream: When adding certificates to an agent, set the expiry to

the certificate expiry time plus a short (5 min) grace period.

This will cause the agent to automtically remove certificates shortly
after they expire.

A new ssh-add -N option disables this behaviour.

Feedback/ok deraadt@

OpenBSD-Commit-ID: 92fed1bba1025069ad45deebb534be7530e181df

7 weeks agoupstream: remove unused 0-sized files; ok deraadt@
jsg@openbsd.org [Mon, 8 Sep 2025 00:31:54 +0000 (00:31 +0000)] 
upstream: remove unused 0-sized files; ok deraadt@

OpenBSD-Commit-ID: 7e8178786157e863f6ff63c5d55200d7b6b04f9e

7 weeks agoupstream: Tabs->spaces. Removes diff vs portable.
dtucker@openbsd.org [Fri, 5 Sep 2025 10:34:35 +0000 (10:34 +0000)] 
upstream: Tabs->spaces. Removes diff vs portable.

OpenBSD-Commit-ID: 06598021a9f08188dab29ac956b2baa002a0ff85

7 weeks ago modified: regress/rekey.sh
Tim Rice [Mon, 8 Sep 2025 19:53:10 +0000 (12:53 -0700)] 
modified:   regress/rekey.sh
Fix for when building out of tree.

7 weeks agoAccept OpenSSL 4.0.0-dev versions.
Darren Tucker [Sun, 7 Sep 2025 03:35:22 +0000 (13:35 +1000)] 
Accept OpenSSL 4.0.0-dev versions.

They seem to work, at least for now.

7 weeks agoUse SSH_TUN_COMPAT_AF on FreeBSD.
Maxim Khon [Mon, 18 Aug 2025 12:05:42 +0000 (12:05 +0000)] 
Use SSH_TUN_COMPAT_AF on FreeBSD.

Otherwise tun forwarding from other OSes fails as soon as the first IPv6
message is sent by the other side (which is usually a Router Solicitation
ICMPv6 message which is sent as soon as the interface is up): all other
OS'es use SSH_TUN_COMPAT_AF or SSH_TUN_PREPEND_AF which effectively uses
OpenBSD AF_INET/AF_INET6 values.

7 weeks agoCheck for nlist function.
Darren Tucker [Fri, 5 Sep 2025 11:32:30 +0000 (21:32 +1000)] 
Check for nlist function.

Check for nlist function presence before attenmpting to use it instead
of relying on the presence of the nlist.h header.  Mac OS X, in particular
has the header, but only has the function in the 32bit libraries.

7 weeks agoupstream: Order includes as per KNF and add time.h. Removes diff
dtucker@openbsd.org [Fri, 5 Sep 2025 10:23:55 +0000 (10:23 +0000)] 
upstream: Order includes as per KNF and add time.h. Removes diff

vs portable.

OpenBSD-Commit-ID: 38043f0bfa17c48ef6d1a744c2834b4405bc9311

7 weeks agoupstream: Order headers as per KNF. Removes diff vs portable.
dtucker@openbsd.org [Fri, 5 Sep 2025 10:17:21 +0000 (10:17 +0000)] 
upstream: Order headers as per KNF. Removes diff vs portable.

OpenBSD-Commit-ID: 4df519fd9fa13ce9653adf7a3d1076e20591d886

7 weeks agoupstream: Order headers as per KNF.
dtucker@openbsd.org [Fri, 5 Sep 2025 10:01:35 +0000 (10:01 +0000)] 
upstream: Order headers as per KNF.

OpenBSD-Commit-ID: 7156b69b0364c68e181e0f6fa17c0f05c72e8670

7 weeks agoResync header order with upstream.
Darren Tucker [Fri, 5 Sep 2025 10:39:16 +0000 (20:39 +1000)] 
Resync header order with upstream.

7 weeks agoResync header order with upstream.
Darren Tucker [Fri, 5 Sep 2025 10:37:04 +0000 (20:37 +1000)] 
Resync header order with upstream.

7 weeks agoSync includes with upstream.
Darren Tucker [Fri, 5 Sep 2025 10:30:20 +0000 (20:30 +1000)] 
Sync includes with upstream.

7 weeks agoMove ssh-pkcs11.h include to match upstream.
Darren Tucker [Fri, 5 Sep 2025 10:26:14 +0000 (20:26 +1000)] 
Move ssh-pkcs11.h include to match upstream.

7 weeks agoReorder includes to match upstream.
Darren Tucker [Fri, 5 Sep 2025 10:20:27 +0000 (20:20 +1000)] 
Reorder includes to match upstream.

7 weeks agoupstream: Order headers as per KNF. Removes diff vs portable.
dtucker@openbsd.org [Fri, 5 Sep 2025 09:58:08 +0000 (09:58 +0000)] 
upstream: Order headers as per KNF. Removes diff vs portable.

OpenBSD-Commit-ID: db72be57429418f6a4319bbe34c98fc103e11ce0

7 weeks agoupstream: Order headers as per KNF. Also removes diff vs
dtucker@openbsd.org [Fri, 5 Sep 2025 09:49:26 +0000 (09:49 +0000)] 
upstream: Order headers as per KNF. Also removes diff vs

-portable.

OpenBSD-Commit-ID: 2061307dc938712e524bc9da48a52f545e43670e

7 weeks agoupstream: Remove unused rmd160.h header. ripemd160 support was
dtucker@openbsd.org [Fri, 5 Sep 2025 09:31:31 +0000 (09:31 +0000)] 
upstream: Remove unused rmd160.h header. ripemd160 support was

removed in 2017.

OpenBSD-Commit-ID: 937fca21498b921adf6e04bac120f4a2e7975b3c

7 weeks agoCreate replacement nlist.h if needed.
Darren Tucker [Fri, 5 Sep 2025 10:07:16 +0000 (20:07 +1000)] 
Create replacement nlist.h if needed.

Remove #ifdef HAVE_NLIST_H wrapper.  ok djm@

7 weeks agoCreate replacement endian.h if needed.
Darren Tucker [Fri, 5 Sep 2025 09:55:20 +0000 (19:55 +1000)] 
Create replacement endian.h if needed.

Remove #ifdef HAVE_ENDIAN_H wrapper.  ok djm@

7 weeks agoAdd /* WITH_OPENSSL */ comments.
Darren Tucker [Fri, 5 Sep 2025 09:52:48 +0000 (19:52 +1000)] 
Add /* WITH_OPENSSL */ comments.

Removes diffs vs upstream.

7 weeks agoMove sys/time.h include to match upstream.
Darren Tucker [Fri, 5 Sep 2025 09:22:37 +0000 (19:22 +1000)] 
Move sys/time.h include to match upstream.

7 weeks agoCreate replacement netgroup.h if needed.
Darren Tucker [Fri, 5 Sep 2025 09:13:52 +0000 (19:13 +1000)] 
Create replacement netgroup.h if needed.

Remove #ifdef HAVE_NETGROUP_H wrapper.  ok djm@

7 weeks agoRemove stray #endif left from previous.
Darren Tucker [Fri, 5 Sep 2025 08:24:59 +0000 (18:24 +1000)] 
Remove stray #endif left from previous.

7 weeks agoCreate replacement libgen.h if needed.
Darren Tucker [Fri, 5 Sep 2025 08:08:51 +0000 (18:08 +1000)] 
Create replacement libgen.h if needed.

Remove #ifdef HAVE_LIBGEN_H wrapper.  ok djm@

7 weeks agoCreate replacement sys/un.h if needed.
Darren Tucker [Fri, 5 Sep 2025 08:05:15 +0000 (18:05 +1000)] 
Create replacement sys/un.h if needed.

Remove #ifdef HAVE_SYS_UN_H wrapper.  ok djm@

7 weeks agoReformat replacement header check one per line.
Darren Tucker [Fri, 5 Sep 2025 08:03:55 +0000 (18:03 +1000)] 
Reformat replacement header check one per line.

7 weeks agoCreate replacement time.h if needed.
Darren Tucker [Fri, 5 Sep 2025 07:55:33 +0000 (17:55 +1000)] 
Create replacement time.h if needed.

Remove #ifdef HAVE_TIME_H wrapper.  ok djm@

7 weeks agoCreate replacement sys/stat.h if needed.
Darren Tucker [Fri, 5 Sep 2025 07:50:18 +0000 (17:50 +1000)] 
Create replacement sys/stat.h if needed.

Remove #ifdef HAVE_SYS_STAT_H wrapper.  ok djm@

7 weeks agoCreate replacement sys/time.h if needed.
Darren Tucker [Fri, 5 Sep 2025 07:44:07 +0000 (17:44 +1000)] 
Create replacement sys/time.h if needed.

Remove #ifdef HAVE_SYS_TIME_H wrapper.  ok djm@

7 weeks agoCreate replacement ifaddrs.h if needed.
Darren Tucker [Fri, 5 Sep 2025 07:31:15 +0000 (17:31 +1000)] 
Create replacement ifaddrs.h if needed.

Remove #ifdef HAVE_IFADDRS_H wrapper.  ok djm@

7 weeks agoCreate replacement util.h if needed.
Darren Tucker [Fri, 5 Sep 2025 07:27:43 +0000 (17:27 +1000)] 
Create replacement util.h if needed.

Remove #ifdef HAVE_UTIL_H wrapper.  ok djm@

7 weeks agoCreate replacement paths.h if needed.
Darren Tucker [Fri, 5 Sep 2025 07:24:50 +0000 (17:24 +1000)] 
Create replacement paths.h if needed.

Remove #ifdef HAVE_PATHS_H wrapper.  ok djm@

7 weeks agoCreate replacement poll.h if needed.
Darren Tucker [Fri, 5 Sep 2025 07:17:52 +0000 (17:17 +1000)] 
Create replacement poll.h if needed.

Remove #ifdef HAVE_POLL_H wrapper.  ok djm@

7 weeks agoFill in missing system header files.
Darren Tucker [Fri, 5 Sep 2025 07:06:14 +0000 (17:06 +1000)] 
Fill in missing system header files.

Create replacement header files inside openbsd-compat for common headers
that are missing on a given platform.  Usually these are just empty,
but in some cases they'll include the equivalent file.  This avoids
having to wrap those includes in '#ifdef HAVE_FOO_H' and reduces the
diff vs OpenBSD.

If we create any such headers, add the path to includes.

Initially just stdint.h, more to follow.

ok djm@

8 weeks agoupstream: repair test after changes to percent expansion of usernames
djm@openbsd.org [Thu, 4 Sep 2025 03:04:44 +0000 (03:04 +0000)] 
upstream: repair test after changes to percent expansion of usernames

on the commandline.

Test more cases that should/shouldn't expand and lightly test
username validity checks.

OpenBSD-Regress-ID: ad4c12c70bdf1f959abfebd1637ecff1b49a484c

8 weeks agoupstream: unit tests for sshbuf_equals and sshbuf_dtourlb64; ok
djm@openbsd.org [Thu, 4 Sep 2025 00:37:10 +0000 (00:37 +0000)] 
upstream: unit tests for sshbuf_equals and sshbuf_dtourlb64; ok

deraadt@

OpenBSD-Regress-ID: bab54e2d4caa813036a63ee67e92c93e6712a5b9

8 weeks agoupstream: unit tests for a bunch of misc.c functions; ok deraadt@
djm@openbsd.org [Thu, 4 Sep 2025 00:34:17 +0000 (00:34 +0000)] 
upstream: unit tests for a bunch of misc.c functions; ok deraadt@

OpenBSD-Regress-ID: 886cf142605405e777ee77a96b48694dc2e9235d

8 weeks agoupstream: fix sshbuf_dtourlb64() to not choke on empty buffers;
djm@openbsd.org [Thu, 4 Sep 2025 00:32:31 +0000 (00:32 +0000)] 
upstream: fix sshbuf_dtourlb64() to not choke on empty buffers;

previously it incorrectly returned an error in this situation; ok deraadt

OpenBSD-Commit-ID: e62773d6e8cb95a19aab54f0af0edbcd47b345c0

8 weeks agoupstream: fix rtrim() function to not attempt to delete whitespace
djm@openbsd.org [Thu, 4 Sep 2025 00:31:49 +0000 (00:31 +0000)] 
upstream: fix rtrim() function to not attempt to delete whitespace

inside a string, just at the end. ok deraadt@

OpenBSD-Commit-ID: d44deaa43580cd88de978dd5509b14e905b67b84

8 weeks agoupstream: don't allow \0 characters in url-encoded strings.
djm@openbsd.org [Thu, 4 Sep 2025 00:30:06 +0000 (00:30 +0000)] 
upstream: don't allow \0 characters in url-encoded strings.

Suggested by David Leadbeater, ok deraadt@

OpenBSD-Commit-ID: c92196cef0f970ceabc1e8007a80b01e9b7cd49c

8 weeks agoupstream: Improve rules for %-expansion of username.
djm@openbsd.org [Thu, 4 Sep 2025 00:29:09 +0000 (00:29 +0000)] 
upstream: Improve rules for %-expansion of username.

Usernames passed on the commandline will no longer be subject to
% expansion. Some tools invoke ssh with connection information
(i.e. usernames and host names) supplied from untrusted sources.
These may contain % expansion sequences which could yield
unexpected results.

Since openssh-9.6, all usernames have been subject to validity
checking. This change tightens the validity checks by refusing
usernames that include control characters (again, these can cause
surprises when supplied adversarially).

This change also relaxes the validity checks in one small way:
usernames supplied via the configuration file as literals (i.e.
include no % expansion characters) are not subject to these
validity checks. This allows usernames that contain arbitrary
characters to be used, but only via configuration files. This
is done on the basis that ssh's configuration is trusted.

Pointed out by David Leadbeater, ok deraadt@

OpenBSD-Commit-ID: e2f0c871fbe664aba30607321575e7c7fc798362

8 weeks agomissing header
Damien Miller [Tue, 2 Sep 2025 23:42:39 +0000 (09:42 +1000)] 
missing header

8 weeks agoupstream: simplify algorithm list functions using xextendf(); ok
djm@openbsd.org [Tue, 2 Sep 2025 11:08:34 +0000 (11:08 +0000)] 
upstream: simplify algorithm list functions using xextendf(); ok

dtucker@

OpenBSD-Commit-ID: ffc5f8d0c25b95705a8a66c8b634f98d23bd92dc

8 weeks agoupstream: unit test for xextendf()
djm@openbsd.org [Tue, 2 Sep 2025 11:04:58 +0000 (11:04 +0000)] 
upstream: unit test for xextendf()

OpenBSD-Regress-ID: ddb3b4db1a52dda23696b967470882fe2b9c3af7

8 weeks agoupstream: fix comment on sshbuf_froms() - it *returns* an error
djm@openbsd.org [Tue, 2 Sep 2025 09:41:23 +0000 (09:41 +0000)] 
upstream: fix comment on sshbuf_froms() - it *returns* an error

code, the allocated buffer is passed via argument

OpenBSD-Commit-ID: b2b0a76df71328f39c3e2ad941a4d87085d8335d

8 weeks agoupstream: GssStrictAcceptor was missing from sshd -T output; fix
djm@openbsd.org [Tue, 2 Sep 2025 09:40:19 +0000 (09:40 +0000)] 
upstream: GssStrictAcceptor was missing from sshd -T output; fix

OpenBSD-Commit-ID: 6014049ccfedc48a208e37d5488ade6bdc2d1c44

8 weeks agoportable-specific comment grammer/spelling fixes
Damien Miller [Tue, 2 Sep 2025 09:38:39 +0000 (19:38 +1000)] 
portable-specific comment grammer/spelling fixes

8 weeks agoupstream: grammar and typos in comments
djm@openbsd.org [Tue, 2 Sep 2025 09:34:48 +0000 (09:34 +0000)] 
upstream: grammar and typos in comments

OpenBSD-Commit-ID: de954daffcd0147ce142d55e8a374810cd19d7ed

8 weeks agoreplace remaining manual logging of __func__
Damien Miller [Tue, 2 Sep 2025 09:30:07 +0000 (19:30 +1000)] 
replace remaining manual logging of __func__

Use the appropriate log macro that prepends the function name
(e.g. logit_f/debug2_f/etc).

8 weeks agoupstream: replace remaining cases where we manually included __func__
djm@openbsd.org [Tue, 2 Sep 2025 09:26:21 +0000 (09:26 +0000)] 
upstream: replace remaining cases where we manually included __func__

in a debug or error log with the respective *_f log variant

OpenBSD-Commit-ID: 46a280d78bcc0bc98f28e65a30b613366600328f

8 weeks agoupstream: test MaxStatups idempotency; ok dtucker@
djm@openbsd.org [Mon, 1 Sep 2025 23:55:29 +0000 (23:55 +0000)] 
upstream: test MaxStatups idempotency; ok dtucker@

OpenBSD-Regress-ID: b5d713c2709000fa5e41d82c0cf8627e13cb43f9