key server: 403 on expired approved keys (#1410)

This commit is contained in:
Jimmy Zelinskie 2016-04-27 14:48:12 -04:00 committed by Jimmy Zelinskie
parent 4f63a50a17
commit 726cb5fe6a

View file

@ -88,6 +88,9 @@ def get_service_key(service, kid):
if key.approval is None:
abort(409)
if key.expiration_date <= datetime.utcnow():
abort(403)
resp = jsonify(key.jwk)
lifetime = timedelta(days=365)