|
General software and network General OS-independent software and network questions, X11, MTA, routing, etc. |
|
Thread Tools | Display Modes |
|
||||
Wouldn't sudo(8) do this easily?
|
|
||||
Yup.
Code:
# sudo -u test ls BACKUP # grep test /etc/passwd test:*:2000:2000:test:/var/empty:/usr/sbin/nologin
__________________
religions, worst damnation of mankind "If 386BSD had been available when I started on Linux, Linux would probably never had happened." Linus Torvalds Linux is not UNIX! Face it! It is not an insult. It is fact: GNU is a recursive acronym for “GNU's Not UNIX”. vermaden's: links resources deviantart spreadbsd |
|
||||
I probably would have tried execl() or execv()
__________________
My Journal Thou shalt check the array bounds of all strings (indeed, all arrays), for surely where thou typest ``foo'' someone someday shall type ``supercalifragilisticexpialidocious''. |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
DHCP client allows shell command injection | J65nko | News | 0 | 7th April 2011 01:09 AM |
Running a command with input from a file. | bigb89 | Programming | 4 | 21st January 2009 06:36 PM |
Execute a command during login | rex | FreeBSD General | 4 | 12th September 2008 08:09 PM |
command launched by normal user... | maurobottone | OpenBSD General | 4 | 1st June 2008 03:45 AM |