Mesos ZooKeeper authentication is broken
----------------------------------------

                 Key: MESOS-54
                 URL: https://issues.apache.org/jira/browse/MESOS-54
             Project: Mesos
          Issue Type: Bug
            Reporter: Vinod Kone


In src/zookeeper/zookeeper.cpp

authenticate() takes (scheme,credentials) as arguments, but this function is 
called with (username,password). this results in the client trying to 
authenticate with szk with scheme 'username' and failing.

Relevant code snippets.
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
int ZooKeeper::authenticate(const string& username, const string& password)

{ #ifndef USE_THREADED_ZOOKEEPER return process::call(impl->self(), 
&ZooKeeperImpl::authenticate, cref(username), cref(password)); #else 
Promise<int> promise = impl->authenticate(username, password); return 
promise.future().get(); #endif // USE_THREADED_ZOOKEEPER }
:::::::::::::::::::::::::::::::
Promise<int> authenticate(const string& scheme, const string& credentials)
{
Promise<int> promise;

tuple<Promise<int> >* args = new tuple<Promise<int> >(promise);

int ret = zoo_add_auth(zh, scheme.c_str(), credentials.data(),
credentials.size(), voidCompletion, args);

if (ret != ZOK) { promise.set(ret); delete args; }

return promise;
}
:::::::::::::::::::::::::::::::

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to