keystone.models.revoke_model.
is_revoked
(events, token_data)[source]¶Check if a token matches a revocation event.
Compare a token against every revocation event. If the token matches an event in the events list, the token is revoked. If the token is compared against every item in the list without a match, it is not considered revoked from the revoke_api.
Parameters: |
|
---|---|
Returns: | True if the token matches an existing revocation event, meaning the token is revoked. False is returned if the token does not match any revocation events, meaning the token is considered valid by the revocation API. |
keystone.models.revoke_model.
matches
(event, token_values)[source]¶See if the token matches the revocation event.
A brute force approach to checking. Compare each attribute from the event with the corresponding value from the token. If the event does not have a value for the attribute, a match is still possible. If the event has a value for the attribute, and it does not match the token, no match is possible, so skip the remaining checks.
Parameters: |
|
---|---|
Returns: | True if the token matches the revocation event, indicating the token has been revoked |
Unified in-memory token model.
keystone.models.token_model.
KeystoneToken
(token_id, token_data)[source]¶Bases: dict
An in-memory representation that unifies v2 and v3 tokens.
audit_chain_id
¶audit_id
¶auth_token
¶bind
¶domain_id
¶domain_name
¶domain_scoped
¶expires
¶federation_group_ids
¶federation_idp_id
¶federation_protocol_id
¶is_admin_project
¶is_domain
¶is_federated_user
¶issued
¶metadata
¶methods
¶oauth_access_token_id
¶oauth_consumer_id
¶oauth_scoped
¶project_domain_id
¶project_domain_name
¶project_id
¶project_name
¶project_scoped
¶role_ids
¶role_names
¶scoped
¶trust_id
¶trust_impersonation
¶trust_scoped
¶trustee_user_id
¶trustor_user_id
¶user_domain_id
¶user_domain_name
¶user_id
¶user_name
¶user_password_expires_at
¶Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.