Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Threaded View
Zookeeper >> mail # user >> Reg: SASL Authentication


I am trying to implement Digest MD5 SASL authentication.
While I have given the correct username and password its getting connected to zk and working fine as expected.

But if I give wrong password I am expecting "AuthFailed" exception message.
But I am getting the keeper state as "Disconnected" and the "ConnectionLoss" exception is thrown.

What I am doing wrong?

While checking in the zk server console getting the following log

2013-02-13 17:40:36,359 [myid:] - WARN  [NIOServerCxn.Factory:] - Client failed t
o SASL authenticate: javax.security.sasl.SaslException: DIGEST-MD5: digest response format violation. Mismatched response
2013-02-13 17:40:36,360 [myid:] - WARN  [NIOServerCxn.Factory:] - Closing client
connection due to SASL authentication failure.
2013-02-13 17:40:36,361 [myid:] - INFO  [NIOServerCxn.Factory:] - Closed socket co
nnection for client / which had sessionid 0x13cd30f81910001
2013-02-13 17:40:36,363 [myid:] - ERROR [NIOServerCxn.Factory:] - Unexpected Except
        at sun.nio.ch.SelectionKeyImpl.ensureValid(Unknown Source)
        at sun.nio.ch.SelectionKeyImpl.interestOps(Unknown Source)
        at org.apache.zookeeper.server.NIOServerCnxn.sendBuffer(NIOServerCnxn.java:153)
        at org.apache.zookeeper.server.NIOServerCnxn.sendResponse(NIOServerCnxn.java:1076)
        at org.apache.zookeeper.server.ZooKeeperServer.processPacket(ZooKeeperServer.java:907)
        at org.apache.zookeeper.server.NIOServerCnxn.readRequest(NIOServerCnxn.java:365)
        at org.apache.zookeeper.server.NIOServerCnxn.readPayload(NIOServerCnxn.java:202)
        at org.apache.zookeeper.server.NIOServerCnxn.doIO(NIOServerCnxn.java:236)
        at org.apache.zookeeper.server.NIOServerCnxnFactory.run(NIOServerCnxnFactory.java:208)
        at java.lang.Thread.run(Unknown Source)
2013-02-13 17:40:36,453 [myid:] - WARN  [NIOServerCxn.Factory:] - Exception causing
 close of session 0x13cd30f81910001 due to java.nio.channels.CancelledKeyException
2013-02-13 17:40:56,000 [myid:] - INFO  [SessionTracker:ZooKeeperServer@325] - Expiring session 0x13cd30f81910001, timeou
t of 20000ms exceeded
2013-02-13 17:40:56,017 [myid:] - INFO  [ProcessThread(sid:0 cport:-1)::PrepRequestProcessor@476] - Processed session ter
mination for sessionid: 0x13cd30f81910001


Please do not print this email unless it is absolutely necessary.

The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s) and may contain proprietary, confidential or privileged information. If you are not the intended recipient, you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately and destroy all copies of this message and any attachments.

WARNING: Computer viruses can be transmitted via email. The recipient should check this email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this email.