sudo - Execute a command with superuser privileges.

learn more… | top users | synonyms

4
votes
0answers
132 views

allow regular users to use network namespaces

I have an architecture using network namespaces (netns). I would like to allow regular users to do some operations in these netns. I could write a script netns-exec.sh, inspired by this post, ...
4
votes
0answers
555 views

How to enable `sudo` with custom functions?

Recently I learned you can enable sudo for custom aliases as follows: alias sudo='sudo ' # note: the space is required! The reason this works is the following: If the last character of the ...
3
votes
0answers
26 views

exists a “two-factor authentication” for sudo, if not how to make one anyway?

tl;dr normaly to gain root priviledges via sudo requires a special user account and the use of its passphrase as means to authetication. Due to keylogging/replay (in X.org session) attacks, I would ...
3
votes
0answers
670 views

How to disable sudo related logging for successful command execution under CentOS/Fedora?

You can disable sudo related log messages via adding something like Defaults:juser !syslog to our sudoers file. That is disabling logging to syslog. But under e.g. CentOS/Fedora there is an auditd ...
3
votes
0answers
3k views

How do I change file/directory permission of a nfs mounted directory, so I access files as user?

On a Ubuntu computer I mounted a directory from another computer using the following line in the fstab: 12.34.56.78:/space/Images /mnt/space/images nfs rsize=16384,wsize=16384,rw,auto,nolock 0 0 ...
3
votes
0answers
242 views

/proc/net/wireless does not show values unless run as root

cat /proc/net/wireless does not show statistics for wireless devices unless it is run as root, even though the permissions on the file are 444. The same seems to apply when accessing statistics via ...
3
votes
0answers
1k views

Security of xhost (local) and sudo xauthority forwarding

Context: launch a GUI application as a linux service. I considered making a headless daemon with a GUI front-end but there is too much code involved to do it now. This service must start on user ...
2
votes
0answers
136 views

Security of sudo not asking for a password after the first time

After using sudo and entering a password to do so, sudo remembers that we have entered a password and we do not have to enter a password the next time we use it. I am concerned about the possibility ...
2
votes
0answers
167 views

How to specify regular expression for command arguments in sudoers

sudoers(5) manpage says that shell-style wildcards (aka meta or glob characters) could be used in command line arguments in the sudoers file. They are *, ?, [...] and [!...]. My idea is to use some ...
2
votes
0answers
501 views

Reading from /etc/environment with sudo

Using Ubuntu 14.04 LTS, I'm having a problem trying to read environment variables from /etc/environment when using sudo env. Basically, they are not being displayed. When I do just env, these ...
2
votes
0answers
243 views

What is the correct way to abort an operation from the sudo password prompt?

Sometimes it amazes me the "little" things I don't know about Unix. For years now I have occasionally noted that I don't actually know how to deal with the sudo password prompt cleanly. Every once in ...
2
votes
0answers
86 views

Why does xdg-open text_file differ from sudo -u me xdg-open text_file?

If I run the following command, the text file opens in my preferred editor (kate). $ xdg-open text_file However, if I try the following, where sparhawk is my username, I get several warnings, and ...
2
votes
0answers
254 views

PHP exec and amixer

I'm trying to make php lower the dB level of amixer using exec, but it seems like php isn't able to perform the task which requires sudo-access. What should be the best way to solve this? I tried: ...
2
votes
0answers
2k views

How to run ssh -t user@remote 'sudo nohup bash -c “comand”' in background

I want to run a script on a remote host with sudo privilege, someone suggests that I should use nohup and ssh -t, like the following command: The script ls; sleep 10; echo finish is crafted here to ...
2
votes
0answers
826 views

Sudo yum permission denied Fedora 17

On Fedora 13, in /etc/sudoers I used to have a line: Cmnd_Alias SOFTWARE=/usr/bin/yum and then for a user that would have the privilege of installing his/her own RPM packages, an entry like: ...
2
votes
0answers
262 views

gksudo not caching credentials

I've built a shell script for mounting ISO images in Nautilus, and it worked fine in earlier versions of Ubuntu. One of the many problems encountered in 11.04 is that gksudo doesn't seem to cache the ...
1
vote
0answers
19 views

User can sudo although he is not in sudo group nor in /etc/sudoers

I have two colleagues on a Red Hat Enterprise Linux Server (release 6.4). Both of them can execute the sudo commands. Curiously, only one of the colleagues is in the /etc/sudoers file - let's call him ...
1
vote
0answers
30 views

Not permitted to add eth0 to bond0

I'm trying to add an interface to my bond0 but I always get the error. sudo ip link set dev eth0 master bond0 RTNETLINK answers: Operation not permitted I already tried it with sudo and with ...
1
vote
0answers
18 views

How do I escalate a signal?

For the past week, I been having a bug that my python code hasn't been doing a cleanup process properly. It was suppose to once it captures a signal caused by closing the terminal, it does some ...
1
vote
0answers
21 views

No drivers after usr ownership change Linux Mint

I have Linux Mint 14.2 installed on an IBM T60 ThinkPad. Everything was going just fine until I was installing some developer tool (I can't even remember which one anymore) and accidentally changed ...
1
vote
0answers
141 views

No candidate version found for sudo

When I try install sudo in Debian 8.2 aptitude install sudo I get error: No candidate version found for sudo. Source list is standart. Sorry for my bad english. Source list: deb ...
1
vote
0answers
258 views

Ubuntu 14.04.2 LTS: for NIS users, SSH works but console login and sudo fail

I set up a fresh Ubuntu 14.04 LTS VM on VirtualBox and did an upgrade, so now I'm sitting at 14.04.2. Our office environment is NIS+NFS. I set up autofs and NIS, and confirmed that I can log in as a ...
1
vote
0answers
57 views

Allowing sudo kill for remote user for recovery purpose. Security implications?

I'm planning to create user allowed to SSH in and with right to sudo kill in case something disables local terminal/keyboard/display etc. Would probably add ps and/or htop to the list, as well. I ...
1
vote
0answers
37 views

gksudo not honoring configuration in /etc/sudoers

Some time ago I posted a question which was related to whether it is possible to preserve environment variables when sudoing to a different user. As it turned out, this is indeed possible. When ...
1
vote
0answers
821 views

sudo and sssd not working with user groups

Having a problem getting sudo that is integrated with sssd to work correctly when we use ldap to store the groups that have the different sudo privs. This works just fine if we have sudo set to go to ...
1
vote
0answers
64 views

Is it safe to disable password for a user, if it only uses SSH key login?

We want to remove the password usage on a UNIX system. The users should only log in with SSH key. Not password. So their password field in the /etc/shadow file will be "*" and set their password to ...
1
vote
0answers
287 views

gksu -S ask for password only once even when set to three times in sudo configuration

I have a problem with gksu command. It always ask for password only once even when I set Defaults passwd_tries=3 in /etc/sudoers file. Command: $ gksu -S --debug ls No ask_pass set, using default! ...
1
vote
0answers
5k views

Trying to kill cron job processes found by “ps ax | grep keyword” logged in as pi user

I'm trying to kill several processes from the command line logged into the pi as the user pi. All of the processes have been started by cronjobs, so they should belong to the root user. I'm running ...
1
vote
0answers
111 views

Is there a QT4 equivalent of gksu, not dependent on KDE libraries?

Is there a QT4 application with the same functionality as sudo to gksu that does not require an entire KDE desktop to be installed?
1
vote
0answers
78 views

can't access account with empty password

I used the passwd command to remove the password for my account. Now, when I try to use su to log in to my account, it won't let me enter an empty password. So now, I can't access my account. Any ...
1
vote
0answers
161 views

External HDD read/write permission changing from a cron job

So, I run an overnight python script that runs a backup of our web data in the /var/www directory, then moves the backups to an external HDD in /media. The script in scheduled in the sudo crontab ...
1
vote
0answers
778 views

git deploy using sudo nopasswd

I'm trying to write simple post-recieve script, which would switch to webserver user and pull git repository. To do so, I added git user to sudoers (I've added this to very last line): git ALL = ...
1
vote
0answers
363 views

Bodhi Issue with Nautilus as SU

I am unsure how to run Nautilus with superuser privilieges on Bodhi, or if this is just a bad idea altogether. I am looking for a file manager that can browse my local network, and can be run as ...
1
vote
0answers
751 views

gkSudo Error no matter what I do

I don't know why, It wasn't happening yesterday. Was it because I turned the machine off and back on again this morning? Anyway here's the error. GkSudo won't run anything at all now. (gksudo:3262): ...
1
vote
0answers
867 views

Gnome update-notifier doesn't show updates when user not in sudo group (Debian Squeeze)

Gnome desktop notifications of new updates is not working on my system. I noticed that the notifications stopped working when I removed my desktop user from the sudo group (I prefer to have a separate ...
1
vote
0answers
643 views

Can't make a copy of /var/lib/mysql/ibdata1

I have a RedHat Linux server and I'm trying to make a copy of /var/lib/mysql/ibdata1, but I'm receiving an error saying permission denied and the file cannot be opened. I'm logged in as root user and ...
0
votes
0answers
10 views

Unable to use Nautilus

I've got Trisquel 7 GNU/Linux distro, with GNOME 3.8.4. I'm finding impossible to create a folder in Nautilus, or drag and drop files into the Desktop, out of other options. I find this quite ...
0
votes
0answers
4 views

Setting www-data (lighttpd) as sudoer not working

I have installed lighttpd with fast-cgi on the raspberry pi. When running a python script that requires root priveleges, I get the following error: RuntimeError: No access to /dev/mem. Try running ...
0
votes
0answers
14 views

How to configure Double Commander to ask for my password and use sudo when it needs it?

As a Total Commander lover I am trying to replace it with Double Commander as Midnight Commander doesn't feel enough to me (needless to say standard single-pane file managers don't). One of the ...
0
votes
0answers
13 views

Problem Running Transmission/Deluge

I have been using Transmission/Deluge(mostly Deluge) on my Raspberry Pi now for a few weeks. I am facing this issue. Every time i click on a magnet link on the web, Firefox brings up Transmission and ...
0
votes
0answers
31 views

Sudo, Virtualbox, and Permission issues. (The Good, The Bad, The Ugly)

I hope the title didn't put you off as this is a fairly interesting and nuanced problem. I'm testing a development image of Linux Mint built by myself and a friend. I'm testing it out by trying to do ...
0
votes
0answers
81 views

sudo and su hang indefinitely… stumped

I am trying to run su or sudo on my CentOS 6.6 machine. Every time I try to execute either command, I get prompted for a password. After entering the password, the command simply hangs. I can ctrl+c ...
0
votes
0answers
15 views

Restrictions made with sudo are applicable since login or only when sudo command is used?

I need to restrict users to run some commands, they already have ssh login, but i need that some users (defined in different groups) been able to run some commands. The easiest way is with sudo (and ...
0
votes
0answers
20 views

How to install framework on remoter server without root privileges

I'm trying to install caffe deep learning library on my university cluster grid running on Debian. The grid has some preinstalled modules, such as python, CUDA, compilers etc. The problem is, some of ...
0
votes
0answers
75 views

Escape special characters in password on remote machine

I'm trying to run sudo -i on the remote machine and send password in the same line. Faced with the problem of when the password contains special characters; escaping does not help. I would be glad ...
0
votes
0answers
41 views

Doesn't these program respect nsswitch?

I've set up LDAP and nsswitch on ubuntu and to some extent it seem to work. For example getent passwd lists accounts from both /etc/passwd and LDAP server. However for example id <user>, sudo ...
0
votes
0answers
39 views

Are there behavior changes for sudo-1.8.6p3-15.x86_64 (RHEL6.6) as compared to sudo-1.6.9p17-6?

We found that there is a behavioural changes in sudo-1.8.6p3-15.x86_64 (RHEL6.6) as compared to sudo-1.6.9p17-6 (RHEL 5.8). It has been observed if a script called through sudo, and if CtrlC (SIGINT) ...
0
votes
0answers
23 views

debian 7 sudo email notification

I edit sudoers by visudo: Defaults env_reset Defaults secure_path="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" Defaults mailto = "me@domain.com" Defaults ...
0
votes
0answers
52 views

Multiple here documents in a bash script to drop in and out of sudo is causing error “Sessions still open, not unmounting”

I'm attempting to write a setup script that I can run on multiple machines to run a bunch of installers (requires sudo) but also do things like pull down a git repo (I want to run that as the normal ...
0
votes
0answers
121 views

sudo: setreuid(ROOT_UID, user_uid): Operation not permitted

I get this in my debian wheezy. I do not know what to do. I get it with every sudo command. Su password fails every time. I have seen people suggesting running service ncsd stop and then start it but ...