password created_at does not honor timezones
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Identity (keystone) |
Fix Released
|
High
|
Ron De Rose | ||
Newton |
Fix Released
|
High
|
Ron De Rose |
Bug Description
This was initially discovered when running the unit tests for migration 002 in a timezone that is UTC+3.
Migration 002 sets the password created_at column to a TIMESTAMP type
with a server_
that have been uncovered with this change:
* We cannot guarantee that func.now() will generate a UTC timestamp.
* For some older versions of MySQL, the TIMESTAMP column will
automatically be updated when other columns are updated:
https:/
Steps to reproduce:
1. dpkg-reconfigure tzdata and select there Europe/Moscow (UTC+3).
2. Restart mysql
3. Configure opportunistic tests with the following command in mysql:
GRANT ALL PRIVILEGES ON *.* TO 'openstack_citest' @'%' identified by 'openstack_citest' WITH GRANT OPTION;
4. Run keystone.
Expected result: test pass
Actual result:
Traceback (most recent call last):
File "keystone/
File "keystone/
raise AssertionError(
AssertionError: Invalid user / password
Aside from the test issue, we should be saving all time related data in DateTime format instead of TIMESTAMP.
description: | updated |
Changed in keystone: | |
assignee: | nobody → Ron De Rose (ronald-de-rose) |
Changed in keystone: | |
status: | New → In Progress |
Changed in keystone: | |
assignee: | Boris Bobrov (bbobrov) → Ron De Rose (ronald-de-rose) |
tags: | added: rc-potential |
Changed in keystone: | |
importance: | Undecided → High |
description: | updated |
Changed in keystone: | |
milestone: | none → ocata-1 |
Fix proposed to branch: master /review. openstack. org/367374
Review: https:/