1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-11-21 07:15:49 +00:00
Commit Graph

10745 Commits

Author SHA1 Message Date
Graham Percival
e413da1358 manuals: fix "PP after SS | SH" warnings
The full mandoc warnings were:
    skipping paragraph macro: PP after SS
    skipping paragraph macro: PP after SH

The rendered output (in ascii and html) is not affected by this commit.

Fixes made by script in https://github.com/Tarsnap/freebsd-doc-scripts

Signed-off-by:	Graham Percival <gperciva@tarsnap.com>
Reviewed by:	jlduran, mhorne
MFC after:	1 week
Sponsored by:	Tarsnap Backup Inc.
Pull Request:	https://github.com/freebsd/freebsd-src/pull/1524
2024-11-14 16:59:43 -04:00
Kristof Provost
aa5d3dec9d route.8: remove now incorrect bug report about blackhole routes
We removed IP fast forwarding a while ago, so this is no longer relevant.
The netlink interface always sets the nexthop interface as V_loif, so users
don't need to worry about it either.

Reported by:	Jim Thompson
Reviewed by:	melifaro
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D47528
2024-11-13 09:12:32 +01:00
Ed Maste
3750ccefb8 Retire MK_PROFILE infrastructure
It was disabled by default in fe52b7f60e.  We planned to (but did not)
remove the option before FreeBSD 14.  Remove it now, for FreeBSD 15.

Relnotes:	Yes
Reviewed by:	imp
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D31558
2024-11-12 12:11:51 -05:00
Cy Schubert
9da30a23a5 ipfilter: Include the IP address in error message
Include the IP address in the message when a hashnode add error occurs.
This helps to identify the ippool.conf statement that the error occurred.

MFC after:	1 week
2024-11-11 19:22:15 -08:00
Cy Schubert
3a2cb65b6e ipfilter: Support printing of IPv6 addresses in error message
Replace inet_ntoa(3) with inet_ntop(3). This supporting the printing of
IPv6 IP addresses in addition to IPv4 IP addresses in error message.

MFC after:	1 week
2024-11-11 19:21:22 -08:00
Cy Schubert
858a7a27f5 ipfilter: Close a bracket in the poolnode error message
When a node in a tree is discovered in error, i.e. duplicate, the
IP address of the node is printed but no closing bracket completes
the node in the message. Fix this.

MFC after:	1 week
2024-11-11 19:20:49 -08:00
Cy Schubert
8aae4220d7 ipfilter: Print the hash name when adding a hashnode fails
As with when printing errors for failed poolnodes, printing the hash
node (IP address) only leads to speculation which hash pool the failed
add occurred. This is especially useful when the same IP address is
listed in multiple hash pools.

MFC after:	1 week
2024-11-11 19:18:08 -08:00
Cy Schubert
470c680cfb ipfilter: Print the pool name when adding a poolnode fails
Printing the pool node (IP address) only leads to speculation which
pool the failed add occurred. This is especially useful when the same
IP address is listed in multiple pools.

MFC after:	1 week
2024-11-11 19:15:45 -08:00
Cy Schubert
4293571628 ipfilter: Avoid overrunning the message buffer
Avoid overrunning the message buffer when printing an ippool btree error.
We do this in two ways. First we increase the message buffer from 80 to
255 bytes and secondly we replace strcat(3) with strlcat(3).

MFC after:	1 week
2024-11-11 19:14:31 -08:00
Mark Johnston
f7c45c0122 nvmecontrol tests: Fix nvmecontrol usage in a couple of tests
nvmecontrol {admin,io}-passthru's -r option doesn't take an argument,
so the tests which added one failed because they tried to open /dev/0.

MFC after:	1 week
2024-11-09 20:04:04 +00:00
Jose Luis Duran
5797a03fe8
ping tests: Run tests unprivileged inside a vnet
In order to create vnet jails, atf_python needs root privileges.
However, once the vnet is created, its privileges inside the vnet can be
demoted, as these tests should not require root in order to pass.

Reviewed by:	markj
Approved by:	emaste (mentor)
Fixes:	4efaf43c6f ("ping: Require root user for pytests")
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D42175
2024-11-05 03:07:32 +00:00
Jose Luis Duran
8b13cb9d65
ping tests: Silence deprecation warnings
Declare some regex patterns as a raw string by prepending `r`.

Reviewed by:	markj
Approved by:	emaste (mentor)
Differential Revision:	https://reviews.freebsd.org/D42174
2024-11-05 03:07:03 +00:00
Jose Luis Duran
4859030ef1
ping: tests: Align with Scapy defaults
Align some of pinger() defaults with Scapy to facilitate debugging when
printing packets.

No functional change intended.

Reviewed by:	emaste, kp
Approved by:	emaste (mentor)
Differential Revision:	https://reviews.freebsd.org/D47159
2024-11-05 02:48:34 +00:00
Jose Luis Duran
2e29bf7a2a
ping: tests: Cleanup IPOption()s
Scapy now only accepts known options with IPOption(), so our unknown
option must be passed raw.

While here, prefer the named options for EOL and NOP.

Reviewed by:	emaste, kp
Approved by:	emaste (mentor)
Differential Revision:	https://reviews.freebsd.org/D47160
2024-11-05 02:46:45 +00:00
John Baldwin
9e1db51d4b nvmecontrol: Use active nslist to enumerate namespaces
Rather than probing all namespace IDs up to cdata.nn for the devlist
command, fetch the active namespace list and iterate over that.  This
can be much quicker on Fabrics controllers which often advertise a
large cdata.nn value to support adding additional namespaces at
runtime.

Reviewed by:	chuck
Reported by:	Neven Z <nevenzfr@gmail.com>
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D47355
2024-11-04 20:28:40 -05:00
John Baldwin
326e20fc12 nvmecontrol: Refactor devlist implementation
Split out helper functions for scan_namespace and scan_controller.
While here, replace sprintf() calls with snprintf() and avoid
leaking the contoller fd if read_controller_data() fails.

Reviewed by:	chuck, imp
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D47354
2024-11-04 20:28:26 -05:00
Graham Percival
c7c3ef8949 manuals: Remove trailing spaces
This does not change the rendered ascii at all.

Signed-off-by:	Graham Percival <gperciva@tarsnap.com>
Reviewed by:	mhorne, Alexander Ziaee <concussious.bugzilla@runbox.com>
MFC after:	3 days
Sponsored by:	Tarsnap Backup Inc.
Pull Request:	https://github.com/freebsd/freebsd-src/pull/1473
2024-11-04 11:26:14 -04:00
Ed Maste
a5f7047f28 gvinum: Postpone removal to FreeBSD 15
It was not removed for FreeBSD 14.

Sponsored by:	The FreeBSD Foundation
2024-11-03 16:28:16 -05:00
Zhenlei Huang
5ec83c660a sysctl: Add flags to filter jail prison and vnet variables
So users do not have to contact the source code to tell whether a
variable is a jail prison / vnet one or not.

Reviewed by:	cy (previous version), markj, jamie (for #jails)
MFC after:	2 weeks
Relnotes:	yes
Differential Revision:	https://reviews.freebsd.org/D47107
2024-10-29 19:26:11 +08:00
Warner Losh
73979b7f0b camcontrol: Bump timeout to get size of drive
When the system is very busy, and the ATA hard disk drives are
overloaded due to reading dodgy sectors, it can take several seconds to
drain the NCQ set of commands to send this command to the drive. Up the
timeout from 5s to 10s out of an abundance of caution, but also to allow
monitioring software that uses camcontrol identify to not fail
needlessly.

Sponsored by:		Netflix
2024-10-28 16:43:25 -06:00
Graham Percival
759ddb4d24 manuals: Misc syntax fixes
These were reported by `mandoc -T lint ...` as errors.

Signed-off-by:	Graham Percival <gperciva@tarsnap.com>
Reviewed by:	mhorne, Alexander Ziaee <concussious.bugzilla@runbox.com>
Sponsored by:	Tarsnap Backup Inc.
Pull Request:	https://github.com/freebsd/freebsd-src/pull/1472
2024-10-28 12:26:03 -03:00
Mark Johnston
abfd031b48 camcontrol: Plug a memory leak in getdevtree()
PR:		275338
MFC after:	1 week
2024-10-28 15:14:36 +00:00
Mark Johnston
9b2f2fbfcb devmatch: Catch truncated linker hints files
PR:		282268
Reviewed by:	christos, imp
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D47243
2024-10-23 22:12:45 +00:00
Li-Wen Hsu
dab59af3bc
Canonicalize the name of the FreeBSD Foundation
Reviewed by:	emaste
Sponsored by:	The FreeBSD Foundation
2024-10-24 05:03:07 +08:00
Mark Johnston
eaab882600 Revert "Reapply "sbin/ping: allow normal users to specify larger packets""
The value of MAXPAYLOAD in the re-applied commit is not right.  Back
this out until it's had a proper review.

This reverts commit b88df1e893.

Requested by:	maxim, glebius
2024-10-20 15:52:28 +00:00
Zhenlei Huang
1c95ec17ca ifconfig: Fix wrong indentation for the status of pfsync(4)
The leading tab is always required, regardless of the configuration of
`syncdev` or `syncpeer`, as `maxupd`, `defer` and `version` all require
it.

Reviewed by:	kp
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D47112
2024-10-20 22:06:33 +08:00
Pedro F. Giffuni
b88df1e893 Reapply "sbin/ping: allow normal users to specify larger packets"
The ping tests were originally broken by an unrelated isue that
is now fixed ( 2926c25942 ).

THanks to kp@ for fixing the test and Jose Luis Duran for pinting it out.

This reverts commit 7bc0cb91a2.
2024-10-16 13:39:48 -05:00
Kristof Provost
2926c25942 ping tests: fix for scapy-2.6.0
Scapy 2.6.0 now appears to parse the IPOption during construction, and it then
gets confused at a single-byte option. IP Options typically contain at least a 1
byte type and 1 byte length. Avoid this by just returning the raw bytes, rather
than an IPOption object.

MFC after:	1 week
Reviewed by:	Jose Luis Duran <jlduran@gmail.com>
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D47151
2024-10-16 17:25:57 +02:00
Pedro F. Giffuni
7bc0cb91a2 Revert "sbin/ping: allow normal users to specify larger packets"
It is causing test failures.

This reverts commit 80a5b26871.
2024-10-16 00:23:58 -05:00
Pedro F. Giffuni
80a5b26871 sbin/ping: allow normal users to specify larger packets
Only super-user could specify a packet size larger than the default 56 bytes.
This restriction was added by Matt Dillon in 1998 during the BEST days [0].
This restriction doesn't exist in ping IPV6 or on NetBSD, OpenBSD and Linux.

UMS [1] uses this feature to estimate the client's bandwidth to optimize the
streaming experience.

[0] DFGit 526f06b278
[1] UMS: https://github.com/UniversalMediaServer/UniversalMediaServer

Obtained from:	DragonFlyBSD
Differential Revision:  https://reviews.freebsd.org/D45774
2024-10-15 20:05:50 -05:00
Graham Percival
6e1fc01180 manuals: Fix "unusual .Xr" warnings with a script
These were reported by `mandoc -T lint ...` as warnings:
- unusual Xr order
- unusual Xr punctuation

Fixes made by script in https://github.com/Tarsnap/freebsd-doc-scripts

Signed-off-by:	Graham Percival <gperciva@tarsnap.com>
Reviewed by:	mhorne, Alexander Ziaee <concussious.bugzilla@runbox.com>
Sponsored by:	Tarsnap Backup Inc.
Pull Request:	https://github.com/freebsd/freebsd-src/pull/1464
2024-10-15 17:18:14 -03:00
Kristof Provost
9c12533672 pf: convert DIOCGETSRCNODES to netlink
Sponsored by:	Rubicon Communications, LLC ("Netgate")
2024-10-15 16:29:11 +02:00
Simon J. Gerraty
a64729f507 Update Makefile.depend files
After building packages we have a number of new
and updated Makefile.depend files

Reviewed by:	stevek
2024-10-14 10:26:17 -07:00
Ed Maste
86e66321bb fdisk: emit deprecation notice when run
Requested by:	rgrimes
Reviewed by:	bapt
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D43585
2024-10-13 13:52:14 -04:00
Ed Maste
255d2d9bbc fdisk: add deprecation/removal notice to man page
As of 2015 (commit b8c19fd719) the fdisk man page claimed the command
is obsolete, but had no explicit mention of removal.  Add another note
that follows our current deprecation notice format.

Reviewed by:	imp
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D47067
2024-10-13 13:45:28 -04:00
Yan-Hao Wang
183e8aa749
mount(8): Complete libxo transition
Reviewed by:	des
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D41390
2024-10-13 02:21:47 +08:00
Warner Losh
2af5769e34 fdisk: Make confusing fdisk messages a little less ambiguous
We print an error when we can't read the MBR. Add minimal messages about
continuing anyway.

PR: 167036
Sponsored by:		Netflix
2024-10-11 12:06:33 -06:00
Kristof Provost
48f5bf8be6 pf: convert DIOCGETRULESET to netlink
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D46938
2024-10-10 14:10:41 +02:00
Kristof Provost
6562157dfa pfctl: avoid possible SIGSEGV when wrong tos option
Obtained from:	OpenBSD, haesbaert <haesbaert@openbsd.org>, 934eaac797
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D46933
2024-10-10 14:10:40 +02:00
Kristof Provost
25e0f8f99f pf: convert DIOCGETRULESETS to netlink
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D46930
2024-10-10 14:10:40 +02:00
Kristof Provost
ee9f418c80 pfctl: correctly print skip steps in -vv mode
- Changed order of address and ports.

Obtained from:	OpenBSD, mcbride <mcbride@openbsd.org>, 0bcfb1e086
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D46926
2024-10-10 14:10:39 +02:00
Graham Percival
d21e322d56 manuals: Fix "missing end of block" errors
These were reported by `mandoc -T lint ...` as errors.

The rendered output (in ascii and html) is not affected by this commit.

Signed-off-by:	Graham Percival <gperciva@tarsnap.com>
Reviewed by:	mhorne
MFC after:	3 days
Sponsored by:	Tarsnap Backup Inc.
Pull Request:	https://github.com/freebsd/freebsd-src/pull/1448
2024-10-07 15:40:58 -03:00
Graham Percival
4f2ef756a4 manuals: Fix "skipping end of block" .Ed errors
These were reported by `mandoc -T lint ...` as errors; this commit only
handles unnecessary .Ed commands.

The rendered output (in ascii and html) is not affected by this commit.

Signed-off-by:	Graham Percival <gperciva@tarsnap.com>
Reviewed by:	mhorne
MFC after:	3 days
Sponsored by:	Tarsnap Backup Inc.
Pull Request:	https://github.com/freebsd/freebsd-src/pull/1435
2024-10-03 14:49:23 -03:00
Kirk McKusick
5b21d4ad06 Ensure that soft updates are not enabled by default when using mdmfs(8)
When soft updates began being enabled by default that change carried
over to mdmfs(8) which does not want or need them. This fix ensures
that they are only enabled in mdmfs(8) when requested with the -U flag.

Reported by: Ivan Rozhuk
Tested by:   Ivan Rozhuk
PR:          279308
MFC after:   1 week
2024-10-03 08:06:28 -07:00
Kristof Provost
288bec2b2b pf: fold pf_test_fragment() into pf_test_rule()
Reduces code and fixes a bunch of bugs with fragment handling not being in sync
with the rest of the ruleset.

Much feedback from mpf, bluhm & markus
Thanks to Tony Sarendal for help with testing

ok bluhm; various previous versions ok henning, claudio, mpf, markus

Note that while this changes the order of src addr/src port/dst addr/dst port
skips this doesn't actually affect the kernel/userspace ABI. The kernel always
recalculates skip steps. As a result we have to fix one of the pfctl parser
tests. Note that this is an order change that does not affect what packets are
acceppted or dropped.

Obtained from:	OpenBSD, mcbride <mcbride@openbsd.org>, 04c69899a7
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D46705
2024-10-01 09:55:13 +02:00
Michael Osipov
38c63b5283 dhclient: Ignore vendor-identifying DHCP options defined in RFC 3925
Ignore DHCP options 124 and 125 to shut up the warning messages.
These options are defined in the RFC 3925.

PR:		281361
Reviewed by:	jrm (mentor), otis (mentor), thj
Tested by:	jlduran@gmail.com
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D46760
2024-09-28 10:49:02 +02:00
Graham Percival
ce251baf42 ipf.5: revert C style(9) applied to man page
These changes were made by accident in:
    ipfilter: Adjust userland returns to conform to style(9)
    2582ae5740

That commit made similar mistakes in other man pages, but those have
already been fixed.

Signed-off-by:	Graham Percival <gperciva@tarsnap.com>
Reviewed by:	mhorne
Sponsored by:	Tarsnap Backup Inc.
Pull Request:	https://github.com/freebsd/freebsd-src/pull/1433
2024-09-24 14:29:39 -03:00
David E. Cross
1b1e392aed ggate: Add support for O_DIRECT access
Adds support for controlling O_DIRECT access to ggated, ggatec, and
ggatel.

Reviewed by:	markj
Relnotes:	yes
MFC after:	1 month
Differential Revision:	https://reviews.freebsd.org/D45056
2024-09-21 13:05:22 +00:00
Alexander Ziaee
2a680c5c37 sysctl.8: mark sysctls as vars per style.mdoc(7)
+ while here, fix alignment and tag SPDX

MFC after:	3 days

Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/1421
2024-09-21 05:25:16 -06:00
Kristof Provost
7309c551a5 pf tests: test the new log(matches) feature
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D46589
2024-09-19 22:20:13 +02:00