twisted.plugins.cred_unix.UNIXChecker(object) class documentationtwisted.plugins.cred_unix
(View In Hierarchy)
Implements interfaces: twisted.cred.checkers.ICredentialsChecker
A credentials checker for a UNIX server. This will check that an authenticating username/password is a valid user on the system.
Does not work on Windows.
Right now this supports Python's pwd and spwd modules, if they are installed. It does not support PAM.
| Method | checkPwd | Obtain the encrypted password for usernamefrom the Unix 
password database usingpwd.getpwnam,
and see if it it matches it matchespassword. | 
| Method | checkSpwd | Obtain the encrypted password for usernamefrom the Unix 
shadow password database usingspwd.getspnam, and see if it it
matches it matchespassword. | 
| Method | requestAvatarId | Validate credentials and produce an avatar ID. | 
Obtain the encrypted password for username from the Unix 
password database using pwd.getpwnam,
and see if it it matches it matches password.
| Parameters | pwd | Module which provides functions which access to the Unix password database. (type: module) | 
| username | The user to look up in the Unix password database. (type: unicode/strorbytes) | |
| password | The password to compare. | 
Obtain the encrypted password for username from the Unix 
shadow password database using spwd.getspnam, and see if it it
matches it matches password.
| Parameters | spwd | Module which provides functions which access to the Unix shadow password database. | 
| username | The user to look up in the Unix password database. (type: unicode/strorbytes) | |
| password | The password to compare. | 
Validate credentials and produce an avatar ID.
| Parameters | credentials | something which implements one of the interfaces in credentialInterfaces. | 
| Returns | a Deferredwhich will fire with abytesthat identifies an avatar, an empty tuple to specify an authenticated 
anonymous user (provided astwisted.cred.checkers.ANONYMOUS)
or fail withUnauthorizedLogin.
Alternatively, return the result itself. | |
| See Also | twisted.cred.credentials | |