From 73e6c409b4569e115292d27f108a0d318114fb12 Mon Sep 17 00:00:00 2001 From: Patrick Uiterwijk Date: Jun 02 2017 07:25:04 +0000 Subject: Correctly process missing refreshable_until token info If refreshable_until=None, it ends up not getting stored in the token information table. This will make sure we will correctly interpret that as "no expiry". Fixes: #264 Signed-off-by: Patrick Uiterwijk --- diff --git a/ipsilon/providers/openidc/store.py b/ipsilon/providers/openidc/store.py index 671cbfa..9879fdc 100644 --- a/ipsilon/providers/openidc/store.py +++ b/ipsilon/providers/openidc/store.py @@ -206,7 +206,7 @@ class OpenIDCStore(Store): if not token['refreshable']: return None - if token['refreshable_until'] and \ + if token.get('refreshable_until') and \ token['refreshable_until'] >= int(time.time()): return None