Commit Graph

6848 Commits

Author SHA1 Message Date
roy 5d499f6897 Resolve every route(4) message type before printing anything more about it
other than the type and length.

This solves the issue where RTM_ONEWADDR is received and it tries to
parse route information from it.
2018-08-14 20:53:07 +00:00
roy 76fcbe2e7c Mark _error() as printflikee 2018-08-02 03:40:51 +00:00
wiz b277a5a934 Various improvements to the man page. 2018-08-01 17:26:30 +00:00
sevan 162b461b88 Remove references to XNS 2018-07-31 21:22:09 +00:00
sevan 6733b800d4 Remove ISO & XNS references which are now long gone. 2018-07-31 20:54:18 +00:00
khorben d7f036be09 Add a port of the umb(4) driver from OpenBSD
The umb(4) driver provides support for USB MBIM (Mobile Broadband
Interface Model) devices.

MBIM devices establish connections via cellular networks such as GPRS,
UMTS, and LTE. They appear as a regular point-to-point network interface, transporting raw IP frames.

Required configuration parameters like PIN and APN have to be set with
umbctl(8), a new tool specific to this driver. The IP address is configured
automatically; the default route and DNS server information have to be set
separately.

The driver is not fully functional yet, it is therefore still marked as
experimental and disabled by default. Any help welcome to complete it!

Tested on NetBSD/amd64, with a Sierra Wireless EM7345 LTE modem on a Lenovo
ThinkPad T440s. No functional change expected otherwise.
2018-07-31 16:44:28 +00:00
wiz 75bef1827d Remove superfluous macro. 2018-07-18 17:57:00 +00:00
dholland be73ca0156 Document what rrestore is (was once) for. PR 53442.
CVS: ----------------------------------------------------------------------
2018-07-15 06:16:12 +00:00
dholland c0640bfe41 Document what rdump is (was once) for. PR 53442. 2018-07-15 06:14:13 +00:00
jnemeth aa3b5bb2ee Not all things that write to the disk do something that dk(4) will
be interested in.  Let individual commands decide if ioctl(DIOCMWEDGES)
should be done.  I was conservative and set the flag on any command
that might create/modify/delete partitions in any way.
2018-07-03 03:41:23 +00:00
sevan ab8dd17d7b vnconfig name is retained for backwards compatibility. Use vndconfig.
Heads up by <tsutsui>
2018-06-30 09:27:41 +00:00
sevan 8ec25d68b5 Note vnconfig(8) may be of interest, especially when looking to mount an iso via
loopback.
2018-06-29 19:13:19 +00:00
kamil bd8efe16d3 Avoid misaligned access in disklabel(8) in find_label()
Introduce a new helper variable tlp and use it for memory access.

Detected with MKSANITIZER/UBSan

A patch by <christos>
2018-06-27 01:14:48 +00:00
zafer c3796b42cb Remove duplicate assignments.
Fixes PR bin/51512 by Jose Luis Rodriguez Garcia
2018-06-12 20:12:21 +00:00
kamil 5f51a87ea5 Correct Undefined Behavior in ifconfig(8)
Unportable left shift reported with MKSANITIZER=yes USE_SANITIZER=undefined:

# ifconfig
alc0: flags=0x8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
        ec_capabilities=3<VLAN_MTU,VLAN_HWTAGGING>
        ec_enabled=0
        address: xx:xx:xx:xx:xx:xx
/public/src.git/sbin/ifconfig/af_inet.c:102:34: runtime error: left shift of 16777215 by 8 places cannot be represented in type 'int'
        inet 192.168.0.38/24 broadcast 192.168.0.255 flags 0x0
        inet6 xxxx::xxxx:xxxx:xxxx:xxx%alc0/64 flags 0x0 scopeid 0x1
lo0: flags=0x8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 33624
        inet 127.0.0.1/8 flags 0x0
        inet6 ::1/128 flags 0x20<NODAD>
        inet6 fe80::1%lo0/64 flags 0x0 scopeid 0x2

Change shifting left 1 to shifting 1U. This corrects the issue.

        if (cidr < 32) {                /* more than 1 bit in mask */
                /* check for non-contig netmask */
                if ((mask ^ (((1 << cidr) - 1) << (32 - cidr))) != 0) // <- here
                        return -1;      /* noncontig, no pfxlen */
        }

Solution suggested by <uwe>

Sponsored by <The NetBSD Foundation>
2018-06-11 17:45:50 +00:00
kamil 1c426e1841 Restore the MKGROFF=bo MKCXX=yes build
Mark the documentation in dc(1), gprof(1), rogue(6) and fsck_ffs(8) with
the .roff flag in SUBDIR.

Sponsored by <The NetBSD Foundation>
2018-06-11 14:18:16 +00:00
wiz 36ad4ce7a8 Remove Tn for standard abbreviations. 2018-05-17 06:37:06 +00:00
thorpej e832c294bb Default NFS mounts to using TCP transport instead of UDP.
PR kern/53166
2018-05-17 02:34:31 +00:00
kre 0efffb3e4f With the change to use getpass_r the 128 byte passphrase limit no
longer applies, so update the BUGS section here to reflect that change.
The limit now is 1023 whichever method is used to fetch the passphrase.
2018-05-09 20:23:35 +00:00
alnsn 265610788f use explicit_memset(3) 2018-05-09 19:38:46 +00:00
alnsn 98def45107 Missed one change when doing a manual merge of my patch with kre's commit. 2018-05-09 18:18:11 +00:00
alnsn bf3984213d Add '-e' option (echo the passphrase) and wipe the passphrase after use.
XXX Using memset for wiping isn't a good idea because memset is likely
optimised away by gcc. This should be revisited.
2018-05-09 18:11:56 +00:00
wiz 9f41709322 Add commas in enumeration. 2018-05-09 17:35:03 +00:00
kre 2d50dc8f17 Fix missing -p in usage message (noted by Christoph Badura, thanks),
and update -l usage as well.

While here fix man page synopses and a few other odds and ends.
2018-05-09 14:27:41 +00:00
kre 99316b228e Check arg count in configure() at entry, rather than later.
This avoids the stupid null deref I added a couple of commits
ago (on bad usage) and also simplifies the rest of the routine
which no longer needs to check the arg count nearly as much.

Thanks to Alexander Nasonov for finding the null deref bug.
2018-05-09 13:19:33 +00:00
kre ed050bc6ea Fix usage for rump. Fixes test breakage caused by previous commit. 2018-05-06 20:55:42 +00:00
kre 8880a43f55 Check whether the cgd device selected is available to be
configured,that is, not already in use, before requesting
passwords from the user (or elsewhere).
2018-05-05 11:28:44 +00:00
kre 1c825c2c91 Spello. (it is "existence").
ispell also says that we should s/parseable/parsable/ but I'm
not sure about that one, so I left it.

I also left a correct spelling that no-one has bothered to mangle!
2018-05-01 21:16:02 +00:00
wiz 64f2452046 Bump date for new EXIT STATUS section. 2018-05-01 21:04:01 +00:00
wiz 32e2530e6d Sort sections. 2018-05-01 21:03:37 +00:00
martin 72be6dafa1 Make the "gpt header" command return EXIT_FAILURE when no GPT is present.
This helps sysinst to tell a GPT labeled disk from others.
Very lazy version of a change proposed by kre.
2018-05-01 08:17:13 +00:00
maxv b5d4b113f7 Add code 3 of paramprob, part of RFC7112: "IPv6 First Fragment has
incomplete IPv6 Header Chain". Handle this code in ping6.
2018-04-24 07:22:32 +00:00
maxv 519a11ad08 Remove annoying (void) casts. 2018-04-24 07:12:04 +00:00
maxv f025b20b34 Remove double include and unused macros. 2018-04-23 18:48:30 +00:00
maxv f4598fe58b Remove the "-R" option. It uses IPV6_REACHCONF, but we've never had
this.
2018-04-23 18:44:39 +00:00
maxv fa0be10b46 Fix usage(), A/E don't exist. 2018-04-23 18:37:19 +00:00
maxv ed8f79525d Simplify: remove #ifdefs for constants that are always defined, and
remove their #else's (some of which can't compile, since they use values
that since got removed).
2018-04-23 18:32:18 +00:00
maxv a845eccede Remove dead/broken code, we want to favor RFC3542 over RFC2292. No
functional change. traceroute6 and rtadvd did the same.
2018-04-23 10:35:20 +00:00
wiz da9f189127 Sort options. Sort option descriptions. Remove Tn.
Sync usage (more) with man page.
2018-04-23 07:25:36 +00:00
maxv 9948652569 Remove the "hops" parameter, it uses RH0, which is deprecated by RFC5095,
and doesn't work on modern networks anymore.
2018-04-23 06:51:25 +00:00
nonaka ca639f32c5 nvmectl(8): Remove some wdc subcommands from man page.
- wdc drive-log
- wdc get-crash-dump
- wdc purge
- wdc purge-monitor
2018-04-18 10:17:54 +00:00
nonaka d2ae75c29e nvmectl(8): fix subcommand usage. 2018-04-18 10:16:22 +00:00
nonaka 6ac76f5b92 nvmectl(8): Add big-endian support.
from FreeBSD nvmecontolr(8) r329824.
2018-04-18 10:11:44 +00:00
nonaka 605c860b16 nvmectl(8): fix wdc command usage. 2018-04-17 15:31:00 +00:00
nonaka 1f5086ec4f nvmectl(8): Sync with FreeBSD nvmecontrol(8) r328763. 2018-04-17 08:54:35 +00:00
maxv bc7ed98e99 typo in comment 2018-04-15 08:27:21 +00:00
kre 329132e2a8 Make timestamp reading code adapt to whatever precision (up to
nanoseconds, 9 digits) the kernel happens to send in the timestamps
in log messages.

Output (numeric) timestamps (when produced) are unchanged and always
in microseconds (for now).
2018-04-14 01:37:34 +00:00
kre 2b71f00cba Minor wording change (no date bump needed.) 2018-04-14 01:34:47 +00:00
mrg 28731ff616 if a new map entry doesn't fit, be more verbose about the sizes. 2018-04-11 07:14:23 +00:00
mrg d144e17dce add information about how to boot from gpt. mostly taken from the wiki. 2018-04-11 07:13:18 +00:00