DragonFly users List (threaded) for 2006-09
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]
Batch/At (does it work for you as a user?)
Feel silly asking this, but I've been trying to figure out what I goofed
up all night.
As a normal user, can you try this:
echo whoami | batch
See if it works for you?
I have an empty at.deny and.. just for good measure I added the name to at.allow
(then removed the file after that didn't work)
I get errors about accessing the lock files. at/batch are setuid, according
to mtree my permission settings are correct. (I think, I've never used mtree
before this)
In a last resort, I inserted some stuff into the source of priv.h:
#define PRIV_START {\
printf("\npriv_start .. \n"); \
printf("real_uid=%d, effective_uid=%d\n",real_uid,effective_uid); \
system("whoami"); \
setreuid(real_uid, effective_uid); \
setregid(real_gid, effective_gid); \
system("whoami"); \
printf(".. done with PRIV_START\n"); \
Seems to do the right thing until just at the point where it accessed the lock
file, but at the critical moment both in AND out report the regular user.
at.c:
PRIV_START
if ((lockdes = open(LFILE, O_WRONLY | O_CREAT, S_IWUSR | S_IRUSR)) < 0)
perr("cannot open lockfile " LFILE);
^^^^^^^^^^^^^^^^^^^^
whoami reports the regular user going in and out of PRIV_START, real_uid and
effective_uid are 500,0
Wondering if this is just my setup (if I botched something) or if it's actually
broken? I tried a cvsup just in case I did something, but that didn't seem to
help either.
(C isn't my primary language.. plz. forgive the crude approach to debugging)
Jamie
--
http://www.geniegate.com Custom web programming
guhzo_42@xxxxxxxxx (rot13) User Management Solutions
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]