aboutsummaryrefslogtreecommitdiff
path: root/libexec
Commit message (Collapse)AuthorAgeFilesLines
* leapseconds: Update to the canonical place.Warner Losh2024-02-141-2/+2
| | | | | | | | | | | | | | | | | | | | | IERS is the source of truth for leap seconds. Their leapsecond file is updated most quickly and is always right (unlike the IANA one which often lags). IERS operates this public service for the express purpose of random people downloading it. Their terms of service are compatible with open source (we could include this in our release). Rather than fighting with questions around this because the IANA one changed locations or the auto update script broken, just use this. This is in preference to the NIST ftp copy. NIST is in the process of retiring their FTP services. Sponsored by: Netflix Reviewed by: philip, delphij, cy Approved by: re (cperciva) Differential Revision: https://reviews.freebsd.org/D43752 (cherry picked from commit 11da791920ba285f0832f09cb504ac81e35ff8d1) (cherry picked from commit 0eea8292ae8c8e9119520ce54aa82cae491d83b9)
* rc.d/kdc: Support start of MIT krb5kdcCy Schubert2024-01-291-6/+4
| | | | | | | | | | | | | | | | | Some users wishing to use the MIT krb5kdc have discovered the kdc script workaround applied to the MIT krb5 ports is insufficient. Let's build into this rc script the smarts to determine whether base or ports Hiemdal kdc is being invoked or the MIT krb5kdc. While at it, remove kdc_start_precmd(). This will simplify a future jail patch. Suggested by: netchild Original patch: netchild Reviewed by: emaste, netchild Differential Revision: https://reviews.freebsd.org/D43523 (cherry picked from commit 91f78c32befa08bf4010db7afd4407277a3e585f)
* bootpd(8): Fix a typo in a source code commentGordon Bergling2024-01-251-1/+1
| | | | | | - s/adddress/address/ (cherry picked from commit d04df664776b436f712051520d48f84be93ab269)
* Stop #defining FREEBSD_ELFJohn Baldwin2024-01-051-1/+1
| | | | | | | | | | | | | | This was originally used (along with FREEBSD_AOUT) to prefer the use of ELF in various tools instead of a.out as part of the a.out to ELF transition in the 3.x days. The last use of it was removed from <link.h> in commit 66422f5b7a1a6055f0b2358268eb902aab6e2e3e back in 2002, but various files still #define it. Reviewed by: kevans, imp, emaste Sponsored by: DARPA Differential Revision: https://reviews.freebsd.org/D42964 (cherry picked from commit 4a3cf5f329d69076aa9d093d596eb0ee82d917f5)
* rc.conf: correct $ntp_leapfile_sourcesPhilip Paeps2023-12-161-1/+1
| | | | | | | | IETF is no longer serving leap-seconds.list. Point at IANA instead. This fixes "service ntpd fetch". (cherry picked from commit b1c95af45488bef649e9a84890e2414ff80b3a00)
* rtld: add a test for RTLD_DEEPBINDKyle Evans2023-12-1510-2/+177
| | | | | | | | | | | | | | | This tests that with RTLD_DEEPBIND, symbols are looked up in all of the object's needed objects before the global object. ATF_REQUIRE_INTEQ was added after stable/13 branched, so we shim it out here. PR: 275393 Reviewed by: kib Sponsored by: NetApp, Inc. Sponsored by: Klara, Inc. (cherry picked from commit d9c543b6b0cabea6e6679d70b4e701018e7eab80)
* RTLD_DEEPBIND: make lookup not just symbolic, but walk all refobj' DAGsKonstantin Belousov2023-12-072-2/+7
| | | | | | PR: 275393 (cherry picked from commit 9daf6cd0f46416d9c6eb0411ea6042cd42b8a9bc)
* rc.conf(5): add <service>_umask to run the service using this valueEugene Grosbein2023-12-021-1/+9
| | | | | | | | | | | | None of tools working with login classes change umask(1) and we had no ways to specify non-default umask for a service not touching its startup script. This change makes in possible. Some file-sharing services that create new files may benefit from it. Differential: https://reviews.freebsd.org/D36309 (cherry picked from commit 160a2f2cdda806e104c0d3194bfb84b208ad1ae8)
* rc: add ${name}_setup script supportFranco Fichtner2023-12-021-3/+11
| | | | | | | Run a service-based setup script before running the start command. Useful for automatic configuration file generation. Reviewed by: https://reviews.freebsd.org/D36006
* ldconfig: filter out non-existing directories from default pathKonstantin Belousov2023-11-281-1/+5
| | | | (cherry picked from commit 806e4e3273bee2e3a12ffc2e74db5c912fbd7aa9)
* rc.d/ldconfig: Prepend rtld stdlib paths to ldconfig(32)_pathsJohn W. O'Brien2023-11-281-1/+4
| | | | | | PR: 275031 (cherry picked from commit 99132daf6f70cb0cc969c555d3612547fa3cf1db)
* Purge more stray embedded $FreeBSD$ stringsJohn Baldwin2023-10-2429-91/+0
| | | | | | | | | These do not use __FBSDID but instead use bare char arrays. Reviewed by: imp, emaste Differential Revision: https://reviews.freebsd.org/D41957 (cherry picked from commit eba230afba4932f02a1ca44efc797cf7499a5cb0)
* rc.subr: Fix a typoMateusz Piotrowski2023-10-041-1/+1
| | | | | | MFC after: 3 days (cherry picked from commit 7f6754d9659183a0c56fe76044d7826ca849675f)
* rc: Start testing the rc(8) framework (beginning with *_oomprotect)Mateusz Piotrowski2023-10-043-0/+109
| | | | | | | | | | | | | | | This change adds 2 tests to make sure that the *_oomprotect variable sets the protection against OOM killer properly within rc(8) scripts. This is also adding the first tests for the rc(8) framework. More tests will be added as we go. PR: 256148 Approved by: des MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D35745 (cherry picked from commit e7437ae907c89bf85a99c5cbb7ddd194a1ff1354)
* rc.d/hostid: remove useless catнаб2023-09-241-1/+1
| | | | | | | We've already read it and validated it ‒ re-reading is wasteful PR: 264376 (cherry picked from commit 11bd40d04af59daa7ae7feea0518081a35f07053)
* rc.subr: don't require service to be enabled for `status`Daniel Tameling2023-09-241-2/+3
| | | | | | | | | | | | | | | | For a service that sets an rcvar, there is a check whether it has been enabled before the actual command is executed. If the check fails, one gets a message to enable it and the returned exit status is 0. However, this is usually undesirable for the status command, which is a) supposed to check whether the service is running anyway and b) returns a non-zero exit code if that is not the case. Thus, skip the check for the status command. PR: 272282 Reviewed by: emaste (cherry picked from commit ba793728a840041e93e38bcbff4a7233dc63b722) (cherry picked from commit f701d9da1d94891dd2edad607a989cad6eb10313)
* rtld: output rtld errors into the dbg channelKonstantin Belousov2023-09-191-0/+1
| | | | (cherry picked from commit 72d97e1dd9cc72a2acb96e35e56db6f3f51bca7d)
* ftpd: add deprecation noticeEd Maste2023-09-141-1/+11
| | | | | | | | | | | Approved by: gordon Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D26447 (cherry picked from commit 98b98ec1bc7e961c3d3468b0e481080580c902cf) (cherry picked from commit cc9347cc79d320cac00ccf5d5f23971de2c887a1) (cherry picked from commit 01d82151022cb1383e83c331708a787f1907b00f) (cherry picked from commit 3ea83e94cdfa34745641dfa5f43debfdcd79e229)
* __crt_aligned_alloc_offset(): fix ov_index for backing allocation addressKonstantin Belousov2023-09-091-1/+1
| | | | (cherry picked from commit 03a7c36ddbc0ddb1063d2c8a37c64d83e1519c55)
* rc.d/routing: Correct setting default gateway for each FIBAndrew Fengler2023-08-301-3/+3
| | | | | | | | | | | | | There was a mistake in the previous commit, it used the incorrect spelling of the FIB variable name and was not functional Also corrects an issue with the IPv6 default route variable name. Fixes: 30659d1dcbcc ("Add support for adding default routes for other FIBs") Sponsored-by: ScaleEngine Inc. Differential Revision: https://reviews.freebsd.org/D37685 (cherry picked from commit f81be7a8318b178e406c12d98f78cfa2a4229af7)
* rtld: switch from malloc_aligned() to __crt_aligned_alloc()Konstantin Belousov2023-08-283-32/+15
| | | | (cherry picked from commit feaae6ba1ace0091384ac371423976cd15e59e5a)
* rtld_malloc: add __crt_aligned_alloc_offset()Konstantin Belousov2023-08-282-3/+32
| | | | (cherry picked from commit c29ee08204ce4106d4992474005c5f2fb7d5fbf1)
* rtld_malloc: increase overhead index to uint16Konstantin Belousov2023-08-281-2/+2
| | | | (cherry picked from commit d60130bf32a3c35417f276507dcdfa569397dae3)
* rtld_malloc.c: change return type of cp2op() to voidKonstantin Belousov2023-08-281-2/+2
| | | | (cherry picked from commit 6bb7f05850efceb01a7050e3c0fd86f9539c0071)
* rtld: unlock bind lock when calling into crt __pthread_distribute_static_tls ↵Konstantin Belousov2023-08-271-0/+2
| | | | | | method (cherry picked from commit b1d3e2b771552af071bf0964233cc5a76ea25542)
* Fix partially removed comment by removing the restWarner Losh2023-08-231-2/+0
| | | | | Fixes: 2a63c3be1582 (cherry picked from commit ddb5480ec67a44a28316724397fd6609354c4558)
* Remove $FreeBSD$: one-line bare tagWarner Losh2023-08-233-6/+0
| | | | | | | Remove /^\s*\$FreeBSD\$$\n/ Similar commit in main: (cherry picked from commit 05248206f720)
* Remove $FreeBSD$: one-line nroff patternWarner Losh2023-08-2312-12/+0
| | | | | | | Remove /^\.\\"\s*\$FreeBSD\$$\n/ Similar commit in main: (cherry picked from commit b2c76c41be32)
* Remove $FreeBSD$: two-line nroff patternWarner Losh2023-08-2316-32/+0
| | | | | | | Remove /^\.\\"\n\.\\"\s*\$FreeBSD\$$\n/ Similar commit in main: (cherry picked from commit fa9896e082a1)
* Remove $FreeBSD$: one-line sh patternWarner Losh2023-08-23314-315/+0
| | | | | | | Remove /^\s*#[#!]?\s*\$FreeBSD\$.*$\n/ Similar commit in main: (cherry picked from commit d0b2dbfa0ecf)
* Remove $FreeBSD$: one-line .c patternWarner Losh2023-08-2342-83/+0
| | | | | | | Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/ Similar commit in main: (cherry picked from commit 1d386b48a555)
* Remove $FreeBSD$: one-line .c comment patternWarner Losh2023-08-2314-14/+0
| | | | | | | Remove /^/[*/]\s*\$FreeBSD\$.*\n/ Similar commit in main: (cherry picked from commit 2a63c3be1582)
* Remove $FreeBSD$: one-line .h patternWarner Losh2023-08-2311-11/+0
| | | | | | | Remove /^\s*\*+\s*\$FreeBSD\$.*$\n/ Similar commit in main: (cherry picked from commit 42b388439bd3)
* Remove $FreeBSD$: two-line .h patternWarner Losh2023-08-2368-136/+0
| | | | | | | Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/ Similar commit in main: (cherry picked from commit b3e7694832e8)
* tftpd: fix wrong conflict resolutionEugene Grosbein2023-08-191-1/+1
| | | | | | This is direct commit to stable/13 after wrong previous one. Fixes: b71dde1aeba2972522a6742bbae77c2c6497eb01
* tftpd: introduce new option -SEugene Grosbein2023-08-192-7/+29
| | | | | | | | | | | | | | | | | Historically, tftpd disallowed write requests to existing files that are not publicly writable. Such requirement is questionable at least. Let us make it possible to run tftpd in chrooted environment keeping files non-world writable. New option -S enables write requests to existing files for chrooted run according to generic file permissions. It is ignored unless tftpd runs chrooted. Requested by: marck Differential: https://reviews.freebsd.org/D41090 (based on) (cherry picked from commit 273a307d0b80743fb08e23237b3f74dc94a8fa2a) (cherry picked from commit 03c2616dc530e5b23f06f9aa421012154590e578)
* atf_pytest_wrapper: fix use with pytest-7.4Kristof Provost2023-08-041-0/+2
| | | | | | | | | | | | | | | | As of pytest 7.4 it no longer walks all the way to the root directory of the file system to find conftest files. As a result we don't find / usr/tests/conftest.py, and don't load atf_python. That in turn causes atf_python tests to fail. Explicitly set the confcutdir, as advised by the pytest changelog. See also: https://github.com/pytest-dev/pytest/pull/11043 MFC after: 3 weeks Sponsored by: Orange Business Services Differential Revision: https://reviews.freebsd.org/D41064 (cherry picked from commit 9f23cbd6cae82fd77edfad7173432fa8dccd0a95)
* rtld_malloc: add cp2op() helperKonstantin Belousov2023-08-021-2/+8
| | | | (cherry picked from commit 86c7368f2bcefeb257f7dc40e4296261b295a674)
* rtld_malloc: only include internal rtld headers when building for rtldKonstantin Belousov2023-08-021-0/+2
| | | | (cherry picked from commit bc7e86106d428c7da328ad7fc9d4cb5f7f303e0e)
* rtld: remove dup __crt_malloc prototypesKonstantin Belousov2023-08-022-5/+1
| | | | (cherry picked from commit cf6dbdd135072fc2b74e0a10c22474b0282ca122)
* rtld_malloc: remove outdated commentsKonstantin Belousov2023-08-021-4/+0
| | | | (cherry picked from commit a24726a6f3b43473093267e2b4e81d186817dc7d)
* rtld: fix dlopen() for an object that is already mapped but not yet initializedKonstantin Belousov2023-07-301-5/+3
| | | | (cherry picked from commit 1005d3d05362de368b1ea7aeb8eb20cee993e122)
* spdx: The BSD-2-Clause-NetBSD identifier is obsolete, drop -NetBSDWarner Losh2023-07-253-3/+3
| | | | | | | | | | | The SPDX folks have obsoleted the BSD-2-Clause-NetBSD identifier. Catch up to that fact and revert to their recommended match of BSD-2-Clause. Discussed with: pfg MFC After: 3 days Sponsored by: Netflix (cherry picked from commit b61a573019428cbdc38ed03be9ecd2482011ea66)
* spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSDWarner Losh2023-07-2539-39/+39
| | | | | | | | | | | The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch up to that fact and revert to their recommended match of BSD-2-Clause. Discussed with: pfg MFC After: 3 days Sponsored by: Netflix (cherry picked from commit 4d846d260e2b9a3d4d0a701462568268cbfe7a5b)
* network.subr: adjust regex for wlans_xxxxx rc.conf entriesBjoern A. Zeeb2023-06-261-2/+2
| | | | | | | | | | | | Drivers like ath1[012]k will not match the current wlans_*-regex as they have digits followed by letters. Adjust the regex to allow this combination in order to be able to configure interfaces with names like wlans_ath11k0="..." Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D39674 (cherry picked from commit de1dde5dfea4407119955a6f94528396b258db3f)
* rc/WPA: driver_bsd.c: backout upstream IFF_ change and add loggingBjoern A. Zeeb2023-06-261-6/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts the state to our old supplicant logic setting or clearing IFF_UP if needed. In addition this adds logging for the cases in which we do (not) change the interface state. Depending on testing this seems to help bringing WiFi up or not log any needed changes (which would be the expected wpa_supplicant logic now). People should look out for ``(changed)`` log entries (at least if debugging the issue; this way we will at least have data points). There is a hypothesis still pondered that the entire IFF_UP toggling only exploits a race in net80211 (see further discssussions for more debugging and alternative solutions see D38508 and D38753). That may also explain why the changes to the rc startup script [1] only helped partially for some people to no longer see the continuous CTRL-EVENT-SCAN-FAILED. It is highly likely that we will want further changes and until we know for sure that people are seeing ''(changed)'' events this should stay local. Should we need to upstream this we'll likely need #ifdef __FreeBSD__ around this code. Remove ifconfig down/up workaround (bfb202c4554a) in rc.d/wpa_supplicant as it is no longer needed. [1] 5fcdc19a81115d975e238270754e28557a2fcfc5 and d06d7eb09131edea666bf049d6c0c55672726f76 Sponsored by: The FreeBSD Foundation Reviewed by: cy, enweiwu (earlier) Differential Revision: https://reviews.freebsd.org/D38807 (cherry picked from commit bfb202c4554a72383202a1a401d80721935b8c95) Reviewed by: bz (for wireless) Differential Revision: https://reviews.freebsd.org/D39257 (cherry picked from commit 052211e08c0e227277d0c4dc603bba2253eb3d73)
* motd: MFC: unbreak for source upgradeEugene Grosbein2023-06-261-4/+4
| | | | | | | | | | In case of source upgrade path from 12.x proper merge of new /etc installs /etc/motd.template. Becase of that, the system is left without symlink /etc/motd -> /var/run/motd but with stale /etc/motd contents. Fix it creating symlink despite of presence of /etc/motd.template. (cherry picked from commit 79a96e294c1acb4a2d17447a35f08647a6d09978)
* rtld: fix typo in commentKonstantin Belousov2023-06-111-1/+1
| | | | (cherry picked from commit a254f671025f3da313e1d02646b6402f54006e14)
* rtld: fix allocate_module_tls() variant I fallback to static allocationKonstantin Belousov2023-06-111-1/+1
| | | | (cherry picked from commit e9a38ed2fa61fd264a80f24ceb35f39b0ac6463d)
* rtld: do not allow both dynamic DTV index and static TLS offsetKonstantin Belousov2023-06-112-0/+15
| | | | (cherry picked from commit 91880e07f605edb90339685bc934699a4344de3b)