1
0
mirror of https://github.com/openbsd/src.git synced 2026-06-18 07:13:36 +02:00
Commit Graph

245099 Commits

Author SHA1 Message Date
djm e83fdb4948 fix multiple problems with testing hostkey types that are
not enabled by default.

1) Add all hostkey types in the "multiple hostkeys" subtest.
   Previously known_hosts was accidentally clobbered, causing
   only the last added hostkey type to be used.
2) Explicitly enable the hostkey types under test via
   HostKeyAlgorithms
2026-06-15 01:55:44 +00:00
jsg be4ef8762b move drm_dev_register() call to before connector test and check return 2026-06-15 01:52:53 +00:00
jsg 385b42751a call amdgpu_init_debug_options() in amdgpu_attachhook()
matches the call in amdgpu_pci_probe()
2026-06-15 01:30:51 +00:00
nicm 82a9e4d18b Fix various errors in redrawing:
- Fix the active pane colour when only two panes and scrollbars enabled.

- Clip left and right scrollbars the same for floating panes.

- Do not subtract scrollbar width twice when working out width of status
  line.

- Check if a character is inside a visible range correctly (do not
  include the next position outside the range).
2026-06-14 20:53:20 +00:00
nicm 44534912ef Skip floating panes when working out the top or bottom cell. Fixes
missing bottom status pane status line when floating panes exist.
2026-06-14 20:37:57 +00:00
nicm 70f06a5829 Add a helper to get pane-border-status for a window for some other
changes to come.
2026-06-14 19:31:37 +00:00
nicm 3f5cf1464b Take account of borders when resizing floating panes. 2026-06-14 18:59:15 +00:00
jsing 3dc2c2828b Correct secondary key share handling for HelloRetryRequests.
With the introduction of a secondary key share, we fail to ensure that the
HelloRetryRequest does not specify the group that was used for the
secondary key share. We also fail to free the secondary key share early in
this case, meaning that it lingers in memory until the SSL is reset or
freed. Fix both of these issues.

ok tb@
2026-06-14 15:51:17 +00:00
jsing 20117dcb7f Improve TLSv1.3 server handling of no shared groups.
While we currently correctly handle the no-shared-group case, it currently
fails late when we try to create the key share. Improve detection and
handling so that we fail sooner and send an alert to the client when
processing client key shares.

While here rename preferred_group_found to shared_group_found - we look for
the client preferred group, but any group that we select will always be in
the client list (even if it's the last one).

Reported by the tlspuffin team.

ok tb@
2026-06-14 15:47:49 +00:00
jsing aca74d656c Send illegal parameter alerts for various HelloRetryRequest violations.
Be more RFC compliant and send illegal parameter alerts when the client
receives a HelloRetryRequest that requests a group that we did not offer
or a group that we sent a key share for in the ClientHello. These were
annotated as missing, but not previously implemented.

Prompted by a report from the tlspuffin team.

ok tb@
2026-06-14 14:53:07 +00:00
jsing 9fa1dce37a Improve renegotation regress.
Include coverage of Renegotiation Indication and legacy connection
handling.
2026-06-14 14:33:36 +00:00
jsing d5512f45c6 Mop up SSL_CTX_set_options(3).
SSL_OP_DONT_INSERT_EMPTY_FRAGMENTS is now a no-op, tidy up
SSL_OP_LEGACY_SERVER_CONNECT and reflect the current state of SSL_OP_ALL
Delete the entire "SECURE RENEGOTIATION" section that contained ancient
ramblings.

ok beck@ tb@
2026-06-14 14:30:52 +00:00
jsing 969f618254 Remove SSL_OP_LEGACY_SERVER_CONNECT from default options.
Remove SSL_OP_LEGACY_SERVER_CONNECT from the default SSL options and the
SSL_OP_ALL define. This means that we will now refuse to connect to a
TLSv1.2 server if it does not support the Renegotiation Indication (RI)
extension. This prevents a class of attacks against TLS clients that are
talking to TLSv1.2-only servers that permit client initiated renegotiation.

Raised by Lucca Hirschi et al from Inria.

ok beck@ tb@
2026-06-14 14:25:55 +00:00
semarie 009b3423c5 cargo-module.5: document more variables
From Andrew Kloet andrew kloet.net
2026-06-14 14:02:44 +00:00
rsadowski 459bfe6c89 relayd: drain OpenSSL error queue on TLS failures
Borrowed from smtpd. Without draining we just log "RSA_meth_dup failed"
and lose the actual reason.

Wire ssl_error() into ca_engine_init(), which also kills a dead
RSA_meth_free() on a NULL pointer there, and into ssl_load_key()s fail
path.

Tweaks and OK tb
2026-06-14 08:57:43 +00:00
rsadowski 67a094f58b relayd: remove from and toptr to simplify
feedback and OK claudio
2026-06-14 08:55:54 +00:00
rsadowski 6ef9a49ecd relayd: use ibuf_get_string() and ibuf_get_data() to read imsg payloads
Drop the local get_string() and read variable-length string and binary
payloads through the ibuf getters instead of the raw imsg->data pointer.

ibuf_get_string() no longer trims the input at the first non-printable
byte like the old get_string() did; the payloads come from the parent
over privsep imsg.

idea and ok claudio
2026-06-14 08:54:21 +00:00
rsadowski 7b68501be4 fix knfmt 2026-06-14 08:53:06 +00:00
rsadowski c9b5e05e3c Check error in proc_forward_imsg 2026-06-14 08:52:16 +00:00
rsadowski a4156c64cb relayd: read parent_dispatch_pfe() payloads via the imsg getters
Use imsg_get_data() for the fixed-size messages and imsg_get_ibuf() for
the variable-length IMSG_CTL_RELOAD path, taking the config name from
the ibuf via ibuf_data()/ibuf_size().

Remove IMSG_SIZE_CHECK and IMSG_DATA_SIZE, no consumer left.


OK claudio
2026-06-14 08:51:11 +00:00
rsadowski a1a35aaebe relayd: use imsg_get_ibuf() for variable-length CA key operations
The IMSG_CA_PRIVENC/PRIVDEC messages carry a ctl_keyop header followed
by cko_flen (request) or cko_tlen (response) trailing bytes, so the
exact-size imsg_get_data() cannot be used. Read the header with
imsg_get_ibuf() + ibuf_get() and take the payload from the same ibuf
via ibuf_data()/ibuf_size().

Tweaks (in a different commit) and OK claudio
2026-06-14 08:50:26 +00:00
rsadowski 93e9ebaeef relayd: read imsg payloads via the new imsg/ibuf getters
Convert the config_get* handlers from IMSG_SIZE_CHECK() + memcpy() to
the new imsg API. Fixed-size payloads use imsg_get_data(). Functions
with a fixed header followed by variable-length data use imsg_get_ibuf()
+ ibuf_get() and read the remainder from the same ibuf cursor, since
imsg_get_data() requires the payload to match the requested size
exactly.

Feedback and OK claudio
2026-06-14 08:48:04 +00:00
nicm 8d8c88272e Return early if connect construct cell, reported by Jere Viikari. 2026-06-14 08:47:44 +00:00
rsadowski 01021ef022 relayd: convert control imsg forwarding to imsg_forward()
Rework control_imsg_forward() to forward the message unaltered via
imsg_forward() instead of rebuilding it with imsg_compose_event().

read the type via imsg_get_type(), dropping the manual header-length
Switch to use read the payload with imsg_get_data() and checks and the
memcpy() that wrote the data back into the imsg before forwarding.

OK claudio
2026-06-14 08:45:02 +00:00
rsadowski c3b31b8270 relayd: use imsg_get_data() and imsg_get_type()
Replace IMSG_SIZE_CHECK() + memcpy()/bcopy() with imsg_get_data(),
which does the length check and copy in one call, and read the message
type via imsg_get_type() instead of imsg->hdr.type.

OK claudio
2026-06-14 08:41:08 +00:00
rsadowski 2f0a999569 relayd: convert proc.c to new imsg API
Replace IMSG_SIZE_CHECK() + memcpy() with imsg_get_data(), which does
the length check and copy in one call. Use the imsg accessors
(imsg_get_*) instead of touching imsg.hdr directly and
imsgbuf_get()/imsgbuf_read() instead of imsg_get().

Rewrite proc_forward_imsg() to use imsg_forward() per target imsgbuf
instead of re-composing via proc_compose_imsg(); arm the write event
with imsg_event_add() after each forward.

proc_forward_imsg() never forwarded an fd, and imsg_forward() rewinds
the buffer internally, so multiple forwards per message keep working.

Drop the now-unused n parameter (all callers passed -1).

ok claudio@
2026-06-14 08:37:00 +00:00
mvs 076e2b1c1f sppp_pap_input(): do not compare credentials if the lengths of received
ones is not the same of configured.

ok renaud bluhm
2026-06-14 05:39:23 +00:00
djm 9cbb3b0bd2 make crypto_sign_ed25519_keypair_from_seed non-static. The
new ML-DSA/ed25519 code needs it
2026-06-14 04:16:19 +00:00
djm 6f9c45541f unit and regression tests for composite PQ ML-DSA44/Ed25519
keys.

Includes a new unittests/crypto test that tests basic functionality
of the underlying crypto primitives against public test vectors
2026-06-14 04:08:05 +00:00
djm 831e2e1785 Add experimental support for a composite post-quantum signature
scheme that combines ML-DSA 44 and Ed25519 using the construction
specified in draft-ietf-lamps-pq-composite-sigs. There's also an
early draft documenting use of the integration of this scheme into
SSH as draft-miller-sshm-mldsa44-ed25519-composite-sigs

This scheme is not enabled by default. To you use, you'll need
to add it to HostKeyAlgorithms, PubkeyAcceptedAlgorithms, etc.
Keys may be generated using "ssh-keygen -t mldsa44-ed25519".

The ML-DSA implementation comes from libcrux. Thanks to
Jonas Schneider-Bensch and Jonathan Protzenko for their work to
make this available.

Consensus is that it's time to get this in to allow people to
experiment with it.

feedback markus@ tb@ logan@ deraadt@
2026-06-14 03:59:34 +00:00
nicm 7f3d25a7c2 With mode-keys vi, keep cursor in the same position relative to the text
when scrolling. GitHub issue 5216 from Arseniy Simonov.
2026-06-13 20:39:11 +00:00
nicm 46410a2bd4 Add some missing const, from Jere Viikari. 2026-06-13 20:07:30 +00:00
nicm cf95c7767d Skip floating cells when moving to previous cell for resize of tiled cells. 2026-06-13 20:03:10 +00:00
nicm 5e36418eb2 Make the resize keys always change right and bottom borders for floating
panes which is more intuitive.
2026-06-13 19:57:44 +00:00
job f1b909137a Provide standards reference for signed object displacement/replay warning
OK tb@
2026-06-13 19:17:59 +00:00
job 685a808d73 Don't include ASPAs with too many providers in the CCR output
Reported by Ties de Kock

OK tb@
2026-06-13 19:16:14 +00:00
nicm 5f43b24e5e Tidy up error messages from split-window. 2026-06-13 18:30:16 +00:00
nicm a103b0d729 Add move-pane -z to move a pane to a particular the z-index. 2026-06-13 18:06:01 +00:00
nicm a15c941f0b Add Z index positions to move-pane -P. 2026-06-13 17:43:20 +00:00
nicm 2a38d5e77a Add -P to move-pane to move a floating pane to a specific place
(top-left, bottom-right). Get rid of the not-so-useful default { and }
swap-pane bindings and use the keys instead for moving to top-left,
top-right and add M-{ and M-} for bottom-left, bottom-right.
2026-06-13 17:12:02 +00:00
jsing ef2c15e04a Enable SHA1_SMALL for libstubs.
On amd64 this reduces the sha1.o text size by 5169 bytes.
2026-06-13 16:23:43 +00:00
jsing 703c32638c Provide a small SHA-1 implementation.
This will be used to reduce code size on install media.

ok tb@
2026-06-13 16:21:29 +00:00
nicm 34933f5926 Add flags to move-pane to move floating panes around (-U, -D, -L, -R
similar to resize-pane; -X, -Y similar to new-pane).
2026-06-13 16:16:18 +00:00
bluhm 4019395a45 Drop stale TCP connections in TIME_WAIT state after each test.
Otherwise they accumulate and regress runs out of port numbers.
2026-06-13 13:16:43 +00:00
nicm 83ab708fc0 Missed this one as well. 2026-06-13 13:07:12 +00:00
nicm 19191f4d7a Use correct name for activity time. 2026-06-13 13:06:12 +00:00
kirill 7cf8aaf9ec sys/ogx: fix build without INET6 option
Reported by Gabriel <vashongabriel at gmail dot com>

OK: kn@
2026-06-13 11:48:05 +00:00
nicm 4abe9ebbcc Remove some stray code from an old floating panes implementation, from
Dane Jensen.
2026-06-13 11:37:46 +00:00
nicm a8844f8c56 Extend client mode so the preview can be changed to a view with a
summary of the client terminal and its features, intended to make
troubleshooting easier. "choose-client -i" or the "i" key in the mode.
2026-06-13 10:32:54 +00:00
nicm 4ee6e01dfc Add an I format modifier to get some bits of information about a client
(terminal features, capabilities and environment).
2026-06-13 09:17:29 +00:00