openbsd
8 months agoadd 7.6 syspatch public key
robert [Thu, 22 Feb 2024 08:35:38 +0000 (08:35 +0000)]
add 7.6 syspatch public key

8 months agoif_inkstatehook -> if_linkstatehook
jsg [Thu, 22 Feb 2024 08:10:08 +0000 (08:10 +0000)]
if_inkstatehook -> if_linkstatehook

8 months agoWorkaround for gcc3 - the use of anonymous unions now makes it complain
miod [Thu, 22 Feb 2024 06:45:22 +0000 (06:45 +0000)]
Workaround for gcc3 - the use of anonymous unions now makes it complain
when named initializers use fields within these anonymous unions.

Hopefully a short-term bandaid until the appropriate changes are identified
and backported to gcc3.

ok claudio@

8 months agovmd(8): only add vionet tap read events after a notify event.
dv [Thu, 22 Feb 2024 02:38:53 +0000 (02:38 +0000)]
vmd(8): only add vionet tap read events after a notify event.

My recent refactor introduced a bug where the vionet device will
add the tap(4) read event on an unpause regardless of driver and
device state, causing the cpu to peg as the read event fires
indefinitely because the guest's virtqueue isn't ready to receive
the data.

Add in a global flag that tracks if the rx-side is enabled or not
to coordinate adding the tap read event.

ok mlarkin@

8 months agomatch on C740; tested by and ok deraadt@
jsg [Wed, 21 Feb 2024 22:57:11 +0000 (22:57 +0000)]
match on C740; tested by and ok deraadt@

8 months agorecognise Neoverse V3 (Poseidon), Neoverse N3 (Hermes)
jsg [Wed, 21 Feb 2024 21:50:17 +0000 (21:50 +0000)]
recognise Neoverse V3 (Poseidon), Neoverse N3 (Hermes)

8 months agofix typos in qwx(4) firmware file names
stsp [Wed, 21 Feb 2024 21:31:02 +0000 (21:31 +0000)]
fix typos in qwx(4) firmware file names

8 months agosync
deraadt [Wed, 21 Feb 2024 18:21:16 +0000 (18:21 +0000)]
sync

8 months agocreate a new code ILL_BTCFI associated with SIGILL for trap faults which
deraadt [Wed, 21 Feb 2024 15:53:07 +0000 (15:53 +0000)]
create a new code ILL_BTCFI associated with SIGILL for trap faults which
indicate missing indirect branch target instructions (on the two
architectures which currently have this).  This becomes nicely visible in
kdump:
  6526 cat      PSIG  SIGILL SIG_DFL code=ILL_BTCFI addr=0x438fad6a990 trapno=21
ok kettenis sthen miod rsadowski

8 months agoRemove duplicate definitions.
kevlo [Wed, 21 Feb 2024 14:40:50 +0000 (14:40 +0000)]
Remove duplicate definitions.

ok stsp@

8 months agoAdd missing checksum flag M_TCP_TSO to ddb show mbuf.
bluhm [Wed, 21 Feb 2024 13:42:06 +0000 (13:42 +0000)]
Add missing checksum flag M_TCP_TSO to ddb show mbuf.

OK mglocker@ claudio@

8 months agoIn it_cmp() make sure that arrays are only considered equal if both
claudio [Wed, 21 Feb 2024 13:24:37 +0000 (13:24 +0000)]
In it_cmp() make sure that arrays are only considered equal if both
have the same number of elements. This fixes an issue where arrays
where too aggressivly merged and as a result the number of elements
was mostly wrong in the CTF bits.
Also it_cmp() should return 0 if both elements are considered equal.
OK mpi@

8 months agoMake DPRINTF() depend on DEBUG and add the missing ;
claudio [Wed, 21 Feb 2024 13:21:56 +0000 (13:21 +0000)]
Make DPRINTF() depend on DEBUG and add the missing ;
OK mpi@

8 months agoApply the void workaround also for typedefs.
claudio [Wed, 21 Feb 2024 13:20:38 +0000 (13:20 +0000)]
Apply the void workaround also for typedefs.

The kernel has 'typedef VOID void' which needs this.
OK mpi@

8 months agoHandle DW_FORM_udata and DW_FORM_ref_udata in dav2val().
claudio [Wed, 21 Feb 2024 13:18:33 +0000 (13:18 +0000)]
Handle DW_FORM_udata and DW_FORM_ref_udata in dav2val().

At least with clang enums use DW_FORM_udata and without this all enum
values would be reported as -1.

OK mpi@

8 months agoMake sure dw_at2name() never returns NULL. This call is used in various
claudio [Wed, 21 Feb 2024 13:16:14 +0000 (13:16 +0000)]
Make sure dw_at2name() never returns NULL. This call is used in various
printf calls that clang decided to optimise into puts calls that crash
with a NULL argument.
Also add DW_AT_noreturn which caused this when running ./ctfconv -d ./ctfconv
OK mpi@

8 months agoGroup logx() getmonotime() and get_current_time() together
tb [Wed, 21 Feb 2024 12:48:25 +0000 (12:48 +0000)]
Group logx() getmonotime() and get_current_time() together

Fix their indent in extern.h, move the X509_TIME_* macros to main.c since
they aren't (and can't really be) used elsewhere, document the meaning of
the magic numbers. Also move get_current_time() out of the middle of entity
handlers.

ok claudio job

8 months agoFix secondary indent of various ip_* and as_* prototypes
tb [Wed, 21 Feb 2024 12:38:10 +0000 (12:38 +0000)]
Fix secondary indent of various ip_* and as_* prototypes

8 months agoRemove prototypes for tak_read() and ip_addr_cmp()
tb [Wed, 21 Feb 2024 12:35:36 +0000 (12:35 +0000)]
Remove prototypes for tak_read() and ip_addr_cmp()

These functions never existed.

ok claudio job

8 months agospelling fixes; ok claudio@
jsg [Wed, 21 Feb 2024 12:08:05 +0000 (12:08 +0000)]
spelling fixes; ok claudio@

8 months agoImport mwx(4) a driver for Mediatek MT7921 and MT7922 802.11ax devices
claudio [Wed, 21 Feb 2024 10:48:10 +0000 (10:48 +0000)]
Import mwx(4) a driver for Mediatek MT7921 and MT7922 802.11ax devices

This is work in progress. Scan works, RX of packets is more or less there
but TX does not work yet. The packets are passed to the chip but get stuck
or ignored there. It is easy to hang the device or the system since device
reset is not quite right (like many other bits).

Also this is only for MT7921 right now since I have no access to a MT7922
device.

Lots of pushing from deraadt@ to commit this now.

8 months agoKeep mbuf data alignment intact in m_defrag()
claudio [Wed, 21 Feb 2024 09:28:29 +0000 (09:28 +0000)]
Keep mbuf data alignment intact in m_defrag()

The recent TSO support in em(4) triggered an alignment error on the TCP
header. In em(4) m_defrag() is called before setting up the TSO dma bits
and with that the TCP header was suddenly no longer aligned. Like other
mbuf functions preserve the data alignment in m_defrag() to prevent such
unaligned packets.

With help and OK bluhm@ mglocker@

8 months agorpki-client: remove the remaining struct parse
tb [Wed, 21 Feb 2024 09:17:06 +0000 (09:17 +0000)]
rpki-client: remove the remaining struct parse

With the exception of mft.c where there is an additional boolean, this
struct carries a file name and a result. This means functions having
struct parse in the signature can't be shared between files, which has
been annoying. Simply pass file name and necessary info directly as a
function parameter and add a small dance to handle the boolean in mft.c.

ok job

8 months agoexplain arguments of internal-sftp
djm [Wed, 21 Feb 2024 06:17:29 +0000 (06:17 +0000)]
explain arguments of internal-sftp
GHPR#454 from Niklas Hambüchen

8 months agoclarify permissions requirements for ChrootDirectory
djm [Wed, 21 Feb 2024 06:06:43 +0000 (06:06 +0000)]
clarify permissions requirements for ChrootDirectory
Part of GHPR#454 from Niklas Hambüchen

8 months ago.Cm for a keyword. Part of GHPR#454 from Niklas Hambüchen
djm [Wed, 21 Feb 2024 06:05:06 +0000 (06:05 +0000)]
.Cm for a keyword. Part of GHPR#454 from Niklas Hambüchen

8 months agofix typo in match directive predicate (s/tagged/tag)
djm [Wed, 21 Feb 2024 06:01:13 +0000 (06:01 +0000)]
fix typo in match directive predicate (s/tagged/tag)
GHPR#462 from Tobias Manske

8 months agofix proxy multiplexing mode, broken when keystroke timing
djm [Wed, 21 Feb 2024 05:57:34 +0000 (05:57 +0000)]
fix proxy multiplexing mode, broken when keystroke timing
obfuscation was added. GHPR#463 from montag451

8 months agorevert r1.35
dlg [Wed, 21 Feb 2024 04:26:45 +0000 (04:26 +0000)]
revert r1.35

i dont know what i'm doing wrong with the handling of the no-map
property, but i'll find some coffee and time and figure it out soon
hopefully.

8 months agoDNS resolution is best effort; if at this time IP addresses for tickers
deraadt [Wed, 21 Feb 2024 03:31:28 +0000 (03:31 +0000)]
DNS resolution is best effort; if at this time IP addresses for tickers
cannot be resolved, don't spam syslog like crazy.  Change the
"DNS lookup tmpfail" message into a log_debug()
ok millert

8 months agoOnly return EPERM for immutable regions for the nasty operations
deraadt [Wed, 21 Feb 2024 03:28:29 +0000 (03:28 +0000)]
Only return EPERM for immutable regions for the nasty operations
of madvise() and msync() which damaged the region.  The sync ones
are allowed to proceed (even if most of them are nops...)
based on issues noted by anton and semarie

8 months agohandle /reserved-memory nodes from device trees on arm64.
dlg [Wed, 21 Feb 2024 01:45:14 +0000 (01:45 +0000)]
handle /reserved-memory nodes from device trees on arm64.

u-boot is supposed to take these entries and put them in the efi
memory map, but i keep hitting machines where an otherwise functional
u-boot does not do this, resulting in weird errors.

i have an espressobin with a vendor u-boot that has a reserved-memory
region for psci. without this diff the machine faults when the
kernel tries to reboot using a psci handler.

a macchiatobin with an otherwise working u-boot throws SErrors or
panics on weird memory corruption problems without this. i thought
it was bad RAM, but the problems persisted with completely different
ram, and very underclocked and well cooled ram.

riscv64 already has code to handle reserved-memory regions. the
riscv64 change is to add handling for the "no-map" property.

ok kettenis@

8 months agoUtilize separate threads for RX and TX in vmd(8)'s vionet.
dv [Tue, 20 Feb 2024 21:40:37 +0000 (21:40 +0000)]
Utilize separate threads for RX and TX in vmd(8)'s vionet.

This commit adds multithreading to allow both virtqueues to be
processed in parallel along with additional synchronization primitives
to protect device configuration state. Allowing RX and TX to operate
independently reduces overall network latency for guests and helps
alleviate the TX side dominating cpu time.

Tested with help from phessler@, kn@, and mlarkin@. ok mlarkin@.

8 months agoLink mpath and pf_trans regress to build.
bluhm [Tue, 20 Feb 2024 21:12:03 +0000 (21:12 +0000)]
Link mpath and pf_trans regress to build.

8 months agoUse REMOTE_ADDR from environment to configure pf_policy test. This
bluhm [Tue, 20 Feb 2024 21:10:26 +0000 (21:10 +0000)]
Use REMOTE_ADDR from environment to configure pf_policy test.  This
name is compatible with regress tree.  Also do not run commands
during make obj and make clean.

8 months agoAdd regression test for multipath routing.
bluhm [Tue, 20 Feb 2024 20:04:51 +0000 (20:04 +0000)]
Add regression test for multipath routing.

Test that routes set with the -mpath flag distribute the traffic.
Each route has a different gateway and the UDP packets have different
source addresses.  The destination address is identical for all
routes and packets.  Analyze the use counter in netstat -r output
to check that multiple routes have been used.  Currently this works
only for IPv4.  sysctl net.inet.ip.multipath and net.inet6.ip6.multipath
are enabled before testing and reset afterwards.  All routes and
interface addresses are created on loopback in a separate routing
domain.

8 months ago+openbsd-76-fw.pub
sthen [Tue, 20 Feb 2024 15:31:29 +0000 (15:31 +0000)]
+openbsd-76-fw.pub

8 months agoadd 7.6 fw key
sthen [Tue, 20 Feb 2024 15:30:54 +0000 (15:30 +0000)]
add 7.6 fw key

8 months agox509_asid: NULL out min/max on extract_min_max() failure
tb [Tue, 20 Feb 2024 14:58:16 +0000 (14:58 +0000)]
x509_asid: NULL out min/max on extract_min_max() failure

requested by/ok jsing

8 months agoRemove some now unused variables. Somehow missed in previous commit.
martijn [Tue, 20 Feb 2024 12:51:10 +0000 (12:51 +0000)]
Remove some now unused variables. Somehow missed in previous commit.

8 months agostrptime() only touches the fields specified in the format string,
martijn [Tue, 20 Feb 2024 12:41:13 +0000 (12:41 +0000)]
strptime() only touches the fields specified in the format string,
meaning there could be garbage left in the other fields. Somehow this
only caused issues in mktime() when /etc/localtime is set to GMT.
Initialize tm to 0.

While here fix a type-O in the format string and make the invalid
strlen for LAST-UPDATED message more consistent with the other 2 error
messages.

Found by and OK sthen@

8 months agotrap receiver is special in that the OID is optional. Make sure that we
martijn [Tue, 20 Feb 2024 12:32:48 +0000 (12:32 +0000)]
trap receiver is special in that the OID is optional. Make sure that we
accept a NULL descriptor, which results in an OID length of 0.

Found by and OK sthen@

8 months agoRemove the packetid logic from ax.c. It's not used by snmpd and has some
martijn [Tue, 20 Feb 2024 12:25:43 +0000 (12:25 +0000)]
Remove the packetid logic from ax.c. It's not used by snmpd and has some
serious flaws.

Issue reported and analysis by Steffen Christgau.
OK tb@

8 months agoimplement disassociation (RUN->AUTH/INIT) in the qwx(4) driver state machine
stsp [Tue, 20 Feb 2024 11:48:19 +0000 (11:48 +0000)]
implement disassociation (RUN->AUTH/INIT) in the qwx(4) driver state machine

8 months agoimplement qwx_dp_reo_cmd_list_cleanup()
stsp [Tue, 20 Feb 2024 11:44:15 +0000 (11:44 +0000)]
implement qwx_dp_reo_cmd_list_cleanup()

8 months agofix a double-free in qwx(4) that occurred when removing a peer from firmware
stsp [Tue, 20 Feb 2024 11:42:36 +0000 (11:42 +0000)]
fix a double-free in qwx(4) that occurred when removing a peer from firmware

It was not yet possible to hit this code path outside of an error path.
But upcoming changes would easily trigger this and crash the kernel.

8 months agoInclude the test pattern that resulted in an infinite loop before
claudio [Tue, 20 Feb 2024 10:37:35 +0000 (10:37 +0000)]
Include the test pattern that resulted in an infinite loop before
rmatch.c rev 1.4.

8 months agoAdd missing check for the case where the pattern hits a barrier before
claudio [Tue, 20 Feb 2024 10:36:23 +0000 (10:36 +0000)]
Add missing check for the case where the pattern hits a barrier before
the string is consumed as well. Right now a string of 'dir1/' and a
pattern of 'dir/' will result in an infinite loop because matchsub()
would return success but then would not move forward.

Report and diff from Kyle Evans (kevans FreeBSD.org)
OK tb@

8 months agoAdd rsync-unit
claudio [Tue, 20 Feb 2024 09:42:49 +0000 (09:42 +0000)]
Add rsync-unit

8 months agoAdd a unit test for rsync special rmatch() function.
claudio [Tue, 20 Feb 2024 09:40:58 +0000 (09:40 +0000)]
Add a unit test for rsync special rmatch() function.
One pattern is currently disabled since it results in an infinite loop.
Fix for that is on the way.

8 months agodrm/i915/pxp/mtl: Update pxp-firmware response timeout
jsg [Tue, 20 Feb 2024 08:06:19 +0000 (08:06 +0000)]
drm/i915/pxp/mtl: Update pxp-firmware response timeout

From Alan Previn
8ae272348153ed2fa423f739047a592d9bd55ba2 in mainline linux

Fixes a LG UltraFine 5K display not lighting up on a Comet Lake machine.
Regression reported by Kirill A. Korinsky who tracked the problem down
to a timeout in pxp.

8 months agodon't append a gratuitous space to the end of subsystem arguments;
djm [Tue, 20 Feb 2024 04:10:03 +0000 (04:10 +0000)]
don't append a gratuitous space to the end of subsystem arguments;
bz3667

8 months agoMake bwfm(4) work with MAC addresses set via ifconfig lladdr.
stsp [Mon, 19 Feb 2024 21:23:02 +0000 (21:23 +0000)]
Make bwfm(4) work with MAC addresses set via ifconfig lladdr.

Patch by Todd Carson
Tests by Todd Carson and naddy@
ok tobhe@

8 months agono need to be as strict with table formats on various match constraints,
gilles [Mon, 19 Feb 2024 21:00:19 +0000 (21:00 +0000)]
no need to be as strict with table formats on various match constraints,
this prevents the reuse of T_HASH tables in T_LIST contexts when the key
column actually makes sense by itself.

diff from Philipp (philipp+openbsd [at] bureaucracy [dot] de)

8 months agoFix a deadlock in openrsync when big files are synced using the hash
claudio [Mon, 19 Feb 2024 16:39:18 +0000 (16:39 +0000)]
Fix a deadlock in openrsync when big files are synced using the hash
algorithm. Make sure the sender does not run ahead of itself and end
stalling in a read from network that never shows up. Instead ensure
that all queued data is pushed out before accepting new data.

Problem found by and fix developed with Kyle Evans (kevans freebsd.org)
OK tb@ deraadt@

8 months agouse correct rtmsg member in sizeof()
denis [Mon, 19 Feb 2024 16:39:03 +0000 (16:39 +0000)]
use correct rtmsg member in sizeof()

OK miod@

8 months agox509_asid: fix some KNF botches
tb [Mon, 19 Feb 2024 15:44:10 +0000 (15:44 +0000)]
x509_asid: fix some KNF botches

When this file was brought into KNF, a few things became particularly ugly.
This makes {a,b}{,_{min,max}} have function scope in canonize/is_canonical,
which removes unfortunate line wraps and some other silliness.

ok job

8 months agopk7_attr.c: tidy includes
tb [Mon, 19 Feb 2024 15:37:44 +0000 (15:37 +0000)]
pk7_attr.c: tidy includes

8 months agoRevert the change that enabled retpoline thunks by default. The use of
kettenis [Mon, 19 Feb 2024 14:08:58 +0000 (14:08 +0000)]
Revert the change that enabled retpoline thunks by default.  The use of
retpolines makes IBT less useful and we have enabled additional mitigations
in our kernel now that should make them (mostly) unnecessary.

ok guenther@

8 months agoRemove "noretpolineplt" from the list of known -z flags. Missed in the
kettenis [Mon, 19 Feb 2024 14:05:01 +0000 (14:05 +0000)]
Remove "noretpolineplt" from the list of known -z flags.  Missed in the
previous commit.

ok guenther@

8 months agoAvoid passphrase in temporary file
kn [Mon, 19 Feb 2024 13:53:03 +0000 (13:53 +0000)]
Avoid passphrase in temporary file

bioctl(8) uses readpassphrase(3) RPP_REQUITE_TTY, so always pass stdin,
but only use it over TTY with -s in unattended mode.

Prodding afresh1 sthen
"much better" sthen

8 months agoIANA assigned error 8 to draft-ietf-idr-sendholdtimer
job [Mon, 19 Feb 2024 10:15:35 +0000 (10:15 +0000)]
IANA assigned error 8 to draft-ietf-idr-sendholdtimer

https://www.iana.org/assignments/bgp-parameters/bgp-parameters.xhtml#bgp-parameters-3

OK claudio@

8 months agoIn cpu_fork() do not copy the register windows stashed in the u_pcb
claudio [Mon, 19 Feb 2024 09:59:29 +0000 (09:59 +0000)]
In cpu_fork() do not copy the register windows stashed in the u_pcb
if the new proc has its own stack. In that case the new thread starts
with a fresh stack and there are no register windows to spill back.

This fixes the pthread issues that kurt@ was struggling with for a long
time. Depending on the scheduler a thread would stomp over another threads
stack which caused strange crashes.

Improved diff provided by miod@
OK miod@ mpi@ kurt@

8 months agoAlways define puttysetup function.
dtucker [Mon, 19 Feb 2024 09:25:52 +0000 (09:25 +0000)]
Always define puttysetup function.

8 months agoregen
jsg [Mon, 19 Feb 2024 05:36:55 +0000 (05:36 +0000)]
regen

8 months agoadd more Intel device ids
jsg [Mon, 19 Feb 2024 05:36:17 +0000 (05:36 +0000)]
add more Intel device ids

more Raptor Lake host ids from:
13th Generation Intel Core and Intel Core 14th Generation Processors
Datasheet, Volume 1 of 2, Doc. No.: 743844, Rev.: 008

700 Series eSPI ids, from:
Intel 700 Series Chipset Family Platform Controller Hub
Datasheet, Volume 1 of 2, Doc. No.: 743835, Rev.: 003

C740 Series (Emmitsburg) PCH ids.  No public docs could be found,
so based on dmesg of a Sapphire Rapids machine and EmmitsburgSystem.inf

8 months agoregen
kevlo [Mon, 19 Feb 2024 03:02:15 +0000 (03:02 +0000)]
regen

8 months agoadd Realtek 802.11ax ids
kevlo [Mon, 19 Feb 2024 03:00:37 +0000 (03:00 +0000)]
add Realtek 802.11ax ids

8 months agodrm/amd/display: Implement bounds check for stream encoder creation in DCN301
jsg [Mon, 19 Feb 2024 01:54:46 +0000 (01:54 +0000)]
drm/amd/display: Implement bounds check for stream encoder creation in DCN301

From Srinivasan Shanmugam
cd9bd10c59e3c1446680514fd3097c5b00d3712d in linux-6.6.y/6.6.17
58fca355ad37dcb5f785d9095db5f748b79c5dc2 in mainline linux

8 months agodrm/amd/display: Add NULL test for 'timing generator' in 'dcn21_set_pipe()'
jsg [Mon, 19 Feb 2024 01:52:20 +0000 (01:52 +0000)]
drm/amd/display: Add NULL test for 'timing generator' in 'dcn21_set_pipe()'

From Srinivasan Shanmugam
3f3c237a706580326d3b7a1b97697e5031ca4667 in linux-6.6.y/6.6.17
66951d98d9bf45ba25acf37fe0747253fafdf298 in mainline linux

8 months agodrm/amd/display: Fix 'panel_cntl' could be null in 'dcn21_set_backlight_level()'
jsg [Mon, 19 Feb 2024 01:50:11 +0000 (01:50 +0000)]
drm/amd/display: Fix 'panel_cntl' could be null in 'dcn21_set_backlight_level()'

From Srinivasan Shanmugam
2e150ccea13129eb048679114808eb9770443e4d in linux-6.6.y/6.6.17
e96fddb32931d007db12b1fce9b5e8e4c080401b in mainline linux

8 months agodrm/i915/gvt: Fix uninitialized variable in handle_mmio()
jsg [Mon, 19 Feb 2024 01:48:23 +0000 (01:48 +0000)]
drm/i915/gvt: Fix uninitialized variable in handle_mmio()

From Dan Carpenter
41d5340cb01e1b076ae4d58cb91da9552bac64c4 in linux-6.6.y/6.6.17
47caa96478b99d6d1199b89467cc3e5a6cc754ee in mainline linux

8 months agoasn1time: remove some debugging code
tb [Sun, 18 Feb 2024 22:17:01 +0000 (22:17 +0000)]
asn1time: remove some debugging code

8 months agoFix format strings in TRAPDEBUG code and unbreak 88110_syscall. NFC
miod [Sun, 18 Feb 2024 21:27:38 +0000 (21:27 +0000)]
Fix format strings in TRAPDEBUG code and unbreak 88110_syscall. NFC

8 months agoPrevent ioctl(WSKBDIO_GETENCODINGS) NULL deference when sysctl
anton [Sun, 18 Feb 2024 20:17:48 +0000 (20:17 +0000)]
Prevent ioctl(WSKBDIO_GETENCODINGS) NULL deference when sysctl
machdep.forceukbd is enabled without any USB keyboard being attached.

Found the hard way by sthen@; ok miod@

8 months agosync
tb [Sun, 18 Feb 2024 17:20:51 +0000 (17:20 +0000)]
sync

8 months agoTweak previous
tb [Sun, 18 Feb 2024 17:13:29 +0000 (17:13 +0000)]
Tweak previous

8 months agoAdjust regress test for memset() requested by jsing on review
tb [Sun, 18 Feb 2024 16:56:33 +0000 (16:56 +0000)]
Adjust regress test for memset() requested by jsing on review

8 months agoAdd regress coverage for the new API
tb [Sun, 18 Feb 2024 16:32:29 +0000 (16:32 +0000)]
Add regress coverage for the new API

This exercises the new API, in particular with respect to overflow behavior
around the years 0/9999, which are special for GeneralizedTime/X.509.

8 months agoUpdate ASN1_TIME_set(3)
tb [Sun, 18 Feb 2024 16:30:17 +0000 (16:30 +0000)]
Update ASN1_TIME_set(3)

Document OPENSSL_{posix_to_tm,tm_to_posix}() and fix the documentation of
OPENSSL_{gmtime,timegm}().

ok jsing

8 months agoAdd posix_time.h from BoringSSL
tb [Sun, 18 Feb 2024 16:28:37 +0000 (16:28 +0000)]
Add posix_time.h from BoringSSL

This is prepares to expose some internal API as OPENSSL_tm_to_posix() and
OPENSSL_posix_to_tm(). They will be used in libtls and ocspcheck(8) to get
rid of the portability nightmare that is timegm().

Also fix the location of OPENSSL_gmtime() and OPENSSL_timegm() (this API
is not yet exposed). The former is from OpenSSL and surprisingly lives in
crypto.h, not asn1.h, and the latter is BoringSSL API and lives in the new
posix_time.h.

Initial diff from beck, this pulls in further upstream work after review
feedback.

ok jsing

8 months agoAlign EVP_CIPHER_CTX_init() and _legacy_clear()
tb [Sun, 18 Feb 2024 15:53:54 +0000 (15:53 +0000)]
Align EVP_CIPHER_CTX_init() and _legacy_clear()

8 months agoHide EVP_{CIPHER,MD}_CTX_init() from internals
tb [Sun, 18 Feb 2024 15:47:48 +0000 (15:47 +0000)]
Hide EVP_{CIPHER,MD}_CTX_init() from internals

ok jsing

8 months agoUse EVP_MD_CTX_legacy_clear() internally
tb [Sun, 18 Feb 2024 15:45:42 +0000 (15:45 +0000)]
Use EVP_MD_CTX_legacy_clear() internally

ok jsing

8 months agoUse EVP_CIPHER_CTX_legacy_clear() internally
tb [Sun, 18 Feb 2024 15:44:10 +0000 (15:44 +0000)]
Use EVP_CIPHER_CTX_legacy_clear() internally

ok jsing

8 months agoAdd EVP_MD_CTX_legacy_clear()
tb [Sun, 18 Feb 2024 15:43:21 +0000 (15:43 +0000)]
Add EVP_MD_CTX_legacy_clear()

This is analogous to EVP_CIPHER_CTX_legacy_clear() and will serve as an
internal replacement for EVP_MD_CTX_init() until the conversion to heap
allocated ctx is completed. This way EVP_MD_CTX_init() can be changed to
match the OpenSSL 1.1 API.

ok jsing

8 months agoAdd EVP_CIPHER_CTX_legacy_clear()
tb [Sun, 18 Feb 2024 15:41:50 +0000 (15:41 +0000)]
Add EVP_CIPHER_CTX_legacy_clear()

OpenSSL 1.1 made EVP_CIPHER_CTX_init() an alias of EVP_CIPHER_CTX_reset().
In particular, it changed signature and it would no longer leak internal
state if used on an already used ctx. On the other hand, it can't be used
for ctx on the stack.

libcrypto still has a few ctx on the stack which will be converted to heap
allocated contexts at some point. Until this is completed, we will use
EVP_CIPHER_CTX_legacy_clear() internally, so that the public API can be
changed to match OpenSSL 1.1.

ok jsing

8 months agoDon't call cpu_ucode_apply() and cpu_tsx_disable() from cpu_attach()'s
guenther [Sun, 18 Feb 2024 05:42:50 +0000 (05:42 +0000)]
Don't call cpu_ucode_apply() and cpu_tsx_disable() from cpu_attach()'s
CPU_ROLE_SP case: for cpu0 they are called earlier, from cpu_startup().
(APs call them from cpu_hatch())

ok deraadt@

8 months agodt(4): profile: remove clock interrupt staggering
cheloha [Sun, 18 Feb 2024 00:54:03 +0000 (00:54 +0000)]
dt(4): profile: remove clock interrupt staggering

Clock interrupt staggering makes profiling more expensive on average.

Remove it.

Thread: https://marc.info/?l=openbsd-tech&m=170751016121770&w=2

ok mpi@

8 months agosync
deraadt [Sun, 18 Feb 2024 00:02:52 +0000 (00:02 +0000)]
sync

8 months agosync
naddy [Sat, 17 Feb 2024 23:33:52 +0000 (23:33 +0000)]
sync

8 months ago7.6 packages key
naddy [Sat, 17 Feb 2024 22:33:06 +0000 (22:33 +0000)]
7.6 packages key

8 months agosync
deraadt [Sat, 17 Feb 2024 16:28:08 +0000 (16:28 +0000)]
sync

8 months agodelete old keys
deraadt [Sat, 17 Feb 2024 16:27:29 +0000 (16:27 +0000)]
delete old keys

8 months agoadd 7.6 base key, commiting myself to another 6 months
deraadt [Sat, 17 Feb 2024 16:27:21 +0000 (16:27 +0000)]
add 7.6 base key, commiting myself to another 6 months

8 months agomove to 7.5-beta
deraadt [Sat, 17 Feb 2024 16:13:24 +0000 (16:13 +0000)]
move to 7.5-beta

8 months agoAdd 'Send Hold Timer expired' BGP Error code
job [Sat, 17 Feb 2024 14:53:29 +0000 (14:53 +0000)]
Add 'Send Hold Timer expired' BGP Error code

OK deraadt@

8 months agoUse calloc() instead of malloc() in BIO_new().
jsing [Sat, 17 Feb 2024 14:29:07 +0000 (14:29 +0000)]
Use calloc() instead of malloc() in BIO_new().

ok tb@

8 months agoBindings for the rk3288/rk3328/rk3399 have landed in Linux and are being
kettenis [Sat, 17 Feb 2024 13:29:25 +0000 (13:29 +0000)]
Bindings for the rk3288/rk3328/rk3399 have landed in Linux and are being
adopted by U-Boot.  So check for the new compatible strings.  Leave the
old ones in place until we have U-Boot packages with update device trees.

ok phessler@, patrick@

8 months agoAdd JH7100 I2C clocks.
kettenis [Sat, 17 Feb 2024 12:01:45 +0000 (12:01 +0000)]
Add JH7100 I2C clocks.

ok miod@, jsg@