def requestAvatarId(self, credentials):
        try:
            from twisted.cred import pamauth
        except __HOLE__: # PyPAM is missing
            return defer.fail(error.UnauthorizedLogin())
        else:
            d = pamauth.pamAuthenticate(self.service, credentials.username,
                                        credentials.pamConversion)
            d.addCallback(lambda x: credentials.username)
            return d



# For backwards compatibility
# Allow access as the old name.
dataset/ETHPy150Open kuri65536/python-for-android/python-modules/twisted/twisted/cred/checkers.py/PluggableAuthenticationModulesChecker.requestAvatarId