all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Jan Nieuwenhuizen <janneke@gnu.org>
To: Raghav Gururajan <raghavgururajan@disroot.org>
Cc: 40901@debbugs.gnu.org
Subject: [bug#40901] gnu: ktsuss: Fix paths.
Date: Mon, 27 Apr 2020 18:21:31 +0200	[thread overview]
Message-ID: <87k120527o.fsf@gnu.org> (raw)
In-Reply-To: <20200427093702.16f9d953.raghavgururajan@disroot.org> (Raghav Gururajan's message of "Mon, 27 Apr 2020 09:37:02 -0400")

Raghav Gururajan writes:

Hello Raghav,

> From ecdb9f73f2aa9854f03ace199fcc4c4547a2be49 Mon Sep 17 00:00:00 2001
> From: Raghav Gururajan <raghavgururajan@disroot.org>
> 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 <sudo>/bin/{su,sudo}
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=`which su 2>/dev/null`")
> +                "supath=/run/setuid-programs/su")
>                 (("sudopath=`which sudo 2>/dev/null`")
> -                (string-append "sudopath="
> -                               (string-append (assoc-ref inputs "sudo")
> -                                              "/bin/sudo"))))
> +                "sudopath=/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

-- 
Jan Nieuwenhuizen <janneke@gnu.org> | GNU LilyPond http://lilypond.org
Freelance IT http://JoyofSource.com | Avatar® http://AvatarAcademy.com

  reply	other threads:[~2020-04-27 16:22 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-27 13:37 [bug#40901] gnu: ktsuss: Fix paths Raghav Gururajan
2020-04-27 16:21 ` Jan Nieuwenhuizen [this message]
2020-04-28  7:43   ` Raghav Gururajan
2020-04-28 17:13     ` Jan Nieuwenhuizen
2020-04-30  8:39       ` Raghav Gururajan
2020-04-30 13:54         ` Raghav Gururajan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87k120527o.fsf@gnu.org \
    --to=janneke@gnu.org \
    --cc=40901@debbugs.gnu.org \
    --cc=raghavgururajan@disroot.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.