From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:470:142:3::10]:47186) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jT6WD-0005rD-QA for guix-patches@gnu.org; Mon, 27 Apr 2020 12:22:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.90_1) (envelope-from ) id 1jT6WB-0003It-VH for guix-patches@gnu.org; Mon, 27 Apr 2020 12:22:05 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:54664) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jT6WB-0003IZ-1M for guix-patches@gnu.org; Mon, 27 Apr 2020 12:22:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jT6WA-0007SG-Tu for guix-patches@gnu.org; Mon, 27 Apr 2020 12:22:02 -0400 Subject: [bug#40901] gnu: ktsuss: Fix paths. Resent-Message-ID: From: Jan Nieuwenhuizen References: <20200427093702.16f9d953.raghavgururajan@disroot.org> Date: Mon, 27 Apr 2020 18:21:31 +0200 In-Reply-To: <20200427093702.16f9d953.raghavgururajan@disroot.org> (Raghav Gururajan's message of "Mon, 27 Apr 2020 09:37:02 -0400") Message-ID: <87k120527o.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Raghav Gururajan Cc: 40901@debbugs.gnu.org Raghav Gururajan writes: Hello Raghav, > From ecdb9f73f2aa9854f03ace199fcc4c4547a2be49 Mon Sep 17 00:00:00 2001 > From: Raghav Gururajan > Date: Mon, 27 Apr 2020 09:32:43 -0400 > Subject: [PATCH] gnu: ktsuss: Fix paths. > > * gnu/packages/admin.scm (ktsuss): Fix paths. I changed the commit message to --8<---------------cut here---------------start------------->8--- gnu: ktsuss: Use setuid "su" and "sudo" commands. This has ktsudo actually gain root access. * gnu/packages/admin.scm (ktsuss)[arguments]: Instead of /bin/{su,sud= o} file names, use the setuid' verrsions. --8<---------------cut here---------------end--------------->8--- When there is a fix being made, a short explanation is nice to have. What was wrong that the file name were changed, what was fixed? Also, we are (mainly) fixing the file names of SU and SUDO, not PATHs. > - (add-after 'unpack 'patch-sudo-path > - (lambda* (#:key inputs #:allow-other-keys) > + (add-after 'unpack 'patch-paths Renamed to 'patch-file-names' > + (lambda* (#:key inputs outputs #:allow-other-keys) Parameters inputs and outputs are both not used; I changed this to + (lambda _ > + (substitute* "src/ktsuss.c" > + (("/usr/sbin:/usr/local/sbin:/sbin") > + "~/.guix-profile/sbin")) No way! :-) I removed/did not apply this change. > (substitute* "configure.ac" > + (("supath=3D`which su 2>/dev/null`") > + "supath=3D/run/setuid-programs/su") > (("sudopath=3D`which sudo 2>/dev/null`") > - (string-append "sudopath=3D" > - (string-append (assoc-ref inputs "sudo") > - "/bin/sudo")))) > + "sudopath=3D/run/setuid-programs/sudo")) LGTM! Can you please remember to test a program before submitting it? And I mean not only check if "it runs", but also if it is actually useful? Pushed to master with these changes. Greetings, janneke --=20 Jan Nieuwenhuizen | GNU LilyPond http://lilypond.org Freelance IT http://JoyofSource.com | Avatar=C2=AE http://AvatarAcademy.com