mglocker [Sat, 4 Sep 2021 10:19:28 +0000 (10:19 +0000)]
Revert list_move() to list_move_tail() change from last commit since it
turned out that it has a negative impact to isoc transfers timing with our
driver implementation.
jasper [Sat, 4 Sep 2021 07:13:14 +0000 (07:13 +0000)]
in backtraces, print as many arguments as the function actually has
since amd64 is compiled with -msave-args we have all arguments available to print and
there's no reason to limit this to six.
discussed with kettenis@
mbuhl [Sat, 4 Sep 2021 07:06:58 +0000 (07:06 +0000)]
Disable tests that don't work in bluhms regress framework.
bluhm [Fri, 3 Sep 2021 23:57:30 +0000 (23:57 +0000)]
Make sure that strings passed to printline() are always NUL terminated.
There was a corner case with a very long message received over TCP
or TLS where this was not clear. Force a '\0' where this line is
truncated.
OK martijn@ deraadt@
job [Fri, 3 Sep 2021 23:30:42 +0000 (23:30 +0000)]
Add X509 Extensions for IP Addresses and AS Identifiers
(subordinate code paths are include guarded)
OK tb@
schwarze [Fri, 3 Sep 2021 16:51:47 +0000 (16:51 +0000)]
* add the missing STANDARDS section as noticed by tb@
* mention that the *optionp input string will be modified
* clarify that the array of tokens is expected to be NULL-terminated
OK millert@ tb@, and the first half of STANDARDS also OK jmc@
jasper [Fri, 3 Sep 2021 16:45:44 +0000 (16:45 +0000)]
add kprobes provider for dt
this allows us to dynamically trace function boundaries with btrace by patching
prologues and epilogues with a breakpoint upon which the handler records the data,
sends it back to userland for btrace to consume.
currently it's hidden behind DDBPROF, and there is still a lot to cleanup and
improve, but basic scripts that observe return codes from a probed function
work.
from Tom Rollet, with various changes by me
feedback and ok mpi@
bluhm [Fri, 3 Sep 2021 16:28:33 +0000 (16:28 +0000)]
Use a define for the iov array size in syslogd. This is better
than passing the magic number 6 around and checking at runtime
whether its fits.
OK deraadt@ martijn@ mvs@
fcambus [Fri, 3 Sep 2021 16:11:45 +0000 (16:11 +0000)]
Allow the compiler driver to link the libclang_rt.profile library.
With this change, passing -fprofile-instr-generate -fcoverage-mapping
when building programs will attempt linking against libclang_rt.profile.a.
Please note that we do not ship the library yet.
OK jca@
jca [Fri, 3 Sep 2021 14:58:25 +0000 (14:58 +0000)]
Zap a chatty printf
ok mlarkin@ kettenis@
patrick [Fri, 3 Sep 2021 14:53:09 +0000 (14:53 +0000)]
It's time to enable smmu(4).
ok kettenis@ some time ago
tb [Fri, 3 Sep 2021 14:50:36 +0000 (14:50 +0000)]
Implement a -h option that allows specifying a target host that
will be passed to the test scripts.
jca [Fri, 3 Sep 2021 14:13:06 +0000 (14:13 +0000)]
Don't pretend we support PT_STEP on this architecture.
The RISC-V doesn't seem to provide hardware support for generic purpose
single stepping, and we're not emulating single stepping for riscv64
like we do for alpha or mips64. Hiding PT_STEP makes it possible to run
inferior processes with a wip ports/devel/gdb update.
ok kettenis@
jca [Fri, 3 Sep 2021 14:09:26 +0000 (14:09 +0000)]
Enable ptrace(2) support for PT_GETFPREGS/PT_SETFPREGS
The code is already there, it was unreachable because of this #if 0.
ok kettenis@
patrick [Fri, 3 Sep 2021 14:04:35 +0000 (14:04 +0000)]
Make virtio(4) less restrictive on the type of BAR it supports for
legacy versions. The current version of Parallels on M1 seems to
not provide the I/O BAR that we expect, and reducing our expectations
seems to be help.
ok kettenis@
tb [Fri, 3 Sep 2021 13:26:20 +0000 (13:26 +0000)]
Now that the issue is fixed, enable test-extensions.py
jsing [Fri, 3 Sep 2021 13:19:12 +0000 (13:19 +0000)]
Use SSL3_HM_HEADER_LENGTH instead of the magic number 4.
ok beck@
jsing [Fri, 3 Sep 2021 13:18:17 +0000 (13:18 +0000)]
Ensure that a server hello does not have trailing data.
Found by tlsfuzzer.
ok beck@
jsing [Fri, 3 Sep 2021 13:18:01 +0000 (13:18 +0000)]
Ensure that a client hello does not have trailing data.
Found by tlsfuzzer.
ok beck@
jsing [Fri, 3 Sep 2021 13:16:54 +0000 (13:16 +0000)]
Set message_size correctly when switching to the legacy stack.
The message_size variable is not actually the handshake message size,
rather the number of bytes contained within the handshake message, hence
we have to subtract the length of the handshake message header.
ok beck@
stsp [Fri, 3 Sep 2021 12:39:43 +0000 (12:39 +0000)]
Reset a net80211 node's QoS Tx sequence counter to the start of the
block ack window when a new Tx block ack agreement is established.
In the future this change will allow the iwx(4) driver to initialize this
sequence number such that it corresponds to what the firmware expects.
Note that ba->ba_winstart is set to ni->ni_qos_txseqs[tid] when a new Tx agg
agreement is initiated in ieee80211_node_addba_request(). Unless the driver
resets ba->ba_winstart before ieee80211_addba_resp_accept() runs, which is
what iwx(4) will do, the assignment added with this patch is a no-op.
kn [Fri, 3 Sep 2021 12:11:15 +0000 (12:11 +0000)]
Document sleep button, lid status and lidaction/pwraction support
landry added the sensor back in 2013 and suspend via sleep button also works
(at least on ThinkPads).
`machdep.{lid,pwr}action' are super useful but only mentioned in
/etc/examples/wsconsctl.conf providing poor discovery.
acpibtn(4) is the most prominent driver supporting them, so document their
behaviour here as a reference point (`man -k .=lidaction' now shows it).
suspend/hibernate wording is taken from apm(8).
sysctl value list style is taken from sysctl(2)'s KERN_POOL_DEBUG.
Feedback jmc
bluhm [Fri, 3 Sep 2021 11:58:24 +0000 (11:58 +0000)]
Make Bob happy.
stsp [Fri, 3 Sep 2021 11:55:31 +0000 (11:55 +0000)]
Make iwm(4) and iwx(4) resume code path more similar to the attach code path.
In particular, this makes suspend/resume work on systems using msix.
Resume is not 100% reliable yet, though, failing about 1 in 20 times
to bring the interface back up.
Recovery with ifconfig down/up should be possible when things go wrong.
With help from gnezdo@ in diagnosing the issue and testing changes.
Tests:
8265: stsp
9260: florian
9560: kevlo, Uwe Werler
ax200: kevlo, Mark Patruck, beck
ax201: gnezdo
dv [Fri, 3 Sep 2021 11:47:05 +0000 (11:47 +0000)]
vmm(4): grab kernel lock before vmspace init
We need the kernel lock before calling some uvm functions. Fixes a
panic reported by syzbot.
Reported-by: syzbot+dd7a70eaf794705db27e@syzkaller.appspotmail.com
ok mlarkin@
stsp [Fri, 3 Sep 2021 11:41:41 +0000 (11:41 +0000)]
Ensure that iwm(4) and iwx(4) will reload firmware from disk on down/up,
and will not do so during resume.
Tested by kevlo@ on iwx(4) and by myself on iwm(4).
florian [Fri, 3 Sep 2021 09:13:00 +0000 (09:13 +0000)]
Make traceroute(8) faster by sending probes and doing DNS async.
Traditional traceroute would send one probe and then wait for up to 5
seconds for a reply and then send the next probe. On a lossy link that
eventually ends in a black hole this would take about 15 minutes and
people would hit control-c in anger.
This rewrites the traceroute engine to use libevent and asr's async
DNS interface. Probes are now send every 30ms or as soon as we get an
answer back. With that we got the 15 minute worse case down to about
10 seconds.
A minor adjustment that is possible with this is to delay printing a
line until we get to a line with answers. This has two effects:
1) If there are intermediate hops that don't answer, output pauses for
a bit so we keep the visual cue of "something might be wrong here".
2) If there is a black hole at the end, we don't print out many "* * *"
lines and thus scrolling the interesting bits out of the terminal.
We collapse those lines and just print
64 * * *
at the end.
Unfortunately the -c option to send udp probes to a fixed port had to
go for now. But we should be able to add it back.
"Once you have seen the new one you can't go back to the old one" &
enthusiastic OK deraadt@
OK sthen@
"I am very distressed that florian went to bed without committing it"
beck@
beck [Fri, 3 Sep 2021 08:58:53 +0000 (08:58 +0000)]
Call the callback on success in new verifier in a compatible way
when we succeed with a chain, and ensure we do not call the callback
twice when the caller doesn't expect it. A refactor of the end of
the legacy verify code in x509_vfy is probably overdue, but this
should be done based on a piece that works. the important bit here
is this allows the perl regression tests in tree to pass.
Changes the previously committed regress tests to test the success
case callbacks to be known to pass.
ok bluhm@ tb@
bentley [Fri, 3 Sep 2021 08:22:25 +0000 (08:22 +0000)]
Update Albuquerque, NM zip codes.
deraadt [Fri, 3 Sep 2021 08:18:31 +0000 (08:18 +0000)]
sigh -- review one one pointless sys/param.h, and discover all the includes
are a mess.
claudio [Fri, 3 Sep 2021 07:58:07 +0000 (07:58 +0000)]
Mention RFC8050 in bgpd.8
claudio [Fri, 3 Sep 2021 07:48:24 +0000 (07:48 +0000)]
Add add-path support in MRT dumps (RFC8050).
This works for table-v2 formats and also for the all and update dumps.
For the latter the code needs to inspect the UPDATE message to guess if
add-path is used in that message or not. Add-path can be enabled per
AFI and alters the NLRI encoding without any way to detect.
For table dumps we decided to dump RIB_GENERIC entires the same way as
gobgp and not use the encoding from the RFC. The RFC specifies that
RIB_GENERIC (non-IPv4/v6) entries in a way that is not only different
but also against the normal codeflow. Only gobgp seems to implement
RIB_GENERIC encoding (neither bird nor frr/quagga do) and so it makes
sense to follow their way.
OK benno@
dtucker [Fri, 3 Sep 2021 07:43:23 +0000 (07:43 +0000)]
Use .Cm instead of .Dq in StrictHostKeyChecking list for consistency.
Patch from scop via github PR#257, ok jmc@
dtucker [Fri, 3 Sep 2021 07:27:03 +0000 (07:27 +0000)]
Mention using ssh -i for specifying the public key file in the case
where the private key is loaded into ssh-agent but is not present
locally. Based on patch from rafork via github PR#215, ok jmc@
dtucker [Fri, 3 Sep 2021 05:25:50 +0000 (05:25 +0000)]
Refer to KEX "algorithms" instead of "methods" to match other references
and improve consistency. Patch from scop via github PR#241, ok djm@
dtucker [Fri, 3 Sep 2021 05:12:25 +0000 (05:12 +0000)]
Remove redundant attrib_clear in upload_dir_internal. The subsequent
call to stat_to_attrib clears the struct as its first step anyway.
From pmeinhardt via github PR#220, ok djm@
dtucker [Fri, 3 Sep 2021 04:11:13 +0000 (04:11 +0000)]
Add test for client termination status on signal.
Based on patch from Alexxz via github PR#235 with some tweaks, to
match patch in bz#3281.
jmc [Thu, 2 Sep 2021 21:50:24 +0000 (21:50 +0000)]
various improvements to the text/usage, chiefly removing alternative long
options from SYNOPSIS/usage;
diff from leon fischer
the opening sentence is mine - i say that not to take credit, just to
distinguish that leon did not agree with wording
job [Thu, 2 Sep 2021 21:47:50 +0000 (21:47 +0000)]
Unroll ASN1_ITEM_ref()
OK @tb
job [Thu, 2 Sep 2021 21:40:32 +0000 (21:40 +0000)]
Change OPENSSL_strdup() to strdup()
OK tb@
job [Thu, 2 Sep 2021 21:37:40 +0000 (21:37 +0000)]
Change OPENSSL_malloc to calloc()
OK tb@
job [Thu, 2 Sep 2021 21:29:35 +0000 (21:29 +0000)]
Repair unrolling of static ASN1_ITEM IPAddrBlocks_it
The conversion tool didn't handle 'static_ASN1_ITEM_TEMPLATE_END'
OK tb@
job [Thu, 2 Sep 2021 21:27:26 +0000 (21:27 +0000)]
Make v3_addr and v3_asid extern const
OK tb@
job [Thu, 2 Sep 2021 21:15:41 +0000 (21:15 +0000)]
Add err.h for X509error() and friends
OK tb@
job [Thu, 2 Sep 2021 21:12:28 +0000 (21:12 +0000)]
Fix OPENSSL_assert() and assert()
OK tb@
deraadt [Thu, 2 Sep 2021 21:12:25 +0000 (21:12 +0000)]
remove sys/param.h that are not needed
deraadt [Thu, 2 Sep 2021 21:12:09 +0000 (21:12 +0000)]
annotate that sys/param.h is needed for roundup and roundup2
deraadt [Thu, 2 Sep 2021 21:09:29 +0000 (21:09 +0000)]
rather than using sys/param.h, define a local replacement MINIMUM() instead
of MIN(), as done elsewhere
deraadt [Thu, 2 Sep 2021 21:06:06 +0000 (21:06 +0000)]
remove sys/param.h that snuck in, by replacing MAXPATHLEN with PATH_MAX
job [Thu, 2 Sep 2021 21:04:01 +0000 (21:04 +0000)]
Unroll ASN1_EX_TEMPLATE_TYPE IPAddrBlocks
OK tb@
deraadt [Thu, 2 Sep 2021 21:03:54 +0000 (21:03 +0000)]
sys/param.h is not needed for any visible reason
job [Thu, 2 Sep 2021 21:00:07 +0000 (21:00 +0000)]
Change the OPENSSL_strdup() to strdup()
OK beck@ tb@
deraadt [Thu, 2 Sep 2021 20:57:58 +0000 (20:57 +0000)]
remove sys/param.h use, by replacing MAXLOGNAME -> LOGIN_NAME_MAX
and MAXHOSTNAMELEN -> HOST_NAME_MAX+1
job [Thu, 2 Sep 2021 20:53:48 +0000 (20:53 +0000)]
Fix header file includes
OK tb@
deraadt [Thu, 2 Sep 2021 20:33:03 +0000 (20:33 +0000)]
sync
job [Thu, 2 Sep 2021 20:25:40 +0000 (20:25 +0000)]
Move the error put functions from X509V3err() to X509V3error()
OK tb@
job [Thu, 2 Sep 2021 20:11:07 +0000 (20:11 +0000)]
Unroll ASN1_SEQUENCE() ASN1_CHOICE() ASN1_ITEM_TEMPLATE()
OK jsing@
tb [Thu, 2 Sep 2021 19:46:44 +0000 (19:46 +0000)]
Add -f to usage
jasper [Thu, 2 Sep 2021 19:41:48 +0000 (19:41 +0000)]
follow-up on previous commit and rename the _sys union to _args
bluhm [Thu, 2 Sep 2021 19:38:20 +0000 (19:38 +0000)]
Do not create loopback interfaces lo1, lo2, ... upfront. They are
automatically set up by the kernel when a routing domain is created.
An existing lo1 in rdomain 0 would prevent to add any interfaces
in rdomain 1.
OK kn@
tobhe [Thu, 2 Sep 2021 19:28:35 +0000 (19:28 +0000)]
style
kettenis [Thu, 2 Sep 2021 19:12:29 +0000 (19:12 +0000)]
Initialize the uvm object when we actually need it such that we can
use uvm_obj_init() to initialize the pager ops and initial reference count.
This will help future uvm unlocking diffs.
ok mpi@, jsg@
krw [Thu, 2 Sep 2021 18:07:45 +0000 (18:07 +0000)]
Split part_type into separate types 'mbr_type' and 'gpt_type',
shrinking static data demands. Split PRT_printall() into
PRT_print_mbrtypes() and PRT_print_gpttypes() to eliminate
pointless 'pseudo' MBR partition types and pointless display of
MBR partition types with no associated GPT GUIDs.
Eases future MBR and GPT partition type editing improvements.
ok kettenis@
jasper [Thu, 2 Sep 2021 17:21:39 +0000 (17:21 +0000)]
rename struct dt_evt fields to make it clear this isn't only used for tracing syscalls
and adjust btrace(8) accordingly.
extracted from a larger diff by Tom Rollet.
ok mpi@
job [Thu, 2 Sep 2021 15:59:05 +0000 (15:59 +0000)]
OPENSSL_assert() is not appropriate in this context
Feedback from tb@
OK tb@
job [Thu, 2 Sep 2021 15:54:40 +0000 (15:54 +0000)]
Replace ossl_assert()/assert() with OPENSSL_assert()
OK tb@
mbuhl [Thu, 2 Sep 2021 15:28:41 +0000 (15:28 +0000)]
Enable vfork syscall test. Disable SIGSTOP test as it is masked until
exec/exit with vfork.
OK bluhm@
anton [Thu, 2 Sep 2021 15:15:12 +0000 (15:15 +0000)]
Explain in a comment why two wscons_keydesc structures are needed.
jeremy [Thu, 2 Sep 2021 15:00:55 +0000 (15:00 +0000)]
Update for change of default Ruby version to 3.0.
beck [Thu, 2 Sep 2021 14:41:03 +0000 (14:41 +0000)]
We need to allow for either a CERTIFICATE or CERTIFICATE_STATUS message
here or we break the handshake with BAD_MESSAGE
ok tb@
job [Thu, 2 Sep 2021 14:14:44 +0000 (14:14 +0000)]
Replace OPENSSL_free() with free()
OK tb@
jmc [Thu, 2 Sep 2021 14:14:44 +0000 (14:14 +0000)]
list -v with -d in SYNOPSIS, instead of seperately,
and add -v to usage();
job [Thu, 2 Sep 2021 14:11:20 +0000 (14:11 +0000)]
Unroll IMPLEMENT_ASN1_FUNCTIONS()
OK jsing@
job [Thu, 2 Sep 2021 13:48:39 +0000 (13:48 +0000)]
Unroll DECLARE_ASN1_FUNCTIONS()
OK jsing@
stsp [Thu, 2 Sep 2021 13:44:10 +0000 (13:44 +0000)]
Fix our iwx(4) xtal latency values to match the values used by Linux iwlwifi.
with a fix from + ok kevlo@
kevlo [Thu, 2 Sep 2021 13:39:34 +0000 (13:39 +0000)]
The PCI_PRODUCT_INTEL_WL_22500_1 device is part of the 22000
family (discrete) not integrated.
ok stsp@
job [Thu, 2 Sep 2021 13:26:51 +0000 (13:26 +0000)]
Rename DEFINE_STACK_OF() to DECLARE_STACK_OF()
OK tb@ jsing@
florian [Thu, 2 Sep 2021 13:18:04 +0000 (13:18 +0000)]
Stop sending debug logging to syslog (which would then drop it on the
floor) all the time. Instead debug logging must be requested with the
new -v flag.
Problem reported and fix provided by weerd@
job [Thu, 2 Sep 2021 12:41:44 +0000 (12:41 +0000)]
Lay groundwork to support X.509 v3 extensions for IP Addresses and AS Identifiers
These extensions are defined in RFC 3779 and used in the RPKI (RFC 6482, RFC 8360).
Imported from OpenSSL 1.1.1j (aaf2fcb575cdf6491b98ab4829abf78a3dec8402b8b81efc8f23c00d443981bf)
This changeset is a no-op, as there are 10+ issues and at least 2 security issues.
Work will continue in-tree.
OK tb@, discussed with beck@
mbuhl [Thu, 2 Sep 2021 12:40:44 +0000 (12:40 +0000)]
Import more NetBSD system call regression tests.
OK bluhm@
claudio [Thu, 2 Sep 2021 12:35:23 +0000 (12:35 +0000)]
Refactor how unveil generates EACCES errors. Instead of tracking the
possible violation during the traversal of the path do the check at the
end. Make the code a bit easier to grok.
OK beck@ semarie@
jasper [Thu, 2 Sep 2021 12:32:22 +0000 (12:32 +0000)]
trailing whitespace
patrick [Thu, 2 Sep 2021 12:09:26 +0000 (12:09 +0000)]
Fix comment spelling.
beck [Thu, 2 Sep 2021 11:58:30 +0000 (11:58 +0000)]
Call the ocsp callback if present and we get no response, instead of
succeeding unconditionally. Makes muststaple work with tls1.3 in nc
ok tb@
inoguchi [Thu, 2 Sep 2021 11:37:44 +0000 (11:37 +0000)]
Use defined constants
semarie [Thu, 2 Sep 2021 11:36:47 +0000 (11:36 +0000)]
atactl(8): few printf("%s", NULL) cleanup
ok deraadt@
inoguchi [Thu, 2 Sep 2021 11:30:15 +0000 (11:30 +0000)]
Add DB_TYPE_SUSP
semarie [Thu, 2 Sep 2021 11:26:54 +0000 (11:26 +0000)]
timeout(1): execvp(2) does not return except on error
there is no need to check if the return value is -1. just
unconditionally call err(3).
ok deraadt@ schwarze@
schwarze [Thu, 2 Sep 2021 11:19:02 +0000 (11:19 +0000)]
Make all signal handler functions async-signal-safe
by deleting the redundant "killersig" struct member
and using the existing sig_atomic_t cl_sigterm variable instead.
While here, garbage collect the h_hup() signal handler
which is essentially identical to h_term().
This also gets rid of the last #define & #undef in cl_main.c.
OK martijn@, and also tested by Tim <trondd at kagu hyphen tsuchi dot com>.
beck [Thu, 2 Sep 2021 11:10:43 +0000 (11:10 +0000)]
Correct the is_server flag in the call to the debug callback to be correct.
ok tb@
inoguchi [Thu, 2 Sep 2021 11:07:56 +0000 (11:07 +0000)]
Move subject check process after the subject edit process
Referred to OpenSSL commit
2cedf794 and arranged for our codebase.
ok tb@
deraadt [Thu, 2 Sep 2021 10:59:13 +0000 (10:59 +0000)]
Ah, I was fooled by a left over man page
mlarkin [Thu, 2 Sep 2021 10:49:26 +0000 (10:49 +0000)]
add aq(4) to amd64 RAMDISK_CD and riscv64 RAMDISK
kettenis [Thu, 2 Sep 2021 10:48:52 +0000 (10:48 +0000)]
Fix the TCR_TG0_xxx definitions and add TCR_TG0_4K to the initial setting
of TCR_EL1 in locore to make clear we use 4K pages for both userland and
the kernel.
ok patrick@
deraadt [Thu, 2 Sep 2021 10:46:22 +0000 (10:46 +0000)]
nameserver alias on domain (53) collided with true nameserver (42)
which would be parsed earlier in any case. what a weird piece of
history.
from Raf Czlonka
deraadt [Thu, 2 Sep 2021 10:39:32 +0000 (10:39 +0000)]
delete reference to X11 README file which is no longer installed.
from Raf Czlonka
mlarkin [Thu, 2 Sep 2021 10:18:27 +0000 (10:18 +0000)]
Typo in previous commit
mlarkin [Thu, 2 Sep 2021 10:17:46 +0000 (10:17 +0000)]
.Xr for aq(4) in pci(4) manpage
mlarkin [Thu, 2 Sep 2021 10:12:20 +0000 (10:12 +0000)]
Forgot the man page Makefile in the previous commit
mlarkin [Thu, 2 Sep 2021 10:11:21 +0000 (10:11 +0000)]
aq(4) driver for Aquantia 1/2.5/5/10Gb/s PCIe ethernet adapters
Adds support for Aquantia AQC1xx family of PCIe ethernet adapters. This
driver supports 1Gbps through 10Gbps modes of operation based on the
hardware and media/switch capabilities.
The initial code was ported from NetBSD, with jmatthew@ finishing up
the Tx/Rx ring support and interrupt handler routine.
The driver only supports devices using firmware V2.
This diff enables aq(4) on riscv64 and amd64, the only platforms where
I have tested the driver, but it likely works on other architectures
as well.