mesos-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vinod Kone (Commented) (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (MESOS-54) Mesos ZooKeeper authentication is broken
Date Tue, 01 Nov 2011 21:39:32 GMT

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

Vinod Kone commented on MESOS-54:
---------------------------------

fixed and attached the patch here..
                
> 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
>         Attachments: 0001-Detector-Auth-fix.patch
>
>
> 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

        

Mime
View raw message