Live data from Hacker News

Run0, a systemd based alternative to sudo, announced

mastodon.social

591–600 of 902 posts

Re: Run0, a systemd based alternative to sudo, announced

#591
post #365

Earlier quoted context omitted.

It violates the principle of Least Surprise; if I'm invoking run0 I'm expecting it to run my program with a different UID and return the same stdout I'd have gotten if I had just run the program in my shell. Not inject a whole bunch of color control bytes in there. Which hopefully my terminal will handle. Unless it doesn't. I'll give them the benefit of the doubt and assume they only do this if $TERM supports color.…

But sudo already doesn’t do that either. Eg sudo may ask for a password, and output some control sequences which hide the text so your password is not visible. This feels like much ado about nothing. Edit: Also don’t forget the “with great power comes great responsibility” blurb that sudo likes to output. I know that doesn’t happen in scripts when output is redirected, but I’m sure run0 will figure that out too.

> sudo may ask for a password, and output some control sequences which hide the text so your password is not visible.

You can turn this off for certain users and/or programs.

Re: Run0, a systemd based alternative to sudo, announced

#592
post #585

First of all, I like the idea. But I have questions. What does logging look like for this? I don't think it would be too difficult to log commands run with polkit, but is there an equivalent of sudo I/O logs? My guess is there isn't now, but to fully replace sudo it will probably need a way to record everything on the ptty it creates. What environment variables does it forward by default? From the man page it sounds…

From the post:

> well, admittedly, we do propagate $TERM, but that's an explicit exception, i.e. allowlist rather than denylist

Re: Run0, a systemd based alternative to sudo, announced

#593
post #581

Earlier quoted context omitted.

I suppose my brutally minimalist Sway config with barely there titlebars and a skinny little status bar and not an icon, button, or widget in sight doesn't give me great standing to call for a respect of conventions. I suppose I should say I found Gnomes luridly chunky decorations and widgets to be personally offensive.

What widgets? Gnome has just the one black bar at the top.

And it's a thick monster with all kinds of extra crap (I'm my not so humble opinion) shoved in it.

Re: Run0, a systemd based alternative to sudo, announced

#594
Can someone explain what this is / how it works to someone who has done a considerable amount of programming but lacks this kind of operating system level knowledge?

I was under the impression that ‘sudo’ was baked into the entire system. Like ‘cd’ or ‘ps’. How exactly can you just swap out sudo? Does that involve swapping out chmod as well?

Re: Run0, a systemd based alternative to sudo, announced

#595
post #233

Earlier quoted context omitted.

You can use almost any GNU project without depending on all the other GNU projects.

This is different from Systemd how? You can't use any GNU project without depending on GNU libc (except glibc itself, trivially).

That is not true. I use gnu tools compiled with musl libc.

Re: Run0, a systemd based alternative to sudo, announced

#597

Can someone explain what this is / how it works to someone who has done a considerable amount of programming but lacks this kind of operating system level knowledge? I was under the impression that ‘sudo’ was baked into the entire system. Like ‘cd’ or ‘ps’. How exactly can you just swap out sudo? Does that involve swapping out chmod as well?

sudo, and even cd and ps you mention are simply binaries that come shipped with your distro / OS.

They, like explorer.exe on Windows, are an essential part of that OS with special privileges and roles but they are not part of the kernel, they are still simply programs. It is not developed by the people who develop the Linux kernel.

There are other Sudo alternatives such as DoAs already.

Re: Run0, a systemd based alternative to sudo, announced

#598

Can someone explain what this is / how it works to someone who has done a considerable amount of programming but lacks this kind of operating system level knowledge? I was under the impression that ‘sudo’ was baked into the entire system. Like ‘cd’ or ‘ps’. How exactly can you just swap out sudo? Does that involve swapping out chmod as well?

Pretty sure `sudo` is an application that you can remove, it just comes pre-installed in many distros.

Re: Run0, a systemd based alternative to sudo, announced

#599

Earlier quoted context omitted.

I've never understood the need for sudo(1) on single-user, physical machines: I keep a root shell (su(1)) around for admin tasks, and it's always been sufficient.

One password is easier than two and it feels weird to use the same password for both accounts. About half of my sudo invocations are 'sudo su' lmao.

> it feels weird to use the same password for both accounts

I'm not sure different passwords adds more protection for single-user machines, especially when sudo(1) can spawn root shells!

Re: Run0, a systemd based alternative to sudo, announced

#600

Can someone explain what this is / how it works to someone who has done a considerable amount of programming but lacks this kind of operating system level knowledge? I was under the impression that ‘sudo’ was baked into the entire system. Like ‘cd’ or ‘ps’. How exactly can you just swap out sudo? Does that involve swapping out chmod as well?

sudo is just another program, it's not "baked in" as such. It just ships with many (not all) distros. I remember having to install it from repos in the past on a new system: https://github.com/sudo-project/sudo
Post reply on HN