PasswdUserContrib
Use getpwnam to get passwords from /etc/passwd
The module uses the standard
getpw*
functions to check passwords against
the
/etc/passwd
file. Thus any user who has an entry in
/etc/passwd
on your server is able to log in to the wiki. It is intended for use
with the
TemplateLogin
manager.
This module will only work with passwords that are stored in
/etc/passwd
. Most systems use shadow passwords, and the
getpwnam
call that this module uses to access the password
only checks for the password in the /etc/passwd
file.
You can get a good idea whether the module will work for you by running
a small fragment of perl
as the Apache user
perl -e 'for (1..10) { print join(" ",getpwent),"\n" }'
This will print the first 10 entries in
/etc/passwd
. If the second field
of each user entry is always 'x', then you probably can't access the passwords
this way.
Note that
/etc/passwd
is read-only, and you will not be able to add users,
change or reset passwords from Foswiki.
Installation Instructions
You do not need to install anything in the browser to use this extension. The following instructions are for the administrator who installs the extension on the server.
Open configure, and open the "Extensions" section. Use "Find More Extensions" to get a list of available extensions. Select "Install".
If you have any problems, or if the extension isn't available in
configure
, then you can still install manually from the command-line. See
http://foswiki.org/Support/ManuallyInstallingExtensions for more help.
- Use the
TemplateLogin
login manager
- {AllowLoginName} should be set to 1
Info
Many thanks to the following sponsors for supporting this work: