"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "keystone/revoke/backends/base.py" between
keystone-16.0.1.tar.gz and keystone-17.0.0.tar.gz

About: OpenStack Keystone (Core Service: Identity) provides an authentication and authorization service for other OpenStack services. Provides a catalog of endpoints for all OpenStack services.
The "Ussuri" series (latest release).

base.py  (keystone-16.0.1):base.py  (keystone-17.0.0)
skipping to change at line 19 skipping to change at line 19
# Unless required by applicable law or agreed to in writing, software # Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations # License for the specific language governing permissions and limitations
# under the License. # under the License.
import abc import abc
import datetime import datetime
from oslo_utils import timeutils from oslo_utils import timeutils
import six
import keystone.conf import keystone.conf
from keystone import exception from keystone import exception
CONF = keystone.conf.CONF CONF = keystone.conf.CONF
def revoked_before_cutoff_time(): def revoked_before_cutoff_time():
expire_delta = datetime.timedelta( expire_delta = datetime.timedelta(
seconds=CONF.token.expiration + CONF.revoke.expiration_buffer) seconds=CONF.token.expiration + CONF.revoke.expiration_buffer)
oldest = timeutils.utcnow() - expire_delta oldest = timeutils.utcnow() - expire_delta
return oldest return oldest
@six.add_metaclass(abc.ABCMeta) class RevokeDriverBase(object, metaclass=abc.ABCMeta):
class RevokeDriverBase(object):
"""Interface for recording and reporting revocation events.""" """Interface for recording and reporting revocation events."""
@abc.abstractmethod @abc.abstractmethod
def list_events(self, last_fetch=None, token=None): def list_events(self, last_fetch=None, token=None):
"""return the revocation events, as a list of objects. """return the revocation events, as a list of objects.
:param last_fetch: Time of last fetch. Return all events newer. :param last_fetch: Time of last fetch. Return all events newer.
:param token: dictionary of values from a token, normalized for :param token: dictionary of values from a token, normalized for
differences between v2 and v3. The checked values are a differences between v2 and v3. The checked values are a
subset of the attributes of model.TokenEvent subset of the attributes of model.TokenEvent
 End of changes. 2 change blocks. 
3 lines changed or deleted 1 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)