[ Team LiB ] |
Recipe 5.12 Authorizing Password Changes via sudo5.12.1 ProblemYou want to permit a user to change the passwords of certain other users. 5.12.2 SolutionTo permit smith to change the passwords of jones, chu, and agarwal: /etc/sudoers: smith ALL = NOPASSWD: \ /usr/bin/passwd jones, \ /usr/bin/passwd chu, \ /usr/bin/passwd agarwal The NOPASSWD tag is optional, for convenience. [Recipe 5.4] 5.12.3 DiscussionAs another example, permit a professor to change passwords for her students, whose logins are student00, student01, student02,...up to student99. /etc/sudoers: prof ALL = NOPASSWD: /usr/bin/passwd student[0-9][0-9] Note that this uses shell-style wildcard expansion; see sudoers(5) for the full syntax. 5.12.4 See Alsosudo(8), sudoers(5). |
[ Team LiB ] |