Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email firstname.lastname@example.org
su and resources not honored
From: Jeremy C. Reed (reedreedmedia.net)
Date: Tue Jun 13 2006 - 21:50:59 CDT
* Don't touch resource/priority settings if -m has been used
* or -l and -c hasn't, and we're not su'ing to root.
if ((asme || (!asthem && class == NULL)) && pwd->pw_uid)
setwhat &= ~(LOGIN_SETPRIORITY|LOGIN_SETRESOURCES);
if (setusercontext(lc, pwd, pwd->pw_uid, setwhat) == -1)
So using "su" (without -m for example), a user (who knows another user
account's password) can login to that other user's account and because
LOGIN_SETRESOURCES is not used their previous resources are in effect. Is
This seems like a way a user can misuse resources. Comments?
If that is acceptable behaviour it should be clearly documented. (Any
suggestions on wording for the manual page?)
I haven't checked other operating systems yet.
Note that our login(1) does not have that problem.
Jeremy C. Reed