summaryrefslogtreecommitdiff
path: root/usr.sbin
AgeCommit message (Collapse)Author
2023-01-24Print the ASPA validation state (avs) in various show rib outputs.Claudio Jeker
OK tb@
2023-01-24Implement ASPA validation and reload logic on ASPA set changes.Claudio Jeker
For this use the validation state (vstate) in struct prefix and struct filterstate to store both the ASPA and ROA validity. Introduce helper functions to set and get the various states for struct prefix and make sure struct filterstate is also setup properly. Change the ASPA state in rde_aspath to be AFI/AID and role independent by storing all 4 possible outcomes. Also add a ASPA generation count which is used to update the rde_aspath ASPA state cache on reloads. Rework the rde_aspa.c code to be AFI/AID and role independent. Doing this for roles is trivial but AFI switch goes deep and is so unnecessary. The reload is combined with the ROA reload logic and renamed to RPKI softreload. OK tb@
2023-01-24match unknown ATI display devices as amdgpu in fw_updateJonathan Gray
For recent devices amdgpu matches via the hardware ip discovery table, not with a table of pci vendor and product ids. So amdgpu_devlist.h and pcidevs do not cover all devices that amdgpu may match. in dmesg amdgpu with an unknown product takes the form: ramdisk kernel, bios/mbr: vga1 at pci12 dev 0 function 0 vendor "ATI", unknown product 0x687f rev 0xc3 ramdisk kernel, efi or non-x86 arch: vendor "ATI", unknown product 0x687f (class display subclass VGA, rev 0x03) at pci12 dev 0 function 0 not configured non-ramdisk kernel: amdgpu0 at pci12 dev 0 function 0 vendor "ATI", unknown product 0x687f rev 0xc3 ok deraadt@ on an earlier version
2023-01-22vmd(8): don't remove known vm's from the config on error.Dave Voutila
Multiple error paths, specifically the one related to if a guest cannot allocate memory at start, resulted in a known vm (via vm.conf(5)) being removed from the vm list. Adjust the error paths to check if the failing vm is defined in the config before tearing it down. Tested with help from beck@ and Mischa Peters. ok beck@
2023-01-20Sync usage with SYNOPSIS, mention that -x may use stdoutKlemens Nanni
Feedback from jmc and Crystal Kolipe OK jmc
2023-01-20Remove 'allow' from aspa-set provider-set lists. That keyword is no longerClaudio Jeker
needed. OK tb@
2023-01-20Document the aspa-set table. While there remove the superfluous 'allow'Claudio Jeker
keyword. OK tb@
2023-01-20comma space not space commaClaudio Jeker
2023-01-20Bad indentClaudio Jeker
2023-01-20remove extra tabClaudio Jeker
2023-01-18Require version 4 UUIDs as RRDP session IDsJob Snijders
OK tb@
2023-01-18Use the vstate of the filterstate struct instead of passing an extra copyClaudio Jeker
to the various prefix update functions. While there fix a filterstate leak in up_generate_updates(). With and OK tb@
2023-01-18Improve pending checks in poll loop by ordering them by trigger frequencyClaudio Jeker
and by making peer_imsg_pending() a true O(1) function. OK tb@
2023-01-18The default output format is -o (openbgpd) but it now includes bothClaudio Jeker
roa-set and aspa-set by default. So make the man page less specific. OK tb@ job@ kn@
2023-01-18rpki-client: explicitly enable policy checksTheo Buehler
In x509_verify.c r1.62, beck disabled policy checks by default in the new X.509 verifier to match the behavior of the legacy validator and OpenSSL. In order to keep policy checks as mandated by RFC 7318, we need to opt into them explicitly. ok beck
2023-01-17Teach bgpctl about ASPA tables.Claudio Jeker
OK tb@
2023-01-17Add the needed logic to load the ASPA table from the rtr process into theClaudio Jeker
RDE. The actual reload logic is missing to keep the diff small. OK tb@
2023-01-16Enable softraid(4) support in installboot(8)Klemens Nanni
riscv64 efiboot already supports booting from softraid volumes. These installboot bits make sure that the boot loader will be installed on chunk devices rather than the volume for root on softraid installations, i.e. full boot support for riscv64, just like amd64, arm64 and sparc64. regress is happy. OK kettenis
2023-01-16Fix bad MP logic in the route refresh handling.Claudio Jeker
Found by and fix provided by Zenon Mousmoulas (@zmousm)
2023-01-14Only open /dev/vmm once in vmd(8).Dave Voutila
Have the parent process open /dev/vmm and send the fd to the vmm child process. Only the vmm process and its resulting children (guest vms) need it for ioctl calls. ok kn@
2023-01-13Add aspa-set to openbgpd config output.Claudio Jeker
Change the way the validated ASPA tree is built since OpenBGPD config follows more the ASPA profile and puts the optional AFI to each provider ASnum instead of duplicated everything into an IPv4 and IPv6 tree. The JSON output of ASPA is still the same. The inclusion of the aspa-set can currently be disabled by the -A flag. OK tb@
2023-01-12Split rde_filterstate_prep() into three functions.Claudio Jeker
- rde_filterstate_init(): initialize a filterstate to default values - rde_filterstate_copy(): copy from a filterstate into a new state object - rde_filterstate_prep(): set filtersate based on prefix passed as argument. This makes the code a bit easier to read. OK tb@
2023-01-11Add the validation state to the filterstate struct.Claudio Jeker
Removes vstate argument from rde_filter(). Rename prefix_vstate() to prefix_roa_vstate(). OK tb@
2023-01-11Add ASPA validation functions to the RDE.Claudio Jeker
This implements ASPA validation based on the current draft. Implementing this showed various weaknesses in the current ASPA draft which I hope to fix in the near future. Unlike the algorithm specified in the draft our version validates the AS_PATH attribute in a single path doing one or two lookups depending on the sessions BGP role. The code is not yet hooked up into the RDE (see the NOTYET blocks). Missing are reload logic, bgpctl integration and the loading of the merged ASPA set from the rtr process. OK tb@
2023-01-10Improve timestamp printing in filemodeJob Snijders
OK claudio@
2023-01-08vmd(8): add thread names to vm process.Dave Voutila
ok guenther@.
2023-01-07The maximum length of the value is extended to 64k bytes.ASOU Masato
ok yasuoka
2023-01-06Rework the main <-> parser/filemode communication protocol a bit.Claudio Jeker
Swap repo_id and filename to simplify the code in parser.c. In filemode both repo_id and filename are ignored. Additionally do not errx() in case of unknown file types. Instead send back enough info that the code can move on. OK tb@
2023-01-06sync with rpki-client 'more dastardly white spaces' commitTheo Buehler
2023-01-06more dastardly white spacesTheo de Raadt
2023-01-06Zap trailing tabsTheo Buehler
2023-01-04Print RRDP serial + ID if nothing changedJob Snijders
OK tb@
2023-01-04Christos Zoulas removed his name from advertising clauses and copyrightsJonathan Gray
of some files in NetBSD. Make the same changes here. https://mail-index.netbsd.org/source-changes/2017/06/03/msg084953.html https://mail-index.netbsd.org/source-changes/2017/06/03/msg084955.html https://mail-index.netbsd.org/source-changes/2019/12/02/msg111431.html https://mail-index.netbsd.org/source-changes/2019/12/02/msg111432.html
2023-01-04Add a per eBGP session role to the config.Claudio Jeker
This somewhat replaces the RFC 9234 open policy role. This is done because ASPA requires the same role to be present to properly validate paths. For iBGP sessions the role is forced to ROLE_NONE. If no role is set on an ebgp session then 'announce policy' is forced to 'no'. Also make sure the the role capability is only added if the role is set. OK tb@
2023-01-04Validate the session_id to be a real UUID.Claudio Jeker
RFC 8182 requires the session_id to be a version 4 random UUID (using variant 1). Now checking the version and variant is currently disabled because there is at least one CA with a session_id that is all random and therefor the version check triggers there. Joint work with job@. OK job@, tb@
2023-01-04Christos Zoulas agreed to rescind clause 3 and 4 inJonathan Gray
NetBSD fsck.8 rev 1.35 fsutil.h rev 1.14 pathnames.h rev 1.2 netgroup_mkdb.8 rev 1.9 netgroup_mkdb.c rev 1.18 str.c rev 1.7 str.h rev 1.4 rdate.8 rev 1.11 rdate.c rev 1.19 extern.h rev 1.14 getnetgrent.c rev 1.41 netgroup.h rev 1.10 fparseln.3 rev 1.4 fparseln.c rev 1.10 our stringlist.c/stringlist.h are derived from getnetgrent.c rfc868time.c from rdate.c newfs/pathnames.h from fsck/pathnames.h https://mail-index.netbsd.org/source-changes/2009/10/21/msg002182.html Not all files are covered as some had copyright assigned to TNF in 1998.
2023-01-04Typos in vmd error message. No functional change.Dave Voutila
2023-01-03do not mention dhclient as a dhcp route message senderTheo de Raadt
2023-01-03Print the RRDP Session ID and Serial in verbose modeJob Snijders
OK tb@ claudio@
2022-12-30accton.c: add missing $OpenBSD$ tagScott Soule Cheloha
2022-12-28{en,de}queing -> {en,de}queuing; from paul tagliamonteJason McIntyre
2022-12-28spelling fixes; from paul tagliamonteJason McIntyre
any parts of his diff not taken are noted on tech
2022-12-28iostat(8): implement periodic display with setitimer(2)Scott Soule Cheloha
Prefer setitimer(2)+sigsuspend(2) to nanosleep(2) when performing periodic work. The latter drifts. Link: https://marc.info/?l=openbsd-tech&m=167068674625838&w=2 ok millert@
2018-04-27Import lpd, a re-implementation of the lpr daemon following the latestEric Faurot
OpenBSD coding practices (fork+exec/privsep/pledge/...). It is only intended to replace the lpd(8) daemon for the moment, not the lpr(1), lprm(1), lpq(1) and lpc(8) commands. This is a work in progress. The server part should be fairly functionnal, but the printer part is not complete: remote printers should work, for local printers it depends on the setup. Anyway, at this point it's better in the tree than rotting on my disk. ok deraadt@
2022-12-28style(9) for includesTheo Buehler
2022-12-28Properly ignore comments in geofeed filesTheo Buehler
Do not consider comments and whitespace leading up to a comment as part of the line. ok claudio job
2022-12-27Adjust handling of the RFC 9234 role capability for ibgp sessions:Claudio Jeker
- Exclude the role capability on ibgp sessions when sending an OPEN - Warn when a role capability is received on an iBGP session - Make sure the capability negotiation is skipped for ibgp sessions, this in turn disables the role capability on the session. OK tb@
2022-12-27Only print the hello_timer if it is actually running.Claudio Jeker
Problem reported by Wouter Prins. Initial diff by kn@ OK remi@
2022-12-26vmd(8): provide a detailed e820 memory map.Dave Voutila
When booting guests with SeaBIOS, vmd(8) supplied details about the available guest memory via CMOS registers. Consequently, we've been carrying some patches in the ports tree to SeaBIOS to fetch this information like it's the 1990s. When a vm initializes memory ranges, we now track what each range represents. This information can be used to supply the e820 memory map to SeaBIOS via the fw_cfg interface allowing it to properly communicate memory ranges to a guest operating system. (This will also allow us to drop some patches from the port.) Given the ranges can now be marked with a purpose, this also allows vmm(4) to switch from hard-coded mmio ranges and instead let the information on the memory range dictate if vmm should be handling a page fault or sending to vmd for a memory assist. Tested by Mischa Peters and others. OK mlarkin@.
2022-12-23vmd(8): implement zero-copy operations on virtqueues.Dave Voutila
The original virtio device implementation relied on allocating a buffer on heap, copying the virtqueue from the guest, mutating the copy, and then overwriting the virtqueue in the guest. While the approach worked, it was both complex and added extra overhead. On older hardware, switching to the zero-copy approach can show a noticeable performance improvement for vionet devices. An added benefit is this diff also reduces the amount of code in vmd, which is always a welcome change. In addition, change to talking about the queue pfn and not "address" as the virtio-pci spec has drivers provide a 32-bit value representing the physical page number of the location in guest memory, not the linear address. Original idea from dlg@ while working on re-adding async task queues. ok dlg@, tested by many