[ 
https://issues.apache.org/jira/browse/SYNCOPE-217?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13472530#comment-13472530
 ] 

Hudson commented on SYNCOPE-217:
--------------------------------

Integrated in Syncope-linux-branches #33 (See 
[https://builds.apache.org/job/Syncope-linux-branches/33/])
    [SYNCOPE-217] Manually applying fix against provided patch (Revision 
1396086)
[SYNCOPE-217] Patch applied (Revision 1396077)

     Result = SUCCESS
ilgrosso : 
Files : 
* 
/incubator/syncope/branches/1_0_X/core/src/main/java/org/apache/syncope/core/persistence/beans/user/SyncopeUser.java

ilgrosso : 
Files : 
* 
/incubator/syncope/branches/1_0_X/core/src/main/java/org/apache/syncope/core/persistence/beans/user/SyncopeUser.java

                
> SyncopeUser.hasTokenExpired() can easily cause nullpointer exception
> --------------------------------------------------------------------
>
>                 Key: SYNCOPE-217
>                 URL: https://issues.apache.org/jira/browse/SYNCOPE-217
>             Project: Syncope
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 1.0.2-incubating
>            Reporter: Jan Bernhardt
>            Assignee: Francesco Chicchiriccò
>            Priority: Minor
>             Fix For: 1.0.3-incubating, 1.1.0-incubating
>
>         Attachments: SyncopeUser.java.patch, SyncopeUser.java.patch
>
>
> public boolean hasTokenExpired() {
>         return tokenExpireTime.before(new Date());
> }
> should be changed to:
> public boolean hasTokenExpired() {
>         return tokenExpireTime == null
>                 ? false
>                 : tokenExpireTime.before(new Date());
> }
> A token set to null should never expire to be consistent with the behavior 
> that a token will always be vaild valid (in checkToken method) if it is null.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to