diff options
author | Tomas Mraz <tm@t8m.info> | 2010-11-18 09:37:31 +0000 |
---|---|---|
committer | Tomas Mraz <tm@t8m.info> | 2010-11-18 09:37:31 +0000 |
commit | ff1e893b0e22e6848d78ae8094d1e10e3993ed7b (patch) | |
tree | d52f2451431dea9dd718d4975485512f85c80afb /modules | |
parent | 7aba472d5255f0e64a5ea42221c0d5f225f3b42d (diff) | |
download | pam-ff1e893b0e22e6848d78ae8094d1e10e3993ed7b.tar.gz pam-ff1e893b0e22e6848d78ae8094d1e10e3993ed7b.tar.bz2 pam-ff1e893b0e22e6848d78ae8094d1e10e3993ed7b.zip |
Relevant BUGIDs:
Purpose of commit: cleanup
Commit summary:
---------------
2010-11-18 Tomas Mraz <tm@t8m.info>
* modules/pam_limits/pam_limits.c (pam_parse,pam_sm_open_session):
Drop obsolete and broken option change_uid.
* modules/pam_limits/pam_limits.8.xml: Likewise.
Diffstat (limited to 'modules')
-rw-r--r-- | modules/pam_limits/pam_limits.8.xml | 16 | ||||
-rw-r--r-- | modules/pam_limits/pam_limits.c | 7 |
2 files changed, 0 insertions, 23 deletions
diff --git a/modules/pam_limits/pam_limits.8.xml b/modules/pam_limits/pam_limits.8.xml index 0be7ef4d..7b944f9e 100644 --- a/modules/pam_limits/pam_limits.8.xml +++ b/modules/pam_limits/pam_limits.8.xml @@ -23,9 +23,6 @@ <cmdsynopsis id="pam_limits-cmdsynopsis"> <command>pam_limits.so</command> <arg choice="opt"> - change_uid - </arg> - <arg choice="opt"> conf=<replaceable>/path/to/limits.conf</replaceable> </arg> <arg choice="opt"> @@ -72,19 +69,6 @@ <variablelist> <varlistentry> <term> - <option>change_uid</option> - </term> - <listitem> - <para> - Change real uid to the user for who the limits are set up. Use this - option if you have problems like login not forking a shell for user - who has no processes. Be warned that something else may break when - you do this. - </para> - </listitem> - </varlistentry> - <varlistentry> - <term> <option>conf=<replaceable>/path/to/limits.conf</replaceable></option> </term> <listitem> diff --git a/modules/pam_limits/pam_limits.c b/modules/pam_limits/pam_limits.c index f446f9e3..79cc717e 100644 --- a/modules/pam_limits/pam_limits.c +++ b/modules/pam_limits/pam_limits.c @@ -103,7 +103,6 @@ struct pam_limit_s { /* argument parsing */ #define PAM_DEBUG_ARG 0x0001 -#define PAM_DO_SETREUID 0x0002 #define PAM_UTMP_EARLY 0x0004 #define PAM_NO_AUDIT 0x0008 @@ -127,8 +126,6 @@ _pam_parse (const pam_handle_t *pamh, int argc, const char **argv, ctrl |= PAM_DEBUG_ARG; } else if (!strncmp(*argv,"conf=",5)) { pl->conf_file = *argv+5; - } else if (!strncmp(*argv,"change_uid",10)) { - ctrl |= PAM_DO_SETREUID; } else if (!strcmp(*argv,"utmp_early")) { ctrl |= PAM_UTMP_EARLY; } else if (!strcmp(*argv,"noaudit")) { @@ -777,10 +774,6 @@ out: return retval; } - if (ctrl & PAM_DO_SETREUID) { - setreuid(pwd->pw_uid, -1); - } - retval = setup_limits(pamh, pwd->pw_name, pwd->pw_uid, ctrl, pl); if (retval & LOGIN_ERR) pam_error(pamh, _("Too many logins for '%s'."), pwd->pw_name); |