
Example 27.1
PAM Configuration for sshd
#%PAM-1.0
auth include common-auth
auth required pam_nologin.so
account include common-account
password include common-password
session include common-session
# Enable the following line to get resmgr support for
# ssh sessions (see /usr/share/doc/packages/resmgr/README.SuSE)
#session optional pam_resmgr.so fake_ttyname
The typical PAM configuration of an application (sshd, in this case) contains four include
statements referring to the configuration files of four module types:
common-auth
,
common-account
,
common-password
, and
common-session
. These four
files hold the default configuration for each module type. By including them instead of
calling each module separately for each PAM application, automatically get an updated
PAM configuration if the administrator changes the defaults. In former times, you had
to adjust all configuration files manually for all applications when changes to PAM
occurred or a new application was installed. Now the PAM configuration is made with
central configuration files and all changes are automatically inherited by the PAM
configuration of each service.
The first include file (
common-auth
) calls two modules of the
auth
type:
pam_env
and
pam_unix2
. See
Example 27.2, “Default Configuration for the
auth
Section”
(page 498).
Example 27.2
Default Configuration for the auth Section
auth required pam_env.so
auth required pam_unix2.so
The first one,
pam_env
, loads the file
/etc/security/pam_env.conf
to set
the environment variables as specified in this file. This can be used to set the
DISPLAY
variable to the correct value, because the
pam_env
module knows about the location
from which the login is taking place. The second one,
pam_unix2
, checks the user's
login and password against
/etc/passwd
and
/etc/shadow
.
After the modules specified in
common-auth
have been successfully called, a third
module called
pam_nologin
checks whether the file
/etc/nologin
exists. If it
does, no user other than
root
may log in. The whole stack of
auth
modules is pro-
cessed before sshd gets any feedback about whether the login has succeeded. Given
498
Installation and Administration
Summary of Contents for LINUX ENTERPRISE SERVER 10 - INSTALLATION AND ADMINISTRATION 11-05-2007
Page 1: ...SUSE Linux Enterprise Server www novell com 10 May 11 2007 Installation and Administration...
Page 14: ......
Page 19: ...Part I Deployment...
Page 20: ......
Page 60: ......
Page 128: ......
Page 243: ...Part II Administration...
Page 244: ......
Page 274: ......
Page 312: ......
Page 348: ......
Page 380: ......
Page 381: ...Part III System...
Page 382: ......
Page 438: ......
Page 452: ......
Page 478: ......
Page 486: ......
Page 498: ......
Page 512: ......
Page 558: ......
Page 559: ...Part IV Services...
Page 560: ......
Page 652: ......
Page 670: ......
Page 742: ......
Page 754: ......
Page 796: ......
Page 817: ...Part V Security...
Page 818: ......
Page 858: ......
Page 886: ......
Page 910: ......
Page 911: ...Part VI Troubleshooting...
Page 912: ......
Page 924: ......