diff options
author | Simo Sorce <idra@samba.org> | 2008-11-24 17:26:44 -0500 |
---|---|---|
committer | Simo Sorce <idra@samba.org> | 2008-11-24 17:44:44 -0500 |
commit | 982dac8bddc097973ec33def2f1c4ecedf454989 (patch) | |
tree | a84080339d61845de2e58798d986c85a95adaed1 /server/nss | |
parent | 8c77f1f01f16c05cd8867584b5acf181ef8ce9e0 (diff) | |
download | sssd-982dac8bddc097973ec33def2f1c4ecedf454989.tar.gz sssd-982dac8bddc097973ec33def2f1c4ecedf454989.tar.bz2 sssd-982dac8bddc097973ec33def2f1c4ecedf454989.zip |
point PIPE_PATH at /var/lib/sss/pipes, not just the private path so that the
same config option can be used for the nss service
Diffstat (limited to 'server/nss')
-rw-r--r-- | server/nss/nsssrv.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/server/nss/nsssrv.c b/server/nss/nsssrv.c index 1969fe49..67aae9ea 100644 --- a/server/nss/nsssrv.c +++ b/server/nss/nsssrv.c @@ -41,6 +41,8 @@ #include "util/btreemap.h" #include "util/service_helpers.h" +#define SSS_NSS_PIPE_NAME "nss" + static int provide_identity(DBusMessage *message, void *data, DBusMessage **r); static int reply_ping(DBusMessage *message, void *data, DBusMessage **r); static int nss_init_domains(struct nss_ctx *nctx); @@ -269,14 +271,22 @@ static int nss_sbus_init(struct nss_ctx *nctx) static int set_unix_socket(struct nss_ctx *nctx) { struct sockaddr_un addr; + char *default_pipe; int ret; + default_pipe = talloc_asprintf(nctx, "%s/%s", PIPE_PATH, SSS_NSS_PIPE_NAME); + if (!default_pipe) { + return ENOMEM; + } + ret = confdb_get_string(nctx->cdb, nctx, "config/services/nss", "unixSocket", - SSS_NSS_SOCKET_NAME, &nctx->sock_name); + default_pipe, &nctx->sock_name); if (ret != EOK) { + talloc_free(default_pipe); return ret; } + talloc_free(default_pipe); nctx->lfd = socket(AF_UNIX, SOCK_STREAM, 0); if (nctx->lfd == -1) { |