<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def auth_token(cls, token):
 """ Callback method for OAuth 2.0 bearer token middleware """


        store = goldman.sess.store
        login = store.find(cls.RTYPE, 'token', token)

        if not login:
            msg = 'No login found with that token. It may have been revoked.'
            raise AuthRejected(**{'detail': msg})
        elif login.locked:
            msg = 'The login account is currently locked out.'
            raise AuthRejected(**{'detail': msg})
        else:
            login.post_authenticate()