summaryrefslogtreecommitdiffstats
path: root/keystone-moon/keystone/contrib/revoke
diff options
context:
space:
mode:
authorasteroide <thomas.duval@orange.com>2015-09-24 16:27:16 +0200
committerasteroide <thomas.duval@orange.com>2015-09-24 16:27:16 +0200
commit92d11d139e9f76d4fd76859aea78643fc32ef36b (patch)
treebd5a2e7b50853498074ab55bdaee4452c460010b /keystone-moon/keystone/contrib/revoke
parent49325d99acfadaadfad99c596c4ada6b5ec849de (diff)
Update Keystone code from repository.
Change-Id: Ib3d0a06b10902fcc6d520f58e85aa617bc326d00
Diffstat (limited to 'keystone-moon/keystone/contrib/revoke')
-rw-r--r--keystone-moon/keystone/contrib/revoke/backends/kvs.py2
-rw-r--r--keystone-moon/keystone/contrib/revoke/backends/sql.py2
-rw-r--r--keystone-moon/keystone/contrib/revoke/core.py5
-rw-r--r--keystone-moon/keystone/contrib/revoke/model.py2
4 files changed, 7 insertions, 4 deletions
diff --git a/keystone-moon/keystone/contrib/revoke/backends/kvs.py b/keystone-moon/keystone/contrib/revoke/backends/kvs.py
index 349ed6e3..086becb0 100644
--- a/keystone-moon/keystone/contrib/revoke/backends/kvs.py
+++ b/keystone-moon/keystone/contrib/revoke/backends/kvs.py
@@ -27,7 +27,7 @@ _EVENT_KEY = 'os-revoke-events'
_KVS_BACKEND = 'openstack.kvs.Memory'
-class Revoke(revoke.Driver):
+class Revoke(revoke.RevokeDriverV8):
@versionutils.deprecated(
versionutils.deprecated.JUNO,
diff --git a/keystone-moon/keystone/contrib/revoke/backends/sql.py b/keystone-moon/keystone/contrib/revoke/backends/sql.py
index dd7fdd19..82e05194 100644
--- a/keystone-moon/keystone/contrib/revoke/backends/sql.py
+++ b/keystone-moon/keystone/contrib/revoke/backends/sql.py
@@ -38,7 +38,7 @@ class RevocationEvent(sql.ModelBase, sql.ModelDictMixin):
audit_chain_id = sql.Column(sql.String(32))
-class Revoke(revoke.Driver):
+class Revoke(revoke.RevokeDriverV8):
def _flush_batch_size(self, dialect):
batch_size = 0
if dialect == 'ibm_db_sa':
diff --git a/keystone-moon/keystone/contrib/revoke/core.py b/keystone-moon/keystone/contrib/revoke/core.py
index e1ab87c8..3b108c9e 100644
--- a/keystone-moon/keystone/contrib/revoke/core.py
+++ b/keystone-moon/keystone/contrib/revoke/core.py
@@ -232,7 +232,7 @@ class Manager(manager.Manager):
@six.add_metaclass(abc.ABCMeta)
-class Driver(object):
+class RevokeDriverV8(object):
"""Interface for recording and reporting revocation events."""
@abc.abstractmethod
@@ -257,3 +257,6 @@ class Driver(object):
"""
raise exception.NotImplemented() # pragma: no cover
+
+
+Driver = manager.create_legacy_driver(RevokeDriverV8)
diff --git a/keystone-moon/keystone/contrib/revoke/model.py b/keystone-moon/keystone/contrib/revoke/model.py
index 1a23d57d..e677bfb5 100644
--- a/keystone-moon/keystone/contrib/revoke/model.py
+++ b/keystone-moon/keystone/contrib/revoke/model.py
@@ -220,7 +220,7 @@ class RevokeTree(object):
# The last (leaf) level is checked in a special way because we
# verify issued_at field differently.
try:
- return revoke_map['issued_before'] > token_data['issued_at']
+ return revoke_map['issued_before'] >= token_data['issued_at']
except KeyError:
return False