Comments (1)
Have we tried to set host
in zoo_sasl_params_t
with NULL
?
typedef struct zoo_sasl_params {
const char *service; /*!< The service name, usually "zookeeper" */
const char *host; /*!< The server name, e.g. "zk-sasl-md5" */
const char *mechlist; /*!< Mechanisms to try, e.g. "DIGEST-MD5" */
const sasl_callback_t *callbacks; /*!< List of callbacks */
} zoo_sasl_params_t;
ZOOAPI zhandle_t *zookeeper_init_sasl(const char *host, watcher_fn fn,
int recv_timeout, const clientid_t *clientid, void *context, int flags,
log_callback_fn log_callback, zoo_sasl_params_t *sasl_params);
I found that host
would be set automatically if it was NULL
:
int zoo_sasl_connect(zhandle_t *zh)
{
......
rc = _zsasl_getipport(zh, (const struct sockaddr *)&local_ip, salen,
iplocalport, NULL);
if (rc < 0) {
return _zsasl_fail(zh, rc);
}
salen = sizeof(remote_ip);
if (getpeername(zh->fd->sock, (struct sockaddr *)&remote_ip, &salen) < 0) {
LOG_ERROR(LOGCALLBACK(zh), "getpeername");
return _zsasl_fail(zh, ZSYSTEMERROR);
}
rc = _zsasl_getipport(zh, (const struct sockaddr *)&remote_ip, salen,
ipremoteport, host);
if (rc < 0) {
return _zsasl_fail(zh, rc);
}
......
/* client new connection */
sr = sasl_client_new(
sc->params.service,
sc->params.host ? sc->params.host : host,
iplocalport,
ipremoteport,
sc->params.callbacks,
/*secflags*/0,
&sc->conn);
if (sr != SASL_OK) {
LOG_ERROR(LOGCALLBACK(zh),
"allocating SASL connection state: %s",
sasl_errstring(sr, NULL, NULL));
return _zsasl_fail(zh, ZSYSTEMERROR);
}
return ZOK;
}
from incubator-pegasus.
Related Issues (20)
- Bug(duplication):some nodes can not send duplication data in master when big difference in data size
- Failed to build Pegasus due to undefined references to all thrift-generated objects while linking libdsn_client.a HOT 1
- Replica server exits abnormally with coredump HOT 4
- Feature: support sampling record users to read specific information into detail log file
- BUG(go client):when go client is writing to one partition and the replica node core dump, go client will finish after timeout without updating the configuration. HOT 2
- use getaddrinfo instead of gethostbyname HOT 1
- Bug(go client):The cluster added a new meta node, but the meta server configuration of the go client was not updated. As a result, the client cannot find the new meta address and can only access the meta listed in the meta list HOT 2
- Question:The Go client is not compiled on GitHub, and users need to download it and build it themselves.
- Errors occurred while launching Pegasus shell HOT 1
- Implement an expiration mechanism to limit the cache size
- Errors occurred while launching Pegasus bench HOT 1
- Error occurred that snappy/zstd/lz4 is not required dependencies while running packing tools HOT 1
- Error occurred that namespace in group validator of flags was missed while building Pegasus daily HOT 1
- Feature: support force no idempotent wirte when doing duplication
- Meta server and Replica server process could not exit normally after backing up or restoring on HDFS
- pegasus uses a non OSS friendly version of org.json:json jar HOT 1
- Error occurred that "get_property could not find TARGET DOWNLOAD_EXTRACT_TIMESTAMP" while building third-parties HOT 1
- Bug(message_ex::copy): In some case, the message_ex::copy function will trigger an assertion HOT 7
- Docker image for compilation environment failed to be built due to "cannot verify archive.apache.org's certificate"
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from incubator-pegasus.