Lines Matching defs:ypclnt
52 #include <rpcsvc/ypclnt.h>
55 #include "ypclnt.h"
67 ypclnt_havepasswdd(ypclnt_t *ypclnt)
75 if (getrpcport(ypclnt->server, YPPASSWDPROG,
77 ypclnt_error(ypclnt, __func__, "no rpc.yppasswdd on server");
93 ypclnt_error(ypclnt, __func__,
100 ypclnt_error(ypclnt, __func__,
102 clnt_spcreateerror(ypclnt->server));
120 ypclnt_passwd(ypclnt_t *ypclnt, const struct passwd *pwd, const char *passwd)
122 switch (ypclnt_havepasswdd(ypclnt)) {
124 return (yppasswd_remote(ypclnt, pwd, passwd));
126 return (yppasswd_local(ypclnt, pwd));
139 yppasswd_local(ypclnt_t *ypclnt, const struct passwd *pwd)
156 yppwd.domain = strdup(ypclnt->domain);
163 ypclnt_error(ypclnt, __func__, strerror(errno));
176 ypclnt_error(ypclnt, __func__,
183 ypclnt_error(ypclnt, __func__,
185 clnt_spcreateerror(ypclnt->server));
197 ypclnt_error(ypclnt, __func__,
199 clnt_sperror(clnt, ypclnt->server));
206 ypclnt_error(ypclnt, __func__,
213 ypclnt_error(ypclnt, NULL, NULL);
239 yppasswd_remote(ypclnt_t *ypclnt, const struct passwd *pwd, const char *passwd)
256 ypclnt_error(ypclnt, __func__, strerror(errno));
262 clnt = clnt_create(ypclnt->server, YPPASSWDPROG, YPPASSWDVERS, "udp");
264 ypclnt_error(ypclnt, __func__,
266 clnt_spcreateerror(ypclnt->server));
278 ypclnt_error(ypclnt, __func__,
280 clnt_sperror(clnt, ypclnt->server));
287 ypclnt_error(ypclnt, __func__,
294 ypclnt_error(ypclnt, NULL, NULL);