Fernet 'expires' value loses 'ms' after validation
When we create a Fernet token we get a token with an expiration
time which contains microseconds. When we validate a Fernet token,
the expiration time changes and comes back missing the microseconds.
We need to make the expiration time the same between creation and
validation time, having microseconds in both cases. This applies to
both v2 and v3 API.
NOTE: This backport differs from the patch to master to handle the
difference in oslo.timeutils versus the move to keystone's own
implementation of isotime in master, and to move the fix in
keystone/token/providers/fernet/core.py to avoid having to backport a
significant refactor Fernet's implementation.
Closes-Bug: #1459790
Change-Id: Ic6adbc2d69af03519a2c4ef66d558bcff9022049
(cherry picked from commit 9391f9307e834f437c6712797c903921881f2977)
Reviewed: https:/ /review. openstack. org/212953 /git.openstack. org/cgit/ openstack/ keystone/ commit/ ?id=aa3354e73bd a53bbe8c354b644 ed37e8b100a7d8
Committed: https:/
Submitter: Jenkins
Branch: stable/kilo
commit aa3354e73bda53b be8c354b644ed37 e8b100a7d8
Author: Roxana Gherle <email address hidden>
Date: Thu Aug 6 09:46:58 2015 -0700
Fernet 'expires' value loses 'ms' after validation
When we create a Fernet token we get a token with an expiration
time which contains microseconds. When we validate a Fernet token,
the expiration time changes and comes back missing the microseconds.
We need to make the expiration time the same between creation and
validation time, having microseconds in both cases. This applies to
both v2 and v3 API.
Conflicts:
keystone/ tests/unit/ test_v3_ auth.py
keystone/ tests/unit/ token/test_ fernet_ provider. py
keystone/ token/providers /fernet/ core.py
keystone/ token/providers /fernet/ token_formatter s.py
NOTE: This backport differs from the patch to master to handle the token/providers /fernet/ core.py to avoid having to backport a
difference in oslo.timeutils versus the move to keystone's own
implementation of isotime in master, and to move the fix in
keystone/
significant refactor Fernet's implementation.
Closes-Bug: #1459790 519a2c4ef66d558 bcff9022049 37c6712797c9039 21881f2977)
Change-Id: Ic6adbc2d69af03
(cherry picked from commit 9391f9307e834f4