Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 1 | SUMMARY = "Provide limited super user privileges to specific users" |
| 2 | DESCRIPTION = "Sudo (superuser do) allows a system administrator to give certain users (or groups of users) the ability to run some (or all) commands as root while logging all commands and arguments." |
| 3 | HOMEPAGE = "http://www.sudo.ws" |
| 4 | BUGTRACKER = "http://www.sudo.ws/bugs/" |
| 5 | SECTION = "admin" |
Andrew Geissler | d159c7f | 2021-09-02 21:05:58 -0500 | [diff] [blame] | 6 | LICENSE = "ISC & BSD-3-Clause & BSD-2-Clause & Zlib" |
Andrew Geissler | fc113ea | 2023-03-31 09:59:46 -0500 | [diff] [blame] | 7 | LIC_FILES_CHKSUM = "file://LICENSE.md;md5=5100e20d35f9015f9eef6bdb27ba194f \ |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 8 | file://plugins/sudoers/redblack.c;beginline=1;endline=46;md5=03e35317699ba00b496251e0dfe9f109 \ |
| 9 | file://lib/util/reallocarray.c;beginline=3;endline=15;md5=397dd45c7683e90b9f8bf24638cf03bf \ |
| 10 | file://lib/util/fnmatch.c;beginline=3;endline=27;md5=004d7d2866ba1f5b41174906849d2e0f \ |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 11 | file://lib/util/glob.c;beginline=2;endline=31;md5=2852f68687544e3eb8a0a61665506f0e \ |
| 12 | file://lib/util/snprintf.c;beginline=3;endline=33;md5=b70df6179969e38fcf68da91b53b8029 \ |
| 13 | file://include/sudo_queue.h;beginline=2;endline=27;md5=ad578e9664d17a010b63e4bc0576ee8d \ |
| 14 | file://lib/util/inet_pton.c;beginline=3;endline=17;md5=27785c9f5835093eda42aa0816a2d0b4 \ |
| 15 | file://lib/util/arc4random.c;beginline=3;endline=20;md5=ced8636ecefa2ba907cfe390bc3bd964 \ |
| 16 | file://lib/util/arc4random_uniform.c;beginline=3;endline=17;md5=e30c2b777cdc00cfcaf7c445a10b262f \ |
| 17 | file://lib/util/getentropy.c;beginline=1;endline=19;md5=a0f58be3d60b6dcd898ec5fe0866d36f \ |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 18 | " |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 19 | |
| 20 | inherit autotools |
| 21 | |
| 22 | PACKAGECONFIG ??= "" |
| 23 | PACKAGECONFIG[zlib] = "--enable-zlib,--disable-zlib,zlib" |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 24 | PACKAGECONFIG[pam-wheel] = ",,,pam-plugin-wheel" |
Andrew Geissler | 517393d | 2023-01-13 08:55:19 -0600 | [diff] [blame] | 25 | PACKAGECONFIG[audit] = "--with-linux-audit,--without-linux-audit,audit" |
| 26 | PACKAGECONFIG[selinux] = "--with-selinux,--without-selinux,libselinux" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 27 | |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 28 | EXTRA_OECONF = "--with-editor=${base_bindir}/vi --with-env-editor" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 29 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 30 | EXTRA_OECONF:append:libc-musl = " --disable-hardening " |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 31 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 32 | do_compile:prepend () { |
Patrick Williams | 2a25492 | 2023-08-11 09:48:11 -0500 | [diff] [blame] | 33 | # Remove build host references from config.h |
Andrew Geissler | eff2747 | 2021-10-29 15:35:00 -0500 | [diff] [blame] | 34 | sed -i \ |
| 35 | -e 's,--with-libtool-sysroot=${STAGING_DIR_TARGET},,g' \ |
| 36 | -e 's,--build=${BUILD_SYS},,g' \ |
| 37 | -e 's,--host=${HOST_SYS},,g' \ |
Patrick Williams | 2a25492 | 2023-08-11 09:48:11 -0500 | [diff] [blame] | 38 | ${B}/config.h |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 39 | } |
| 40 | |
| 41 | # Explicitly create ${localstatedir}/lib before do_install to ensure |
| 42 | # the directory is accessible by all users. Otherwise the mkinstalldirs |
| 43 | # script (from sudo) will recursively create ${localstatedir}/lib/sudo |
| 44 | # and then chmod each directory with 0700 permissions, which isn't what |
| 45 | # we want (i.e, users would not be able to access /var/lib). |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 46 | do_install:prepend (){ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 47 | mkdir -p ${D}/${localstatedir}/lib |
| 48 | } |
Andrew Geissler | 95ac1b8 | 2021-03-31 14:34:31 -0500 | [diff] [blame] | 49 | |
| 50 | CVE_VERSION_SUFFIX = "patch" |