Token::isValid() returns true on invalid tokens
Bug #1572943 reported by
Alberto Mardegan
This bug affects 2 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Canonical System Image |
Fix Released
|
Medium
|
David Barth | ||
webapps-sprint |
Fix Released
|
Undecided
|
Alberto Mardegan | ||
ubuntuone-credentials (Ubuntu) |
Fix Released
|
Medium
|
Alberto Mardegan |
Bug Description
Token token(QString(), QString(), QString(), QString());
token.isValid(); // prints true
This is something which can obviously being worked around in the client code, but I think it would be nicer if Token would consider empty strings as missing data.
Related branches
lp://staging/~mardy/ubuntuone-credentials/token-valid-1572943
- dobey (community): Approve
- PS Jenkins bot: Approve (continuous-integration)
-
Diff: 69 lines (+22/-10)3 files modifiedlibubuntuoneauth/tests/test_token.cpp (+7/-0)
libubuntuoneauth/tests/test_token.h (+1/-0)
libubuntuoneauth/token.cpp (+14/-10)
Changed in ubuntuone-credentials (Ubuntu): | |
status: | New → In Progress |
assignee: | nobody → Alberto Mardegan (mardy) |
importance: | Undecided → Medium |
Changed in canonical-devices-system-image: | |
status: | New → Fix Committed |
importance: | Undecided → Medium |
milestone: | none → 12 |
Changed in canonical-devices-system-image: | |
assignee: | nobody → David Barth (dbarth) |
Changed in webapps-sprint: | |
assignee: | nobody → Alberto Mardegan (mardy) |
status: | New → Fix Released |
Changed in canonical-devices-system-image: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
This bug was fixed in the package ubuntuone- credentials - 15.11+16. 04.20160427
--------------- credentials (15.11+ 16.04.20160427) xenial; urgency=medium
ubuntuone-
[ Alberto Mardegan ]
* Be more explicit about which headers are installed. Move the symbol
export map to LINK_FLAGS on the target.
* Complete the UbuntuOne authentication plugin
* Make Token::isValid() return false on tokens created out of empty
strings. (LP: #1572943)
-- Rodney Dawes <email address hidden> Wed, 27 Apr 2016 20:33:37 +0000