Crates.io | yas |
lib.rs | yas |
version | 1.0.0 |
source | src |
created_at | 2020-09-27 20:00:21.943661 |
updated_at | 2020-10-04 17:23:26.359862 |
description | A sudo replacement, written in rust |
homepage | https://github.com/alx365/yas |
repository | https://github.com/alx365/yas |
max_upload_size | |
id | 293512 |
size | 70,070 |
yas - a (kind of) sudo replacement (entire readme is still work in progress)
yas, or ’yet another sudo’, is kind of a sudo replacement, written in rust and without really any configuration options or not needed features. It is intended for single user systems only, as it works out of the box, with no configuration needed, but you also can’t restrict a user from running stuff as root. yas also can’t run commands as any other user, but root. In case you really do have a user, that shouldn’t be allowed to run stuff as root, this isn’t for you.
There is a AUR package for the git version of yas, you can install it with a AUR helper, or just git clone it manually:
git clone ssh://aur@aur.archlinux.org/yas-git.git
cd yas-git
makepkg -is
or:
yay -S yas-git
Get it from crates.io with rusts cargo, by running:
cargo install yas
NOTE: The suid bit will not be set, you will manually have to set it for yas to work:
su -c "chown root ~/.cargo/bin/yas && chmod u+s ~/.cargo/bin/yas"
Download a binary
Change the owner to root
chmod root yas
Set the suid bit
chmod u+s yas
Put it somewhere in your path, such as /usr/bin
yas - execute commands as the root user
usage: yas [-h/--help] [-v/--version ]<command> <arguments for the command, this can be chained infinite>
As one can see, there aren’t really any options for yas.
99% of the people who use sudo (or opendoas), just use it with default configuration and the default options.
Who would also need a flag, to edit a file, if nobody ever uses that, and instead just runs `sudo
you could have a car that is very safe by just limiting its max speed to 20 miles an hour but I don’t want to do that I want to have something that’s more like a Lamborghini so maybe I’ll throw in some airbags and it’s gonna be mostly up to the driver to protect themselves and drive it safely
Mental Outlaw on youtube
yas will ask for the password whenever you want to run a command privileged, unless you ran a command with yas in the last 5 minutes. Not however, that this is cross terminal, but i am planning on fixing that.
yas doesn’t ship with so many security features, as sudo, so if you want the most secure root commmand executor, you should also use sudo.