summaryrefslogtreecommitdiff
path: root/sbin
AgeCommit message (Collapse)Author
2021-07-05Print SA MTU if included in pfkey message.tobhe
ok bluhm@ sthen@ mpi@
2021-07-04Fix legacy booting.Kenneth R Westerback
Don't flag the EFI SYS partition "DOSACTIVE". Leave that status to the OpenBSD partition. Reverts part of r1.77. Problem reported and fix tested by Mihai Popescu. Thanks! Cluebats from deraadt@ and code bisecting by dv@. ok kettenis@
2021-07-04store provider ID in umb(4), and display it in ifconfig. OK stsp deraadtStuart Henderson
Previously only the provider's display name was used. The text used depends on how the SIM is configured and not just on the network in use (for example, an MVNO SIM on another network will often display the MVNO's name rather than that of the underlying network). I have a SIM that roams to any network in my country - whichever network it roams onto, the display name is the same, so you can't tell which network you're really using. By printing the provider ID (in GSM-land this is MCC+MNC) it's easy to lookup and check this. As the provider was printed on the ifconfig line also showing subscriber-id and ICCID it was already a bit long, and adding the provider-id there is a bit too much, so move it to the output line showing APN, now looking like : subscriber-id 2400xxxxxxxxxxx ICC-id 8946203xxxxxxxxxxxxx : device EM7455 IMEI 01458xxxxxxxxxx firmware SWI9X30C_02.24.0 : APN key provider Tele2 IoT provider-id 23420
2021-07-02call the API function X509_NAME_cmp(3) instead of the obsolete,Ingo Schwarze
undocumented macro alias X509_name_cmp(3); no binary change; OK tb@
2021-06-29Send AUTHENTICATION_FAILED in case of unexpected auth method or authtobhe
data not being accessible. From Claudia Priesterjahn @ achelos ok patrick@
2021-06-28Add another epicycle to -A processing that ensures ONLY theKenneth R Westerback
partition table is changed. Not the GPT header. Not the MBR. And only write back as much partition table information as the header claims to have room for. At a minimum should make -A safer when operating on the Apple M1 GPT. A major overhaul of this code is urgently needed before someone sneezes too hard in its vicinity. Feedback kettenis@ & ok deraadt@
2021-06-26delete extra explanations in the usage: messages which are describedTheo de Raadt
far better in the manual pages ok jmc
2021-06-25Replace instances of the magic number '64' with a nice #defineKenneth R Westerback
BLOCKALIGNMENT. This will make it more obvious where this 512-byte block count could/should be converted to a disk sector count. No functional change.
2021-06-24trim usage to match the man page;Jason McIntyre
remove -DSEEALSO, as suggested by millert ok millert
2021-06-23The value of -l should be treated as a 512-byte block count.Kenneth R Westerback
Tweak man page.
2021-06-23Use print_host() to log destination, netmask and gateway. Add prettytobhe
printing for route flags. ok markus@
2021-06-23Factor out vroute_addr().tobhe
ok markus@
2021-06-22Pp not required before list items;Jason McIntyre
2021-06-22reduce verbosity of usage(); keep it the same as SYNOPSIS, wrapped at 80w.Jason McIntyre
lowercase for "usage", and add -e, which was missing; ok kettenis
2021-06-22The values for blocks and offset in -b should be treated as 512-byte blockKenneth R Westerback
counts. Tweak man page accordingly. Requested by deraadt@ and kettenis@.
2021-06-21Wrap #define nitems in #ifndef nitems/#endif.Kenneth R Westerback
While here fix a misplaced '(' to make this nitems the same as all its friends. Pointed out by okan@
2021-06-21Add -A option to "safely" initialize a GPT without removingKenneth R Westerback
special boot partitions needed by some hardware. Make it difficult to add, delete or modify those partitions with 'fdisk -e'. Trim back and correct syntax in usage(). Whack at man page verbiage. Suggestions and ok deraadt@
2021-06-20replace the Oo/Oc block of -chs in SYNOPSIS with a simple Op: the blockJason McIntyre
would have been written this way because of the old args limit, but the extensions to -b expose a nasty line wrap when written that way;
2021-06-20few more Ns in the -b option descriptionTheo de Raadt
2021-06-20Make -b available to architectures other than amd64 and i386.Kenneth R Westerback
Extend the syntax to allow the boot partition offset and boot partition type to be specified if needed. ok deraadt@ kettenis@
2021-06-20Put (boot) filename, next-server, host-name and domain-name into leaseFlorian Obser
file for the installer.
2021-06-18fix SMALL buildFlorian Obser
2021-06-17Skip flows in ikev2_cp_addr() if they don't contain a dynamic (0.0.0.0)tobhe
address before checking sa_addrpool. Fixes a bug where no flows are added if a single address instead of a pool is configured in config address. Reported by Sebastien Leclerc ok patrick@
2021-06-16Ensure that the '-i' command line option and the 'reinit [mbr]'Kenneth R Westerback
editing commnd completely remove any existing on-disk GPT header when writing the MBR. '-ig'/'reinit gpt' must be used to create GPT format. Previous interactions between '-i', '-b' and overly clever 'reinit' produced surprising, inconsistent and incorrect behaviour. ok deraadt@ kettenis@
2021-06-16Actually request classless static routes from the dhcp server; missedFlorian Obser
in previous.
2021-06-16Implement classless static routes dhcp option.Florian Obser
For this we need to be able to handle multiple routes being sent from the engine to the main process as well as to the control tool. The configuration of the various cases (default route, directly connected routes, non-default route via a gateway) was inspired by dhclient's set_routes() and should behave the same way. Tested by Uwe Werler
2021-06-14Only use of 'reinited' died in cmd.c r1.100. It is now set in aKenneth R Westerback
couple of places but never checked. Retire it. No functional change.
2021-06-14Somewhere in the recent churn a couple of memset()'sKenneth R Westerback
inadvertantly got lost. Restore merciless zapping of gpt header & partition entries when '-i -g' or 'reinit [gpt]' are invoked.
2021-06-13There is no '!' in HiFive.Kenneth R Westerback
Pointed out by kettenis@
2021-06-13Have gedit() and gsetpid() both return CMD_CLEAN if no data hasKenneth R Westerback
changed, thus keeping the modified indicator correct and avoiding early bailout when editing a gpt partition w/o changing the type.
2021-06-13Tweak gsetpid() to restore partition info in case of an error,Kenneth R Westerback
and mark the partition dirty only if something changed. More aligned with gedit() and safer when invoked directly from Xsetpid().
2021-06-13UUID_STR_LEN+1 is less mysterious than '37'.Kenneth R Westerback
2021-06-13Don't ignore a GPT that claims the last usable LBA is locatedKenneth R Westerback
past the address where alternate partition entries would be written. Just adjust the GPT header value (gh_lba_end) to the highest safe value and carry on. Issue encountered in the wild by mlarkin@ while accessing some disk images. ok deraadt@
2021-06-13Fix lba_start >= lba_end debug message.Kenneth R Westerback
2021-06-12Ooops. Managed to typo 'gh' instead of 'gp' when copyingKenneth R Westerback
code from GPT_init() into init_gh().
2021-06-12Recognize "HiFive! FSBL" and "HiFive! BBL" GPT partitions.Kenneth R Westerback
Seen on SiFive Unmatched stock image provided by mlarkin@.
2021-06-12Abstract init_gh() and init_gp() from GPT_init().Kenneth R Westerback
Restore original gh/gp if initialization fails. No other functional change.
2021-06-12GPT_get_header() and GPT_get_partition_table() are only usedKenneth R Westerback
in gpt.c. Move declarations and rename to get_header() and get_partition_table(). No functional change.
2021-06-12When initializing a GPT always create an EFI SYS partition if theKenneth R Westerback
'-b' option is specified. GPT is no longer a __i386__/__amd64__ thing. ok kettenis@
2021-06-12Create add_partition() and use in GPT_init() to initialize GPTKenneth R Westerback
with EFI SYS and OpenBSD partitions. Replaces some barbarian direct whacking of GPT. ok kettenis@
2021-06-12Use a new variable 'gpbytes' rather than 'sizeof(gp)' to controlKenneth R Westerback
the number of bytes of partition entries to write to disk. Set gpbytes to 'sizeof(gp)' so no functional change for now.
2021-06-11Oops. Restore error message when no free space found.Kenneth R Westerback
2021-06-11Add local function lba_free() to find the bounds of the largestKenneth R Westerback
chunk of free space in a GPT. Steal logic from GPT_get_lba_start(). No intentional functional change.
2021-06-11Add local functions edit() and setpid().Kenneth R Westerback
Reduce Xedit()/Xsetpid() to parsing the partition number and invoking [g]edit()/[g]setpid() appropriately. No intentional functional change.
2021-06-11Take a bit more obvious care in gedit() to restore originalKenneth R Westerback
partition information when one of the modification steps (e.g. setting the partition type via gsetpid()) fails.
2021-06-11Revert previous change in ikev2_cp_fixaddr().tobhe
Fixes a regression found by landry@. ok patrick@
2021-06-11No need to parse partition number more than necessary. Just passKenneth R Westerback
a parsed number to the helper functions gedit() and gsetpid(). No functional change.
2021-06-10Another hand rolled partition number parsing bites the dust.Kenneth R Westerback
2021-06-10Missed an occurance of hand rolled partition number parsing.Kenneth R Westerback
No intentional funtional change.
2021-06-10Abstract repeated parsing of partition numbers into parsepn() toKenneth R Westerback
simplify the code. No intentional funtional change.