yppasswdd_main.c (96391) | yppasswdd_main.c (109363) |
---|---|
1/* 2 * Copyright (c) 1995, 1996 3 * Bill Paul <wpaul@ctr.columbia.edu>. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 18 unchanged lines hidden (view full) --- 27 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 30 * SUCH DAMAGE. 31 */ 32 33#ifndef lint 34static const char rcsid[] = | 1/* 2 * Copyright (c) 1995, 1996 3 * Bill Paul <wpaul@ctr.columbia.edu>. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 18 unchanged lines hidden (view full) --- 27 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 30 * SUCH DAMAGE. 31 */ 32 33#ifndef lint 34static const char rcsid[] = |
35 "$FreeBSD: head/usr.sbin/rpc.yppasswdd/yppasswdd_main.c 96391 2002-05-11 04:10:49Z alfred $"; | 35 "$FreeBSD: head/usr.sbin/rpc.yppasswdd/yppasswdd_main.c 109363 2003-01-16 07:27:30Z mbr $"; |
36#endif /* not lint */ 37 38#include <sys/param.h> 39#include <sys/ioctl.h> 40#include <sys/stat.h> 41#include <sys/socket.h> 42#include <sys/time.h> 43#include <sys/resource.h> --- 7 unchanged lines hidden (view full) --- 51#include <stdio.h> 52#include <stdlib.h> /* getenv, exit */ 53#include <string.h> 54#include <string.h> /* strcmp */ 55#include <syslog.h> 56#include <unistd.h> 57 58#include <rpc/rpc.h> | 36#endif /* not lint */ 37 38#include <sys/param.h> 39#include <sys/ioctl.h> 40#include <sys/stat.h> 41#include <sys/socket.h> 42#include <sys/time.h> 43#include <sys/resource.h> --- 7 unchanged lines hidden (view full) --- 51#include <stdio.h> 52#include <stdlib.h> /* getenv, exit */ 53#include <string.h> 54#include <string.h> /* strcmp */ 55#include <syslog.h> 56#include <unistd.h> 57 58#include <rpc/rpc.h> |
59#include <rpc/rpc_com.h> |
|
59#include <rpc/pmap_clnt.h> /* for pmap_unset */ 60#include <rpcsvc/yp.h> 61struct dom_binding {}; 62#include <rpcsvc/ypclnt.h> 63 64#include "yppasswd.h" 65#include "yppasswdd_extern.h" 66#include "yppasswd_private.h" --- 99 unchanged lines hidden (view full) --- 166 SVCXPRT *transp = NULL; 167 struct sockaddr_in saddr; 168 int asize = sizeof (saddr); 169 struct netconfig *nconf; 170 void *localhandle; 171 int ch; 172 char *mastername; 173 char myname[MAXHOSTNAMELEN + 2]; | 60#include <rpc/pmap_clnt.h> /* for pmap_unset */ 61#include <rpcsvc/yp.h> 62struct dom_binding {}; 63#include <rpcsvc/ypclnt.h> 64 65#include "yppasswd.h" 66#include "yppasswdd_extern.h" 67#include "yppasswd_private.h" --- 99 unchanged lines hidden (view full) --- 167 SVCXPRT *transp = NULL; 168 struct sockaddr_in saddr; 169 int asize = sizeof (saddr); 170 struct netconfig *nconf; 171 void *localhandle; 172 int ch; 173 char *mastername; 174 char myname[MAXHOSTNAMELEN + 2]; |
175 int maxrec = RPC_MAXDATASIZE; |
|
174 175 extern int debug; 176 177 debug = 1; 178 179 while ((ch = getopt(argc, argv, "t:d:p:sfamuivh")) != -1) { 180 switch (ch) { 181 case 't': --- 86 unchanged lines hidden (view full) --- 268 err(1,"cannot fork"); 269 } 270 } 271 openlog("rpc.yppasswdd", LOG_PID, LOG_DAEMON); 272 273 rpcb_unset(YPPASSWDPROG, YPPASSWDVERS, NULL); 274 rpcb_unset(MASTER_YPPASSWDPROG, MASTER_YPPASSWDVERS, NULL); 275 | 176 177 extern int debug; 178 179 debug = 1; 180 181 while ((ch = getopt(argc, argv, "t:d:p:sfamuivh")) != -1) { 182 switch (ch) { 183 case 't': --- 86 unchanged lines hidden (view full) --- 270 err(1,"cannot fork"); 271 } 272 } 273 openlog("rpc.yppasswdd", LOG_PID, LOG_DAEMON); 274 275 rpcb_unset(YPPASSWDPROG, YPPASSWDVERS, NULL); 276 rpcb_unset(MASTER_YPPASSWDPROG, MASTER_YPPASSWDVERS, NULL); 277 |
278 rpc_control(RPC_SVC_CONNMAXREC_SET, &maxrec); 279 |
|
276 if (svc_create(yppasswdprog_1, YPPASSWDPROG, YPPASSWDVERS, "netpath") == 0) { 277 yp_error("cannot create yppasswd service."); 278 exit(1); 279 } 280 if (svc_create(master_yppasswdprog_1, MASTER_YPPASSWDPROG, 281 MASTER_YPPASSWDVERS, "netpath") == 0) { 282 yp_error("cannot create master_yppasswd service."); 283 exit(1); --- 65 unchanged lines hidden --- | 280 if (svc_create(yppasswdprog_1, YPPASSWDPROG, YPPASSWDVERS, "netpath") == 0) { 281 yp_error("cannot create yppasswd service."); 282 exit(1); 283 } 284 if (svc_create(master_yppasswdprog_1, MASTER_YPPASSWDPROG, 285 MASTER_YPPASSWDVERS, "netpath") == 0) { 286 yp_error("cannot create master_yppasswd service."); 287 exit(1); --- 65 unchanged lines hidden --- |