You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zookeeper.apache.org by "Ben Bangert (JIRA)" <ji...@apache.org> on 2012/08/31 20:41:10 UTC

[jira] [Created] (ZOOKEEPER-1543) Bad sessionId/password combo should return auth failure

Ben Bangert created ZOOKEEPER-1543:
--------------------------------------

             Summary: Bad sessionId/password combo should return auth failure
                 Key: ZOOKEEPER-1543
                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-1543
             Project: ZooKeeper
          Issue Type: Improvement
          Components: server
    Affects Versions: 3.3.6, 3.4.3, 3.5.0
         Environment: All
            Reporter: Ben Bangert


When connecting to a server with a valid session id, but invalid password, Zookeeper disconnects with a SESSION_EXPIRED error. This is blatantly false, its actually the wrong password. Returning a SESSION_EXPIRED in this case is also not documented anywhere.

This makes debugging this issue an absolute nightmare, since the server has already lead you down the wrong track (trying to figure out why the session is expired, but it isn't).

There's already an AUTH_FAILURE error, why not return that?

--
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

[jira] [Commented] (ZOOKEEPER-1543) Bad sessionId/password combo should return auth failure

Posted by "Ben Bangert (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ZOOKEEPER-1543?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13447344#comment-13447344 ] 

Ben Bangert commented on ZOOKEEPER-1543:
----------------------------------------

It's about making it easier to debug. Let's say you saved the password and session ID, and resumed it within the appropriate period.... but the session password got corrupted somehow. Zookeeper doesn't say you have the wrong session id + password, it says the session is expired. That's plain wrong, and indicating that is confusing when trouble-shooting *why* the password got corrupted because Zookeeper just told you the wrong thing.

If you have a bad password for the session ID, there is no sane reason to say "SESSION_EXPIRED", *unless the session is actually expired*. All it does is make it harder to trouble-shoot the real problem if there's password corruption occurring between client restarts on the client-side. Systems should be easy to trouble-shoot, having Zookeeper throw someone down the wrong path because its providing misleading information isn't good.
                
> Bad sessionId/password combo should return auth failure
> -------------------------------------------------------
>
>                 Key: ZOOKEEPER-1543
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-1543
>             Project: ZooKeeper
>          Issue Type: Improvement
>          Components: server
>    Affects Versions: 3.4.3, 3.3.6, 3.5.0
>         Environment: All
>            Reporter: Ben Bangert
>
> When connecting to a server with a valid session id, but invalid password, Zookeeper disconnects with a SESSION_EXPIRED error. This is blatantly false, its actually the wrong password. Returning a SESSION_EXPIRED in this case is also not documented anywhere.
> This makes debugging this issue an absolute nightmare, since the server has already lead you down the wrong track (trying to figure out why the session is expired, but it isn't).
> There's already an AUTH_FAILURE error, why not return that?

--
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

[jira] [Commented] (ZOOKEEPER-1543) Bad sessionId/password combo should return auth failure

Posted by "Leader Ni (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ZOOKEEPER-1543?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13447267#comment-13447267 ] 

Leader Ni commented on ZOOKEEPER-1543:
--------------------------------------

You mean zookeeper need to differentiate AUTH_FAILURE from SESSION_EXPIRED?
We know, zookeeper will have two password, one is in client connection, and another is is digest auth check.
The first password may the thing you said. You know, usually, we will not change this password. So, What's the meanning of telling client the AUTH_FAILURE.
And the second password---the password in digest, i'm sure server will tell client the auth_failure.
                
> Bad sessionId/password combo should return auth failure
> -------------------------------------------------------
>
>                 Key: ZOOKEEPER-1543
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-1543
>             Project: ZooKeeper
>          Issue Type: Improvement
>          Components: server
>    Affects Versions: 3.4.3, 3.3.6, 3.5.0
>         Environment: All
>            Reporter: Ben Bangert
>
> When connecting to a server with a valid session id, but invalid password, Zookeeper disconnects with a SESSION_EXPIRED error. This is blatantly false, its actually the wrong password. Returning a SESSION_EXPIRED in this case is also not documented anywhere.
> This makes debugging this issue an absolute nightmare, since the server has already lead you down the wrong track (trying to figure out why the session is expired, but it isn't).
> There's already an AUTH_FAILURE error, why not return that?

--
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

[jira] [Commented] (ZOOKEEPER-1543) Bad sessionId/password combo should return auth failure

Posted by "Henry Robinson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ZOOKEEPER-1543?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13452574#comment-13452574 ] 

Henry Robinson commented on ZOOKEEPER-1543:
-------------------------------------------

This seems reasonable to me - not sure immediately what the work looks like on the internals, but I wouldn't expect it to be too significant. Better debugging information is always good. 
                
> Bad sessionId/password combo should return auth failure
> -------------------------------------------------------
>
>                 Key: ZOOKEEPER-1543
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-1543
>             Project: ZooKeeper
>          Issue Type: Improvement
>          Components: server
>    Affects Versions: 3.4.3, 3.3.6, 3.5.0
>         Environment: All
>            Reporter: Ben Bangert
>
> When connecting to a server with a valid session id, but invalid password, Zookeeper disconnects with a SESSION_EXPIRED error. This is blatantly false, its actually the wrong password. Returning a SESSION_EXPIRED in this case is also not documented anywhere.
> This makes debugging this issue an absolute nightmare, since the server has already lead you down the wrong track (trying to figure out why the session is expired, but it isn't).
> There's already an AUTH_FAILURE error, why not return that?

--
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