diff options
author | Mike Frysinger <vapier@gentoo.org> | 2008-02-12 04:27:28 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2008-02-12 04:27:28 +0000 |
commit | 5adbc237ae645299d29f7dbff245881a4e072ea3 (patch) | |
tree | af687b57edf1929c250cdc9b0625b7d6f36c2001 /net-nds | |
parent | Version bump to 2.0.6_pre4 for testing. Since this fixes a nice little bug i... (diff) | |
download | gentoo-2-5adbc237ae645299d29f7dbff245881a4e072ea3.tar.gz gentoo-2-5adbc237ae645299d29f7dbff245881a4e072ea3.tar.bz2 gentoo-2-5adbc237ae645299d29f7dbff245881a4e072ea3.zip |
old
Diffstat (limited to 'net-nds')
-rw-r--r-- | net-nds/portmap/files/portmap-4.0-cleanup.patch | 85 | ||||
-rw-r--r-- | net-nds/portmap/files/portmap-4.0-malloc.patch | 338 | ||||
-rw-r--r-- | net-nds/portmap/files/portmap-4.0-rpc_user.patch | 59 | ||||
-rw-r--r-- | net-nds/portmap/files/portmap-4.0-sigpipe.patch | 12 | ||||
-rw-r--r-- | net-nds/portmap/files/portmap-5b-include-errno_h.patch | 18 | ||||
-rw-r--r-- | net-nds/portmap/files/portmap-5b-loopback-only.patch | 63 | ||||
-rw-r--r-- | net-nds/portmap/files/portmap-5b-no-SYS.patch | 16 | ||||
-rw-r--r-- | net-nds/portmap/files/portmap-5b-optional-tcpd.patch | 38 | ||||
-rw-r--r-- | net-nds/portmap/files/portmap_5beta.dif | 294 | ||||
-rw-r--r-- | net-nds/portmap/portmap-5b-r9.ebuild | 77 |
10 files changed, 0 insertions, 1000 deletions
diff --git a/net-nds/portmap/files/portmap-4.0-cleanup.patch b/net-nds/portmap/files/portmap-4.0-cleanup.patch deleted file mode 100644 index 2e005afe28e4..000000000000 --- a/net-nds/portmap/files/portmap-4.0-cleanup.patch +++ /dev/null @@ -1,85 +0,0 @@ -Some cleanup for my last patch. - - --- -H.J. Lu (hjl@gnu.org) --- ---- portmap_4/pmap_check.c.hostname Wed May 10 10:23:35 2000 -+++ portmap_4/pmap_check.c Wed May 10 11:03:22 2000 -@@ -35,6 +35,7 @@ - static char sccsid[] = "@(#) pmap_check.c 1.6 93/11/21 20:58:59"; - #endif - #include <unistd.h> -+#include <string.h> - #include <rpc/rpc.h> - #include <rpc/pmap_prot.h> - #include <syslog.h> -@@ -69,8 +70,6 @@ int deny_severity = LOG_WARNING; - /* coming from libwrap.a (tcp_wrappers) */ - extern int hosts_ctl(char *daemon, char *name, char *addr, char *user); - --#define good_client(a) hosts_ctl("portmap", "", inet_ntoa(a->sin_addr), "") -- - #define reserved_port(p) (IPPORT_RESERVED/2 < (p) && (p) < IPPORT_RESERVED) - - #define unreserved_port(p) (IPPORT_RESERVED <= (p) && (p) != NFS_PORT) -@@ -88,6 +87,59 @@ extern int hosts_ctl(char *daemon, char - - #define log_client(addr, proc, prog) \ - logit(allow_severity, addr, proc, prog, "") -+ -+#ifdef HOSTS_ACCESS -+static int -+good_client(addr) -+struct sockaddr_in *addr; -+{ -+ struct hostent *hp; -+ char **sp; -+ char *tmpname; -+ -+ /* Check the IP address first. */ -+ if (hosts_ctl("portmap", "", inet_ntoa(addr->sin_addr), "")) -+ return 1; -+ -+ /* Check the hostname. */ -+ hp = gethostbyaddr ((const char *) &(addr->sin_addr), -+ sizeof (addr->sin_addr), AF_INET); -+ -+ if (!hp) -+ return 0; -+ -+ /* must make sure the hostent is authorative. */ -+ tmpname = alloca (strlen (hp->h_name) + 1); -+ strcpy (tmpname, hp->h_name); -+ hp = gethostbyname(tmpname); -+ if (hp) { -+ /* now make sure the "addr->sin_addr" is on the list */ -+ for (sp = hp->h_addr_list ; *sp ; sp++) { -+ if (memcmp(*sp, &(addr->sin_addr), hp->h_length)==0) -+ break; -+ } -+ if (!*sp) -+ /* it was a FAKE. */ -+ return 0; -+ } -+ else -+ /* never heard of it. misconfigured DNS? */ -+ return 0; -+ -+ /* Check the official name first. */ -+ if (hosts_ctl("portmap", "", hp->h_name, "")) -+ return 1; -+ -+ /* Check aliases. */ -+ for (sp = hp->h_aliases; *sp ; sp++) { -+ if (hosts_ctl("portmap", "", *sp, "")) -+ return 1; -+ } -+ -+ /* No match */ -+ return 0; -+} -+#endif - - /* check_startup - additional startup code */ - diff --git a/net-nds/portmap/files/portmap-4.0-malloc.patch b/net-nds/portmap/files/portmap-4.0-malloc.patch deleted file mode 100644 index db3bf09eea93..000000000000 --- a/net-nds/portmap/files/portmap-4.0-malloc.patch +++ /dev/null @@ -1,338 +0,0 @@ -diff -urN portmap_4/daemon.c portmap_4.new/daemon.c ---- portmap_4/daemon.c Thu Jun 11 13:53:12 1992 -+++ portmap_4.new/daemon.c Mon Nov 29 18:37:28 1999 -@@ -35,7 +35,9 @@ - static char sccsid[] = "@(#)daemon.c 5.3 (Berkeley) 12/28/90"; - #endif /* LIBC_SCCS and not lint */ - -+#include <sys/types.h> - #include <fcntl.h> -+#include <unistd.h> - - /* From unistd.h */ - #define STDIN_FILENO 0 -@@ -44,7 +46,7 @@ - - /* From paths.h */ - #define _PATH_DEVNULL "/dev/null" -- -+int - daemon(nochdir, noclose) - int nochdir, noclose; - { -diff -urN portmap_4/from_local.c portmap_4.new/from_local.c ---- portmap_4/from_local.c Fri May 31 06:52:58 1996 -+++ portmap_4.new/from_local.c Tue Nov 30 01:21:27 1999 -@@ -46,12 +46,14 @@ - #include <sys/types.h> - #include <sys/socket.h> - #include <stdio.h> --#include <stdlib.h> -+#include <unistd.h> - #include <netdb.h> - #include <netinet/in.h> - #include <net/if.h> - #include <sys/ioctl.h> - #include <syslog.h> -+#include <stdlib.h> -+#include <string.h> - - #ifndef TRUE - #define TRUE 1 -@@ -95,7 +98,7 @@ - } - - /* find_local - find all IP addresses for this host */ -- -+int - find_local() - { - struct ifconf ifc; -@@ -153,7 +156,7 @@ - } - - /* from_local - determine whether request comes from the local system */ -- -+int - from_local(addr) - struct sockaddr_in *addr; - { -diff -urN portmap_4/pmap_check.c portmap_4.new/pmap_check.c ---- portmap_4/pmap_check.c Sun Nov 21 11:59:01 1993 -+++ portmap_4.new/pmap_check.c Tue Nov 30 01:19:37 1999 -@@ -34,7 +34,7 @@ - #ifndef lint - static char sccsid[] = "@(#) pmap_check.c 1.6 93/11/21 20:58:59"; - #endif -- -+#include <unistd.h> - #include <rpc/rpc.h> - #include <rpc/pmap_prot.h> - #include <syslog.h> -@@ -66,6 +66,9 @@ - - /* A handful of macros for "readability". */ - -+/* coming from libwrap.a (tcp_wrappers) */ -+extern int hosts_ctl(char *daemon, char *name, char *addr, char *user); -+ - #define good_client(a) hosts_ctl("portmap", "", inet_ntoa(a->sin_addr), "") - - #define legal_port(a,p) \ -@@ -104,6 +107,7 @@ - - /* check_default - additional checks for NULL, DUMP, GETPORT and unknown */ - -+int - check_default(addr, proc, prog) - struct sockaddr_in *addr; - u_long proc; -@@ -121,7 +125,7 @@ - } - - /* check_privileged_port - additional checks for privileged-port updates */ -- -+int - check_privileged_port(addr, proc, prog, port) - struct sockaddr_in *addr; - u_long proc; -@@ -147,6 +147,6 @@ - - #ifdef LOOPBACK_SETUNSET -- -+int - check_setunset(xprt, ludp_xprt, ltcp_xprt, proc, prog, port) - SVCXPRT *xprt; - SVCXPRT *ludp_xprt; -@@ -173,6 +174,6 @@ - - #else -- -+int - check_setunset(addr, proc, prog, port) - struct sockaddr_in *addr; - u_long proc; -@@ -160,7 +164,7 @@ - } - - /* check_callit - additional checks for forwarded requests */ -- -+int - check_callit(addr, proc, prog, aproc) - struct sockaddr_in *addr; - u_long proc; -@@ -213,13 +217,13 @@ - }; - struct proc_map *procp; - static struct proc_map procmap[] = { -- PMAPPROC_CALLIT, "callit", -- PMAPPROC_DUMP, "dump", -- PMAPPROC_GETPORT, "getport", -- PMAPPROC_NULL, "null", -- PMAPPROC_SET, "set", -- PMAPPROC_UNSET, "unset", -- 0, 0, -+ { PMAPPROC_CALLIT, "callit"}, -+ { PMAPPROC_DUMP, "dump"}, -+ { PMAPPROC_GETPORT, "getport"}, -+ { PMAPPROC_NULL, "null"}, -+ { PMAPPROC_SET, "set"}, -+ { PMAPPROC_UNSET, "unset"}, -+ { 0, 0}, - }; - - /* -@@ -233,7 +237,7 @@ - - if (prognum == 0) { - progname = ""; -- } else if (rpc = getrpcbynumber((int) prognum)) { -+ } else if ((rpc = getrpcbynumber((int) prognum))) { - progname = rpc->r_name; - } else { - sprintf(progname = progbuf, "%lu", prognum); -diff -urN portmap_4/pmap_dump.c portmap_4.new/pmap_dump.c ---- portmap_4/pmap_dump.c Thu Jun 11 13:53:16 1992 -+++ portmap_4.new/pmap_dump.c Tue Nov 30 01:22:07 1999 -@@ -22,7 +22,7 @@ - #include <rpc/pmap_prot.h> - - static char *protoname(); -- -+int - main(argc, argv) - int argc; - char **argv; -diff -urN portmap_4/pmap_set.c portmap_4.new/pmap_set.c ---- portmap_4/pmap_set.c Thu Jun 11 13:53:17 1992 -+++ portmap_4.new/pmap_set.c Tue Nov 30 01:23:49 1999 -@@ -17,6 +17,9 @@ - #include <rpc/rpc.h> - #include <rpc/pmap_clnt.h> - -+int parse_line(char *buf, u_long *, u_long *, int *, unsigned *); -+ -+int - main(argc, argv) - int argc; - char **argv; -@@ -42,7 +45,7 @@ - } - - /* parse_line - convert line to numbers */ -- -+int - parse_line(buf, prog, vers, prot, port) - char *buf; - u_long *prog; -diff -urN portmap_4/portmap.c portmap_4.new/portmap.c ---- portmap_4/portmap.c Fri May 31 06:52:59 1996 -+++ portmap_4.new/portmap.c Tue Nov 30 01:01:32 1999 -@@ -83,6 +83,7 @@ - #include <rpc/rpc.h> - #include <rpc/pmap_prot.h> - #include <stdio.h> -+#include <unistd.h> - #include <syslog.h> - #include <netdb.h> - #include <sys/socket.h> -@@ -128,6 +129,7 @@ - - #include "pmap_check.h" - -+int - main(argc, argv) - int argc; - char **argv; -@@ -229,6 +231,7 @@ - svc_run(); - syslog(LOG_ERR, "run_svc returned unexpectedly"); - abort(); -+ /* never reached */ - } - - #ifndef lint -@@ -290,7 +293,7 @@ - */ - /* remote host authorization check */ - check_default(svc_getcaller(xprt), rqstp->rq_proc, (u_long) 0); -- if (!svc_sendreply(xprt, xdr_void, (caddr_t)0) && debugging) { -+ if (!svc_sendreply(xprt, (xdrproc_t)xdr_void, (caddr_t)0) && debugging) { - abort(); - } - break; -@@ -299,7 +302,7 @@ - /* - * Set a program,version to port mapping - */ -- if (!svc_getargs(xprt, xdr_pmap, ®)) -+ if (!svc_getargs(xprt, (xdrproc_t)xdr_pmap, (caddr_t)®)) - svcerr_decode(xprt); - else { - /* reject non-local requests, protect priv. ports */ -@@ -341,7 +344,7 @@ - ans = 1; - } - done: -- if ((!svc_sendreply(xprt, xdr_int, (caddr_t)&ans)) && -+ if ((!svc_sendreply(xprt, (xdrproc_t)xdr_int, (caddr_t)&ans)) && - debugging) { - (void) fprintf(stderr, "svc_sendreply\n"); - abort(); -@@ -353,7 +356,7 @@ - /* - * Remove a program,version to port mapping. - */ -- if (!svc_getargs(xprt, xdr_pmap, ®)) -+ if (!svc_getargs(xprt, (xdrproc_t)xdr_pmap, (caddr_t)®)) - svcerr_decode(xprt); - else { - ans = 0; -@@ -387,7 +390,7 @@ - prevpml->pml_next = pml; - free(t); - } -- if ((!svc_sendreply(xprt, xdr_int, (caddr_t)&ans)) && -+ if ((!svc_sendreply(xprt, (xdrproc_t)xdr_int, (caddr_t)&ans)) && - debugging) { - (void) fprintf(stderr, "svc_sendreply\n"); - abort(); -@@ -399,7 +402,7 @@ - /* - * Lookup the mapping for a program,version and return its port - */ -- if (!svc_getargs(xprt, xdr_pmap, ®)) -+ if (!svc_getargs(xprt, (xdrproc_t)xdr_pmap, (caddr_t)®)) - svcerr_decode(xprt); - else { - /* remote host authorization check */ -@@ -414,7 +417,7 @@ - port = fnd->pml_map.pm_port; - else - port = 0; -- if ((!svc_sendreply(xprt, xdr_int, (caddr_t)&port)) && -+ if ((!svc_sendreply(xprt, (xdrproc_t)xdr_int, (caddr_t)&port)) && - debugging) { - (void) fprintf(stderr, "svc_sendreply\n"); - abort(); -@@ -426,7 +429,7 @@ - /* - * Return the current set of mapped program,version - */ -- if (!svc_getargs(xprt, xdr_void, NULL)) -+ if (!svc_getargs(xprt, (xdrproc_t)xdr_void, NULL)) - svcerr_decode(xprt); - else { - /* remote host authorization check */ -@@ -437,7 +440,7 @@ - } else { - p = pmaplist; - } -- if ((!svc_sendreply(xprt, xdr_pmaplist, -+ if ((!svc_sendreply(xprt, (xdrproc_t)xdr_pmaplist, - (caddr_t)&p)) && debugging) { - (void) fprintf(stderr, "svc_sendreply\n"); - abort(); -@@ -481,7 +484,7 @@ - struct encap_parms *epp; - { - -- return (xdr_bytes(xdrs, &(epp->args), &(epp->arglen), ARGSIZE)); -+ return (xdr_bytes(xdrs, &(epp->args), (u_int *)&(epp->arglen), ARGSIZE)); - } - - struct rmtcallargs { -@@ -585,7 +588,7 @@ - timeout.tv_sec = 5; - timeout.tv_usec = 0; - a.rmt_args.args = buf; -- if (!svc_getargs(xprt, xdr_rmtcall_args, &a)) -+ if (!svc_getargs(xprt, (xdrproc_t)xdr_rmtcall_args, (caddr_t)&a)) - return; - /* host and service access control */ - if (!check_callit(svc_getcaller(xprt), -@@ -614,9 +617,9 @@ - au->aup_uid, au->aup_gid, au->aup_len, au->aup_gids); - } - a.rmt_port = (u_long)port; -- if (clnt_call(client, a.rmt_proc, xdr_opaque_parms, &a, -- xdr_len_opaque_parms, &a, timeout) == RPC_SUCCESS) { -- svc_sendreply(xprt, xdr_rmtcall_result, (caddr_t)&a); -+ if (clnt_call(client, a.rmt_proc, (xdrproc_t)xdr_opaque_parms, (caddr_t)&a, -+ (xdrproc_t)xdr_len_opaque_parms, (caddr_t)&a, timeout) == RPC_SUCCESS) { -+ svc_sendreply(xprt, (xdrproc_t)xdr_rmtcall_result, (caddr_t)&a); - } - AUTH_DESTROY(client->cl_auth); - clnt_destroy(client); - -+--------------------------------------------------------------------+ -| Ste'phane ERANIAN | Email eranian@hpl.hp.com | -| Hewlett-Packard Laboratories | | -| 1501, Page Mill Road MS 1U-15 | | -| Palo Alto, CA 94303-096 | | -| USA | | -| Tel : (650) 857-7174 | | -| Fax : (650) 857-5548 | | -+--------------------------------------------------------------------+ - - diff --git a/net-nds/portmap/files/portmap-4.0-rpc_user.patch b/net-nds/portmap/files/portmap-4.0-rpc_user.patch deleted file mode 100644 index 6ef0736d085b..000000000000 --- a/net-nds/portmap/files/portmap-4.0-rpc_user.patch +++ /dev/null @@ -1,59 +0,0 @@ -diff -urN portmap_4/daemon.c portmap_4.new/daemon.c ---- portmap_4/daemon.c Thu Aug 3 18:07:22 2000 -+++ portmap_4.new/daemon.c Fri Aug 4 08:45:25 2000 -@@ -35,6 +35,7 @@ - static char sccsid[] = "@(#)daemon.c 5.3 (Berkeley) 12/28/90"; - #endif /* LIBC_SCCS and not lint */ - -+#include <stdlib.h> - #include <sys/types.h> - #include <fcntl.h> - #include <unistd.h> -diff -urN portmap_4/pmap_check.c portmap_4.new/pmap_check.c ---- portmap_4/pmap_check.c Thu Aug 3 18:07:22 2000 -+++ portmap_4.new/pmap_check.c Thu Aug 3 18:29:51 2000 -@@ -40,6 +40,8 @@ - #include <rpc/pmap_prot.h> - #include <syslog.h> - #include <netdb.h> -+#include <pwd.h> -+#include <sys/types.h> - #include <sys/signal.h> - #ifdef SYSV40 - #include <netinet/in.h> -@@ -149,11 +151,32 @@ - /* - * Give up root privileges so that we can never allocate a privileged - * port when forwarding an rpc request. -+ * -+ * Fix 8/3/00 Philipp Knirsch: First lookup our rpc user. If we find it, -+ * switch to that uid, otherwise simply resue the old bin user and print -+ * out a warning in syslog. - */ -- if (setuid(1) == -1) { -- syslog(LOG_ERR, "setuid(1) failed: %m"); -- exit(1); -+ -+ struct passwd *pwent; -+ -+ pwent = getpwnam("rpc"); -+ if (pwent == NULL) { -+ syslog(LOG_WARNING, "user rpc not found, reverting to user bin"); -+ if (setuid(1) == -1) { -+ syslog(LOG_ERR, "setuid(1) failed: %m"); -+ exit(1); -+ } - } -+ else { -+ if (setuid(pwent->pw_uid) == -1) { -+ syslog(LOG_WARNING, "setuid() to rpc user failed: %m"); -+ if (setuid(1) == -1) { -+ syslog(LOG_ERR, "setuid(1) failed: %m"); -+ exit(1); -+ } -+ } -+ } -+ - (void) signal(SIGINT, toggle_verboselog); - } - diff --git a/net-nds/portmap/files/portmap-4.0-sigpipe.patch b/net-nds/portmap/files/portmap-4.0-sigpipe.patch deleted file mode 100644 index dba7cf4bb15c..000000000000 --- a/net-nds/portmap/files/portmap-4.0-sigpipe.patch +++ /dev/null @@ -1,12 +0,0 @@ ---- portmap_4/portmap.c.sigpipe Sun Feb 11 17:45:11 2001 -+++ portmap_4/portmap.c Sun Feb 11 17:45:51 2001 -@@ -228,6 +228,9 @@ - #else - (void)signal(SIGCHLD, reap); - #endif -+ /* Dying on SIGPIPE doesn't help anyone */ -+ (void)signal(SIGPIPE, SIG_IGN); -+ - svc_run(); - syslog(LOG_ERR, "run_svc returned unexpectedly"); - abort(); diff --git a/net-nds/portmap/files/portmap-5b-include-errno_h.patch b/net-nds/portmap/files/portmap-5b-include-errno_h.patch deleted file mode 100644 index a440e6158809..000000000000 --- a/net-nds/portmap/files/portmap-5b-include-errno_h.patch +++ /dev/null @@ -1,18 +0,0 @@ ---- portmap_5beta/portmap.c.orig 2002-12-31 22:13:17.000000000 +0200 -+++ portmap_5beta/portmap.c 2002-12-31 22:13:50.000000000 +0200 -@@ -97,6 +97,7 @@ - - extern char *strerror(); - #include <stdlib.h> -+#include <errno.h> - - #ifndef LOG_PERROR - #define LOG_PERROR 0 -@@ -124,7 +125,6 @@ - static void callit(); - struct pmaplist *pmaplist; - int debugging = 0; --extern int errno; - - #include "pmap_check.h" - diff --git a/net-nds/portmap/files/portmap-5b-loopback-only.patch b/net-nds/portmap/files/portmap-5b-loopback-only.patch deleted file mode 100644 index e34623f6cc35..000000000000 --- a/net-nds/portmap/files/portmap-5b-loopback-only.patch +++ /dev/null @@ -1,63 +0,0 @@ -diff -u portmap_5beta/pmap_check.c portmap_5beta_elros/pmap_check.c ---- portmap_5beta/pmap_check.c 1996-07-07 10:49:10.000000000 +0200 -+++ portmap_5beta_elros/pmap_check.c 2004-09-24 01:56:47.000000000 +0200 -@@ -63,6 +63,7 @@ - static void logit(); - static void toggle_verboselog(); - int verboselog = 0; -+int listenonlyloopback = 0; - int allow_severity = LOG_INFO; - int deny_severity = LOG_WARNING; - -diff -u portmap_5beta/pmap_check.h portmap_5beta_elros/pmap_check.h ---- portmap_5beta/pmap_check.h 1996-07-06 23:06:23.000000000 +0200 -+++ portmap_5beta_elros/pmap_check.h 2004-09-24 01:55:24.000000000 +0200 -@@ -7,6 +7,7 @@ - extern int check_privileged_port(); - extern int check_callit(); - extern int verboselog; -+extern int listenonlyloopback; - extern int allow_severity; - extern int deny_severity; - -diff -u portmap_5beta/portmap.c portmap_5beta_elros/portmap.c ---- portmap_5beta/portmap.c 1996-07-06 23:06:24.000000000 +0200 -+++ portmap_5beta_elros/portmap.c 2004-09-24 01:49:47.000000000 +0200 -@@ -158,7 +158,7 @@ - int len = sizeof(struct sockaddr_in); - register struct pmaplist *pml; - -- while ((c = getopt(argc, argv, "dv")) != EOF) { -+ while ((c = getopt(argc, argv, "dvl")) != EOF) { - switch (c) { - - case 'd': -@@ -169,10 +169,15 @@ - verboselog = 1; - break; - -+ case 'l': -+ listenonlyloopback = 1; -+ break; -+ - default: -- (void) fprintf(stderr, "usage: %s [-dv]\n", argv[0]); -+ (void) fprintf(stderr, "usage: %s [-dvl]\n", argv[0]); - (void) fprintf(stderr, "-d: debugging mode\n"); - (void) fprintf(stderr, "-v: verbose logging\n"); -+ (void) fprintf(stderr, "-l: listen only on loopback address (not on external address)\n"); - exit(1); - } - } -@@ -201,6 +206,11 @@ - addr.sin_addr.s_addr = 0; - addr.sin_family = AF_INET; - addr.sin_port = htons(PMAPPORT); -+ -+ if (listenonlyloopback) { -+ addr.sin_addr.s_addr = htonl(INADDR_LOOPBACK); -+ } -+ - if (bind(sock, (struct sockaddr *)&addr, len) != 0) { - syslog(LOG_ERR, "cannot bind udp: %m"); - exit(1); diff --git a/net-nds/portmap/files/portmap-5b-no-SYS.patch b/net-nds/portmap/files/portmap-5b-no-SYS.patch deleted file mode 100644 index ca8798d21b91..000000000000 --- a/net-nds/portmap/files/portmap-5b-no-SYS.patch +++ /dev/null @@ -1,16 +0,0 @@ -The Makefile doesn't actually use the SYS variable and having it -set in your env can cause weird build failures. Just punt it. - -http://bugs.gentoo.org/show_bug.cgi?id=83000 - ---- portmap/Makefile -+++ portmap/Makefile -@@ -109,7 +109,7 @@ - SHELL = /bin/sh - - COPT = $(CONST) -Dperror=xperror $(CHECK_PORT) \ -- $(SYS) -DFACILITY=$(FACILITY) $(ULONG) $(ZOMBIES) $(SA_LEN) \ -+ -DFACILITY=$(FACILITY) $(ULONG) $(ZOMBIES) $(SA_LEN) \ - $(LOOPBACK) $(SETPGRP) - CFLAGS = $(COPT) $(O) $(NSARCHS) - OBJECTS = portmap.o pmap_check.o from_local.o $(AUX) diff --git a/net-nds/portmap/files/portmap-5b-optional-tcpd.patch b/net-nds/portmap/files/portmap-5b-optional-tcpd.patch deleted file mode 100644 index fa2d5204af86..000000000000 --- a/net-nds/portmap/files/portmap-5b-optional-tcpd.patch +++ /dev/null @@ -1,38 +0,0 @@ ---- Makefile.orig 2004-10-31 01:54:48.073875024 -0400 -+++ Makefile 2004-10-31 01:54:58.395305928 -0400 -@@ -15,8 +15,6 @@ - # no access control tables. The local system, since it runs the portmap - # daemon, is always treated as an authorized host. - --HOSTS_ACCESS= -DHOSTS_ACCESS --WRAP_LIB = $(WRAP_DIR)/libwrap.a - - # Comment out if your RPC library does not allocate privileged ports for - # requests from processes with root privilege, or the new portmap will -@@ -87,7 +85,7 @@ - # - AUX = # daemon.o strerror.o - --LIBS = -lwrap -lutil -+LIBS = -lutil - NSARCHS = - O = -Wall -O2 -pipe - -@@ -110,7 +108,7 @@ - - SHELL = /bin/sh - --COPT = $(CONST) -Dperror=xperror $(HOSTS_ACCESS) $(CHECK_PORT) \ -+COPT = $(CONST) -Dperror=xperror $(CHECK_PORT) \ - $(SYS) -DFACILITY=$(FACILITY) $(ULONG) $(ZOMBIES) $(SA_LEN) \ - $(LOOPBACK) $(SETPGRP) - CFLAGS = $(COPT) $(O) $(NSARCHS) -@@ -118,7 +116,7 @@ - - all: portmap pmap_dump pmap_set - --portmap: $(OBJECTS) $(WRAP_DIR)/libwrap.a -+portmap: $(OBJECTS) - $(CC) $(CFLAGS) -o $@ $(OBJECTS) $(WRAP_LIB) $(LIBS) - - pmap_dump: pmap_dump.c diff --git a/net-nds/portmap/files/portmap_5beta.dif b/net-nds/portmap/files/portmap_5beta.dif deleted file mode 100644 index 23ce5f14560f..000000000000 --- a/net-nds/portmap/files/portmap_5beta.dif +++ /dev/null @@ -1,294 +0,0 @@ ---- from_local.c -+++ from_local.c 2000/02/28 15:10:25 -@@ -46,6 +46,7 @@ - #include <sys/types.h> - #include <sys/socket.h> - #include <stdio.h> -+#include <stdlib.h> - #include <netdb.h> - #include <netinet/in.h> - #include <net/if.h> ---- Makefile -+++ Makefile 2000/02/28 15:10:25 -@@ -8,7 +8,7 @@ - # if you disagree. See `man 3 syslog' for examples. Some syslog versions - # do not provide this flexibility. - # --FACILITY=LOG_MAIL -+FACILITY=LOG_AUTH - - # To disable tcp-wrapper style access control, comment out the following - # macro definitions. Access control can also be turned off by providing -@@ -71,7 +71,7 @@ - # With verbose logging on, HP-UX 9.x and AIX 4.1 leave zombies behind when - # SIGCHLD is not ignored. Enable next macro for a fix. - # --# ZOMBIES = -DIGNORE_SIGCHLD # AIX 4.x, HP-UX 9.x -+ZOMBIES = -DIGNORE_SIGCHLD # AIX 4.x, HP-UX 9.x - - # Uncomment the following macro if your system does not have u_long. - # -@@ -81,11 +81,15 @@ - # libwrap.a object library. WRAP_DIR should specify the directory with - # that library. - --WRAP_DIR= ../tcp_wrappers -+WRAP_DIR= /usr/lib - - # Auxiliary object files that may be missing from your C library. - # --AUX = daemon.o strerror.o -+AUX = # daemon.o strerror.o -+ -+LIBS = -lwrap -lutil -+NSARCHS = -+O = -Wall -O2 -pipe - - # NEXTSTEP is a little different. The following seems to work with NS 3.2 - # -@@ -99,7 +103,7 @@ - - # Comment out if your compiler talks ANSI and understands const - # --CONST = -Dconst= -+#CONST = -Dconst= - - ### End of configurable stuff. - ############################## -@@ -109,7 +113,7 @@ - COPT = $(CONST) -Dperror=xperror $(HOSTS_ACCESS) $(CHECK_PORT) \ - $(SYS) -DFACILITY=$(FACILITY) $(ULONG) $(ZOMBIES) $(SA_LEN) \ - $(LOOPBACK) $(SETPGRP) --CFLAGS = $(COPT) -O $(NSARCHS) -+CFLAGS = $(COPT) $(O) $(NSARCHS) - OBJECTS = portmap.o pmap_check.o from_local.o $(AUX) - - all: portmap pmap_dump pmap_set ---- pmap_dump.8 -+++ pmap_dump.8 2000/02/28 15:10:25 -@@ -0,0 +1,23 @@ -+.TH PMAP_DUMP 8 "21th June 1997" Linux "Linux Programmer's Manual" -+.SH NAME -+pmap_dump \- print a list of all registered RPC programs -+.SH SYNOPSIS -+.B pmap_dump -+.SH DESCRIPTION -+The -+.B pmap_dump -+command can be used to restart a running portmapper or to print -+a list of all registered RPC programs on the local host. If you -+want to use the program to restart the portmapper you have to -+redirect the output of -+.B pmap_dump -+to a file. After this you can restart the portmapper and restore -+the list of the registered RPC programs by feeding the output -+of -+.B pmap_dump -+to the -+.B pmap_set -+command. -+.SH SEE ALSO -+.BR pmap_set (8), -+.BR portmap (8) ---- pmap_set.8 -+++ pmap_set.8 2000/02/28 15:10:25 -@@ -0,0 +1,24 @@ -+.TH PMAP_SET 8 "21th June 1997" Linux "Linux Programmer's Manual" -+.SH NAME -+pmap_set \- set the list of registered RPC programs -+.SH SYNOPSIS -+.B pmap_set -+.SH DESCRIPTION -+The -+.B pmap_set -+command can be used to restart a running portmapper or to set -+the list of registered RPC programs on the local host. If you -+want to use the program to restart the portmapper you have to -+redirect the output of -+.B pmap_dump -+to a file. After this you can restart the portmapper and restore -+the list of the registered RPC programs by feeding the output -+of -+.B pmap_dump -+to the -+.B pmap_set -+command. -+.SH SEE ALSO -+.BR pmap_dump (8), -+.BR portmap (8) -+ ---- portmap.8 -+++ portmap.8 2000/02/28 15:10:25 -@@ -0,0 +1,158 @@ -+.\" Copyright (c) 1987 Sun Microsystems -+.\" Copyright (c) 1990, 1991 The Regents of the University of California. -+.\" All rights reserved. -+.\" -+.\" Redistribution and use in source and binary forms, with or without -+.\" modification, are permitted provided that the following conditions -+.\" are met: -+.\" 1. Redistributions of source code must retain the above copyright -+.\" notice, this list of conditions and the following disclaimer. -+.\" 2. Redistributions in binary form must reproduce the above copyright -+.\" notice, this list of conditions and the following disclaimer in the -+.\" documentation and/or other materials provided with the distribution. -+.\" 3. All advertising materials mentioning features or use of this software -+.\" must display the following acknowledgement: -+.\" This product includes software developed by the University of -+.\" California, Berkeley and its contributors. -+.\" 4. Neither the name of the University nor the names of its contributors -+.\" may be used to endorse or promote products derived from this software -+.\" without specific prior written permission. -+.\" -+.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND -+.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -+.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -+.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE -+.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -+.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -+.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -+.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -+.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -+.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -+.\" SUCH DAMAGE. -+.\" -+.\" from: @(#)portmap.8 5.3 (Berkeley) 3/16/91 -+.\" $Id: portmap_5beta.dif,v 1.1 2000/08/09 23:55:48 achim Exp $ -+.\" -+.Dd March 16, 1991 -+.Dt PORTMAP 8 -+.Os BSD 4.3 -+.Sh NAME -+.Nm portmap -+.Nd -+.Tn DARPA -+port to -+.Tn RPC -+program number mapper -+.Sh SYNOPSIS -+.Nm portmap -+.Op Fl dv -+.Sh DESCRIPTION -+.Nm Portmap -+is a server that converts -+.Tn RPC -+program numbers into -+.Tn DARPA -+protocol port numbers. -+It must be running in order to make -+.Tn RPC -+calls. -+.Pp -+When an -+.Tn RPC -+server is started, it will tell -+.Nm portmap -+what port number it is listening to, and what -+.Tn RPC -+program numbers it is prepared to serve. -+When a client wishes to make an -+.Tn RPC -+call to a given program number, -+it will first contact -+.Nm portmap -+on the server machine to determine -+the port number where -+.Tn RPC -+packets should be sent. -+.Pp -+.Nm Portmap -+must be started before any -+.Tn RPC -+servers are invoked. -+.Pp -+Normally -+.Nm portmap -+forks and dissociates itself from the terminal -+like any other daemon. -+.Nm Portmap -+then logs errors using -+.Xr syslog 3 . -+.Pp -+Option available: -+.Bl -tag -width Ds -+.It Fl d -+(debug) prevents -+.Nm portmap -+from running as a daemon, -+and causes errors and debugging information -+to be printed to the standard error output. -+.It Fl v -+(verbose) causes -+.Nm portmap -+to give more logging information to -+.Xr syslogd 8. -+.Pp -+.Sh Access control -+By default, host access control is enabled. However, the host that runs -+the portmapper is always considered authorized. The host access control -+tables are never consulted with requests from the local system itself; -+they are always consulted with requests from other hosts. -+.Pp -+In order to avoid deadlocks, the portmap program does not attempt to -+look up the remote host name or user name, nor will it try to match NIS -+netgroups. The upshot of all this is that only network number patterns -+will work for portmap access control. -+.Pp -+Sample entries for the host access-control files are: -+ -+.Nm /etc/hosts.allow: -+ portmap: your.sub.net.number/your.sub.net.mask -+ portmap: 255.255.255.255 0.0.0.0 -+ -+.Nm /etc/hosts.deny -+ portmap: ALL -+ -+The syntax of the access-control files is described in the -+.Xr hosts_access 5 -+and -+.Xr hosts_options 5 -+manual page that comes with the tcp wrapper (log_tcp) -+sources. The safe_finger command comes with later wrapper releases. -+.Pp -+The first line in the hosts.allow file permits access from all systems -+within your own subnet. Some rpc services rely on broadcasts and will -+contact your portmapper anyway; and once an intruder has access to your -+local network segment you're already in deep trouble. -+.Pp -+The second line in the hosts.allow file may be needed if there are -+any PC-NFS systems on your network segment. -+.Pp -+For security reasons, the portmap process drops root privilegs after -+initialization. The access control files should therefore be readable -+for group or world. -+.El -+.Sh SEE ALSO -+.Xr inetd.conf 5 , -+.Xr rpcinfo 8 , -+.Xr inetd 8 , -+.Xr syslogd 8 , -+.Xr hosts_access 5 , -+.Xr hosts_options 5 -+.Sh BUGS -+If -+.Nm portmap -+crashes, all servers must be restarted. -+.Sh HISTORY -+The -+.Nm -+command appeared in -+.Bx 4.3 ---- portmap.c -+++ portmap.c 2000/02/28 15:10:25 -@@ -182,9 +182,8 @@ - exit(1); - } - --#ifdef LOG_MAIL -- openlog("portmap", debugging ? LOG_PID | LOG_PERROR : LOG_PID, -- FACILITY); -+#ifdef FACILITY -+ openlog("portmap", debugging ? LOG_PID | LOG_PERROR : LOG_PID, FACILITY); - #else - openlog("portmap", debugging ? LOG_PID | LOG_PERROR : LOG_PID); - #endif diff --git a/net-nds/portmap/portmap-5b-r9.ebuild b/net-nds/portmap/portmap-5b-r9.ebuild deleted file mode 100644 index c10ab0d76698..000000000000 --- a/net-nds/portmap/portmap-5b-r9.ebuild +++ /dev/null @@ -1,77 +0,0 @@ -# Copyright 1999-2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/net-nds/portmap/portmap-5b-r9.ebuild,v 1.16 2007/03/26 08:03:27 antarus Exp $ - -inherit eutils flag-o-matic toolchain-funcs - -MY_P="${PN}_${PV}eta" -S="${WORKDIR}/${MY_P}" -DESCRIPTION="Netkit - portmapper" -HOMEPAGE="ftp://ftp.porcupine.org/pub/security/index.html" -SRC_URI="ftp://ftp.porcupine.org/pub/security/${MY_P}.tar.gz" - -LICENSE="as-is" -SLOT="0" -KEYWORDS="alpha amd64 arm hppa ia64 mips ppc ppc64 s390 sh sparc x86" -IUSE="selinux tcpd" - -RDEPEND="selinux? ( sec-policy/selinux-portmap ) - tcpd? ( >=sys-apps/tcp-wrappers-7.6-r7 )" -DEPEND="${RDEPEND}" - -pkg_setup() { - enewgroup rpc 111 - enewuser rpc 111 -1 /dev/null rpc -} - -src_unpack() { - unpack ${A} - cd "${S}" - epatch "${FILESDIR}"/${PN}_5beta.dif - - # Redhat patches - epatch "${FILESDIR}"/${PN}-4.0-malloc.patch - epatch "${FILESDIR}"/${PN}-4.0-cleanup.patch - epatch "${FILESDIR}"/${PN}-4.0-rpc_user.patch - epatch "${FILESDIR}"/${PN}-4.0-sigpipe.patch - - # Should include errno.h, and not define as external. Fix - # relocation error and build problem with glibc-2.3.2 cvs ... - # <azarah@gentoo.org> (31 Dec 2002). - epatch "${FILESDIR}"/${P}-include-errno_h.patch - - # Patch to listen on loopback only #65199 - epatch "${FILESDIR}"/${P}-loopback-only.patch - - # Make tcp wrapper checks easier - epatch "${FILESDIR}"/${P}-optional-tcpd.patch - - # Remove useless make variable #83000 - epatch "${FILESDIR}"/${P}-no-SYS.patch -} - -src_compile() { - local tcpd="" - use tcpd \ - && tcpd="-lwrap" \ - && append-flags -DHOSTS_ACCESS - - emake \ - CC="$(tc-getCC)" \ - O="${CFLAGS}" \ - WRAP_LIB="${tcpd}" \ - || die -} - -src_install() { - into / - dosbin portmap || die "portmap" - into /usr - dosbin pmap_dump pmap_set || die "pmap" - - doman portmap.8 pmap_dump.8 pmap_set.8 - dodoc BLURB CHANGES README - - newinitd ${FILESDIR}/portmap.rc6 portmap - newconfd ${FILESDIR}/portmap.confd portmap -} |