I have tried to set-up a user to run a command as another user
(which is a role). The current config is:
/etc/user_attr:
jjohn::::type=normal;profiles=UncaExec
unca::::type=role;profiles=All
/etc/security/prof_attr:
UncaExec:::UncaExec
/etc/security/exec_attr
UncaExec:suser:cmd:::/tmp/fred:uid=603;gid=207
# cat /tmp/fred
/usr/bin/id
# ls -ld /tmp/fred
-r-xr-x--- 1 unca unca 12 Jun 30 08:54 /tmp/fred
$ id
uid=319(jjohn) gid=14(sysadmin)
$ /tmp/fred
pfexec: Exec format error
Does anyone know what this error message really means. I can find not
useful reference to this on the usual seach engines. I don't think
the syntax is incorrect because I simply copied the lines from a known
working configuration.
It usually means that the file is not the right format for the system
you're on. What does 'file /tmp/fred' tell you? Are you trying to run
a Linux binary on Solaris? Or a SPARC executable on x86, or vise-versa?
--
Brandon Hume - hume -> BOFH.Ca, http://WWW.BOFH.Ca/
As I wrote:
# cat /tmp/fred
/usr/bin/id
# file /tmp/fred
/tmp/fred: commands text
# file /usr/bin/id
/usr/bin/id: ELF 32-bit MSB executable SPARC Version 1, dynamically
linked, stripped
# uname -a
SunOS kubera 5.9 Generic_118558-33 sun4u sparc SUNW,Sun-Fire-15000
If /usr/bin/id is broken, which it is not, then this would not be the
only problem I would be having today.
On Jun 30, 4:17 pm, hume.spamfil...@bofh.ca wrote:
"commands text"? As opposed to "executable shell script"?
Did you forget your "#!/bin/sh" at the top?
You star. This solved it.