Updated to latest upstream release: libtirpc-0-3-3

Signed-off-by: Steve Dickson <steved@redhat.com>
This commit is contained in:
Steve Dickson 2015-05-07 10:34:27 -04:00
parent 7846561ddd
commit c6fe6a5e92
7 changed files with 10 additions and 4644 deletions

8
.gitignore vendored
View File

@ -1,7 +1,5 @@
Makefile
cscope*
/libtirpc-0.2.2.tar.bz2
libtirpc-0.2.2/
x86_64/
/libtirpc-0.2.3.tar.bz2
/libtirpc-0.2.4.tar.bz2
/libtirpc-0.2.5.tar.bz2
/libtirpc-0.3.0.tar.bz2
libtirpc-0.3.0

View File

@ -1,744 +0,0 @@
diff --git a/configure.ac b/configure.ac
index 11df020..10d17ea 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,7 +1,6 @@
AC_INIT(libtirpc, 0.2.4)
AM_INIT_AUTOMAKE([silent-rules])
AM_SILENT_RULES([yes])
-AM_MAINTAINER_MODE
AC_CONFIG_SRCDIR([src/auth_des.c])
AC_CONFIG_MACRO_DIR([m4])
diff --git a/man/Makefile.am b/man/Makefile.am
index 8f764b7..a37c7da 100644
--- a/man/Makefile.am
+++ b/man/Makefile.am
@@ -1,11 +1,19 @@
+LOOKUP_MANS = getrpcent.3t getrpcport.3t
+NETCONFIG_MANS = getnetconfig.3t getnetpath.3t
+BIND_MANS = bindresvport.3t
+COMPAT_MANS = des_crypt.3t rpc_soc.3t rpc_secure.3t rtime.3t
+CLIENT_MANS = rpc_clnt_auth.3t rpc_clnt_calls.3t rpc_clnt_create.3t \
+ rpcbind.3t
+SERVER_MANS = rpc_svc_calls.3t rpc_svc_create.3t rpc_svc_err.3t \
+ rpc_svc_reg.3t
+GENERIC_MANS = rpc.3t rpc_xdr.3t
-man5_MANS = netconfig.5
-man3_MANS = bindresvport.3t des_crypt.3t getnetconfig.3t getnetpath.3t \
- getrpcent.3t getrpcport.3t rpc.3t rpc_clnt_auth.3t rpc_clnt_calls.3t \
- rpc_clnt_create.3t rpc_secure.3t rpc_soc.3t rpc_svc_calls.3t \
- rpc_svc_create.3t rpc_svc_err.3t rpc_svc_reg.3t rpc_xdr.3t rtime.3t
+dist_man5_MANS = netconfig.5
+dist_man3_MANS = $(LOOKUP_MANS) $(NETCONFIG_MANS) \
+ $(BIND_MANS) $(GENERIC_MANS) $(COMPAT_MANS) \
+ $(CLIENT_MANS) $(SERVER_MANS)
-EXTRA_DIST = $(man5_MANS) $(man3_MANS)
+EXTRA_DIST = publickey.3t publickey.5 rpc.5
-CLEANFILES = cscope.* *~
-DISTCLEANFILES = Makefile.in
+CLEANFILES = cscope.* *~
+DISTCLEANFILES = Makefile.in
diff --git a/man/bindresvport.3t b/man/bindresvport.3t
index 6724663..476e678 100644
--- a/man/bindresvport.3t
+++ b/man/bindresvport.3t
@@ -7,8 +7,6 @@
.Nm bindresvport ,
.Nm bindresvport_sa
.Nd bind a socket to a privileged IP port
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In sys/types.h
.In rpc/rpc.h
@@ -94,8 +92,11 @@ for any of the errors specified for the calls
.Xr getsockopt 2 ,
or
.Xr setsockopt 2 .
+.Sh AVAILABILITY
+The
+.Fn bindresvport
+function is part of libtirpc.
.Sh SEE ALSO
.Xr bind 2 ,
.Xr getsockopt 2 ,
-.Xr setsockopt 2 ,
-.Xr ip 4
+.Xr setsockopt 2
diff --git a/man/des_crypt.3t b/man/des_crypt.3t
index b708f76..a2be1bd 100644
--- a/man/des_crypt.3t
+++ b/man/des_crypt.3t
@@ -6,8 +6,6 @@
.Sh NAME
.Nm des_crypt , ecb_crypt , cbc_crypt , des_setparity
.Nd "fast DES encryption"
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/des_crypt.h
.Ft int
@@ -118,6 +116,13 @@ Given a result status
the macro
.Fn DES_FAILED stat
is false only for the first two statuses.
+.Sh AVAILABILITY
+The
+.Fn ecb_crypt ,
+.Fn cbc_crypt ,
+and
+.Fn des_setparity
+functions are part of libtirpc.
.Sh SEE ALSO
.\" .Xr des 1 ,
.Xr crypt 3
diff --git a/man/getnetconfig.3t b/man/getnetconfig.3t
index fbaa14d..6682319 100644
--- a/man/getnetconfig.3t
+++ b/man/getnetconfig.3t
@@ -12,8 +12,6 @@
.Nm nc_perror ,
.Nm nc_sperror
.Nd get network configuration database entry
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In netconfig.h
.Ft "struct netconfig *"
@@ -215,6 +213,8 @@ implemented as thread-specific data.
.Bl -tag -width /etc/netconfig -compact
.It Pa /etc/netconfig
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr getnetpath 3 ,
.Xr netconfig 5
diff --git a/man/getnetpath.3t b/man/getnetpath.3t
index b3712ad..474acf9 100644
--- a/man/getnetpath.3t
+++ b/man/getnetpath.3t
@@ -12,8 +12,6 @@
entry corresponding to
.Ev NETPATH
component
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In netconfig.h
.Ft "struct netconfig *"
@@ -162,6 +160,8 @@ has been exhausted,
.Fn getnetpath
returns
.Dv NULL .
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr getnetconfig 3 ,
.Xr netconfig 5 ,
diff --git a/man/getrpcent.3t b/man/getrpcent.3t
index 261a8f4..2796de9 100644
--- a/man/getrpcent.3t
+++ b/man/getrpcent.3t
@@ -10,8 +10,6 @@
.Nm endrpcent ,
.Nm setrpcent
.Nd get RPC entry
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft struct rpcent *
@@ -89,10 +87,11 @@ program number is found, or until end-of-file is encountered.
.Bl -tag -width /etc/rpc -compact
.It Pa /etc/rpc
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc 5 ,
-.Xr rpcinfo 8 ,
-.Xr ypserv 8
+.Xr rpcinfo 8
.Sh DIAGNOSTICS
A
.Dv NULL
diff --git a/man/getrpcport.3t b/man/getrpcport.3t
index 8a072c7..1aa5773 100644
--- a/man/getrpcport.3t
+++ b/man/getrpcport.3t
@@ -6,8 +6,6 @@
.Sh NAME
.Nm getrpcport
.Nd get RPC port number
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.Ft int
.Fn getrpcport "char *host" "int prognum" "int versnum" "int proto"
@@ -32,3 +30,7 @@ is registered but not with version
it will still return a port number (for some version of the program)
indicating that the program is indeed registered.
The version mismatch will be detected upon the first call to the service.
+.Sh AVAILABILITY
+The
+.Fn getrpcport
+function is part of libtirpc.
diff --git a/man/rpc.3t b/man/rpc.3t
index b2927b1..9ff7423 100644
--- a/man/rpc.3t
+++ b/man/rpc.3t
@@ -6,8 +6,6 @@
.Sh NAME
.Nm rpc
.Nd library routines for remote procedure calls
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.In netconfig.h
@@ -499,6 +497,8 @@ pages on which they are described:
.Bl -tag -width /etc/netconfig
.It Pa /etc/netconfig
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr getnetconfig 3 ,
.Xr getnetpath 3 ,
diff --git a/man/rpc_clnt_auth.3t b/man/rpc_clnt_auth.3t
index ee8fd1d..e20f322 100644
--- a/man/rpc_clnt_auth.3t
+++ b/man/rpc_clnt_auth.3t
@@ -13,8 +13,6 @@
.Nm authsys_create ,
.Nm authsys_create_default
.Nd library routines for client side remote procedure call authentication
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft "void"
@@ -90,6 +88,8 @@ Call
.Fn authsys_create
with the appropriate arguments.
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc 3 ,
.Xr rpc_clnt_calls 3 ,
diff --git a/man/rpc_clnt_calls.3t b/man/rpc_clnt_calls.3t
index 38b29d5..8c3804b 100644
--- a/man/rpc_clnt_calls.3t
+++ b/man/rpc_clnt_calls.3t
@@ -19,8 +19,6 @@
.Nm rpc_broadcast_exp ,
.Nm rpc_call
.Nd library routines for client side calls
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft "enum clnt_stat"
@@ -309,6 +307,8 @@ on which it can create a connection.
You do not have control of timeouts or authentication
using this routine.
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr printf 3 ,
.Xr rpc 3 ,
diff --git a/man/rpc_clnt_create.3t b/man/rpc_clnt_create.3t
index acdbab4..95b6fc8 100644
--- a/man/rpc_clnt_create.3t
+++ b/man/rpc_clnt_create.3t
@@ -27,8 +27,6 @@
.Nd "library routines for dealing with creation and manipulation of"
.Vt CLIENT
handles
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft bool_t
@@ -507,6 +505,8 @@ It is used by the routine
.Fn clnt_pcreateerror
to print the reason for the failure.
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc 3 ,
.Xr rpc_clnt_auth 3 ,
diff --git a/man/rpc_secure.3t b/man/rpc_secure.3t
index 7969a91..7ad6e49 100644
--- a/man/rpc_secure.3t
+++ b/man/rpc_secure.3t
@@ -258,10 +258,11 @@ if it succeeds and
if it fails.
Inverse of
.Fn netname2user .
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc 3 ,
-.Xr xdr 3 ,
-.Xr keyserv 8
+.Xr xdr 3
.Pp
The following manuals:
.Rs
diff --git a/man/rpc_soc.3t b/man/rpc_soc.3t
index 59058c0..f26c0af 100644
--- a/man/rpc_soc.3t
+++ b/man/rpc_soc.3t
@@ -72,8 +72,6 @@
.Nm xprt_register ,
.Nm xprt_unregister
.Nd "library routines for remote procedure calls"
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Pp
@@ -1707,6 +1705,8 @@ This routine modifies the global variable
.Va svc_fds .
Service implementors usually do not need this routine.
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc_secure 3 ,
.Xr xdr 3
diff --git a/man/rpc_svc_calls.3t b/man/rpc_svc_calls.3t
index 582b45d..4b3c08b 100644
--- a/man/rpc_svc_calls.3t
+++ b/man/rpc_svc_calls.3t
@@ -21,8 +21,6 @@
.Nm svc_run ,
.Nm svc_sendreply
.Nd library routines for RPC servers
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft int
@@ -258,6 +256,8 @@ if it succeeds,
.Dv FALSE
otherwise.
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr poll 2 ,
.Xr select 2 ,
diff --git a/man/rpc_svc_create.3t b/man/rpc_svc_create.3t
index d47be2b..6e28d2e 100644
--- a/man/rpc_svc_create.3t
+++ b/man/rpc_svc_create.3t
@@ -18,8 +18,6 @@
.Nm svc_tp_create ,
.Nm svc_vc_create
.Nd library routines for the creation of server handles
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft bool_t
@@ -329,6 +327,8 @@ The server is not registered with the
.Xr rpcbind 8
service.
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc 3 ,
.Xr rpc_svc_calls 3 ,
diff --git a/man/rpc_svc_err.3t b/man/rpc_svc_err.3t
index 49139cb..ffc7f53 100644
--- a/man/rpc_svc_err.3t
+++ b/man/rpc_svc_err.3t
@@ -17,8 +17,6 @@
.Nm svcerr_systemerr ,
.Nm svcerr_weakauth
.Nd library routines for server side remote procedure call errors
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft void
@@ -90,6 +88,8 @@ authentication arguments.
The routine calls
.Fn svcerr_auth "xprt" "AUTH_TOOWEAK" .
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc 3 ,
.Xr rpc_svc_calls 3 ,
diff --git a/man/rpc_svc_reg.3t b/man/rpc_svc_reg.3t
index 56dd530..e74f7fc 100644
--- a/man/rpc_svc_reg.3t
+++ b/man/rpc_svc_reg.3t
@@ -16,8 +16,6 @@
.Nm xprt_register ,
.Nm xprt_unregister
.Nd library routines for registering servers
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft int
@@ -173,6 +171,8 @@ This routine modifies the global variable
.Xr rpc_svc_calls 3 ) .
Service implementors usually do not need this routine.
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr select 2 ,
.Xr rpc 3 ,
diff --git a/man/rpc_xdr.3t b/man/rpc_xdr.3t
index feb708b..ae3d663 100644
--- a/man/rpc_xdr.3t
+++ b/man/rpc_xdr.3t
@@ -15,8 +15,6 @@
.Nm xdr_rejected_reply ,
.Nm xdr_replymsg
.Nd XDR library routines for remote procedure calls
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft bool_t
@@ -96,6 +94,8 @@ This reply could be either an acceptance,
rejection or
.Dv NULL .
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc 3 ,
.Xr xdr 3
diff --git a/man/rpcbind.3t b/man/rpcbind.3t
index 99b03cf..ec492cc 100644
--- a/man/rpcbind.3t
+++ b/man/rpcbind.3t
@@ -14,8 +14,6 @@
.Nm rpcb_set ,
.Nm rpcb_unset
.Nd library routines for RPC bind service
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft "rpcblist *"
@@ -187,6 +185,8 @@ Only the owner of the service or the super-user can destroy the mapping.
in
.Xr rpc_svc_calls 3 . )
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc_clnt_calls 3 ,
.Xr rpc_svc_calls 3 ,
diff --git a/man/rtime.3t b/man/rtime.3t
index 6e61350..bc93af6 100644
--- a/man/rtime.3t
+++ b/man/rtime.3t
@@ -7,8 +7,6 @@
.Sh NAME
.Nm rtime
.Nd "get remote time"
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In sys/types.h
.In sys/time.h
@@ -46,5 +44,7 @@ however, the routine will instead use
and block until a reply is received from the time server.
.Sh RETURN VALUES
.Rv -std rtime
-.Sh SEE ALSO
-.Xr timed 8
+.Sh AVAILABILITY
+The
+.Fn rtime
+function is part of libtirpc.
diff --git a/src/auth_gss.c b/src/auth_gss.c
index 703bc3f..fd6191b 100644
--- a/src/auth_gss.c
+++ b/src/auth_gss.c
@@ -49,14 +49,14 @@
#include <netinet/in.h>
#include <gssapi/gssapi.h>
-static void authgss_nextverf();
-static bool_t authgss_marshal();
-static bool_t authgss_refresh();
-static bool_t authgss_validate();
-static void authgss_destroy();
-static void authgss_destroy_context();
-static bool_t authgss_wrap();
-static bool_t authgss_unwrap();
+static void authgss_nextverf(AUTH *);
+static bool_t authgss_marshal(AUTH *, XDR *);
+static bool_t authgss_refresh(AUTH *, void *);
+static bool_t authgss_validate(AUTH *, struct opaque_auth *);
+static void authgss_destroy(AUTH *);
+static void authgss_destroy_context(AUTH *);
+static bool_t authgss_wrap(AUTH *, XDR *, xdrproc_t, caddr_t);
+static bool_t authgss_unwrap(AUTH *, XDR *, xdrproc_t, caddr_t);
/*
@@ -198,7 +198,7 @@ authgss_create(CLIENT *clnt, gss_name_t name, struct rpc_gss_sec *sec)
save_auth = clnt->cl_auth;
clnt->cl_auth = auth;
- if (!authgss_refresh(auth))
+ if (!authgss_refresh(auth, NULL))
auth = NULL;
else
auth_get(auth); /* Reference for caller */
@@ -418,7 +418,7 @@ authgss_validate(AUTH *auth, struct opaque_auth *verf)
}
static bool_t
-authgss_refresh(AUTH *auth)
+authgss_refresh(AUTH *auth, void *dummy)
{
struct rpc_gss_data *gd;
struct rpc_gss_init_res gr;
@@ -639,7 +639,7 @@ authgss_destroy(AUTH *auth)
free(auth);
}
-bool_t
+static bool_t
authgss_wrap(AUTH *auth, XDR *xdrs, xdrproc_t xdr_func, caddr_t xdr_ptr)
{
struct rpc_gss_data *gd;
@@ -656,7 +656,7 @@ authgss_wrap(AUTH *auth, XDR *xdrs, xdrproc_t xdr_func, caddr_t xdr_ptr)
gd->sec.svc, gd->gc.gc_seq));
}
-bool_t
+static bool_t
authgss_unwrap(AUTH *auth, XDR *xdrs, xdrproc_t xdr_func, caddr_t xdr_ptr)
{
struct rpc_gss_data *gd;
diff --git a/src/clnt_simple.c b/src/clnt_simple.c
index e66da6a..7ee9542 100644
--- a/src/clnt_simple.c
+++ b/src/clnt_simple.c
@@ -104,9 +104,9 @@ rpc_call(host, prognum, versnum, procnum, inproc, in, outproc, out, nettype)
extern thread_key_t rpc_call_key;
extern mutex_t tsd_lock;
- if (rpc_call_key == -1) {
+ if (rpc_call_key == KEY_INITIALIZER) {
mutex_lock(&tsd_lock);
- if (rpc_call_key == -1)
+ if (rpc_call_key == KEY_INITIALIZER)
thr_keycreate(&rpc_call_key, rpc_call_destroy);
mutex_unlock(&tsd_lock);
}
diff --git a/src/getnetconfig.c b/src/getnetconfig.c
index 78de0f6..635c03a 100644
--- a/src/getnetconfig.c
+++ b/src/getnetconfig.c
@@ -137,10 +137,10 @@ __nc_error()
* (including non-threaded programs), or if an allocation
* fails.
*/
- if (nc_key == -1) {
+ if (nc_key == KEY_INITIALIZER) {
error = 0;
mutex_lock(&nc_lock);
- if (nc_key == -1)
+ if (nc_key == KEY_INITIALIZER)
error = thr_keycreate(&nc_key, free);
mutex_unlock(&nc_lock);
if (error)
diff --git a/src/mt_misc.c b/src/mt_misc.c
index d459dec..093086e 100644
--- a/src/mt_misc.c
+++ b/src/mt_misc.c
@@ -78,12 +78,12 @@ pthread_mutex_t svcraw_lock = PTHREAD_MUTEX_INITIALIZER;
pthread_mutex_t tsd_lock = PTHREAD_MUTEX_INITIALIZER;
/* Library global tsd keys */
-thread_key_t clnt_broadcast_key;
-thread_key_t rpc_call_key = -1;
-thread_key_t tcp_key = -1;
-thread_key_t udp_key = -1;
-thread_key_t nc_key = -1;
-thread_key_t rce_key = -1;
+thread_key_t clnt_broadcast_key = KEY_INITIALIZER;
+thread_key_t rpc_call_key = KEY_INITIALIZER;
+thread_key_t tcp_key = KEY_INITIALIZER;
+thread_key_t udp_key = KEY_INITIALIZER;
+thread_key_t nc_key = KEY_INITIALIZER;
+thread_key_t rce_key = KEY_INITIALIZER;
/* xprtlist (svc_generic.c) */
pthread_mutex_t xprtlist_lock = PTHREAD_MUTEX_INITIALIZER;
@@ -110,7 +110,7 @@ __rpc_createerr()
struct rpc_createerr *rce_addr;
mutex_lock(&tsd_lock);
- if (rce_key == -1)
+ if (rce_key == KEY_INITIALIZER)
thr_keycreate(&rce_key, free);
mutex_unlock(&tsd_lock);
@@ -131,17 +131,17 @@ __rpc_createerr()
void tsd_key_delete(void)
{
- if (clnt_broadcast_key != -1)
+ if (clnt_broadcast_key != KEY_INITIALIZER)
pthread_key_delete(clnt_broadcast_key);
- if (rpc_call_key != -1)
+ if (rpc_call_key != KEY_INITIALIZER)
pthread_key_delete(rpc_call_key);
- if (tcp_key != -1)
+ if (tcp_key != KEY_INITIALIZER)
pthread_key_delete(tcp_key);
- if (udp_key != -1)
+ if (udp_key != KEY_INITIALIZER)
pthread_key_delete(udp_key);
- if (nc_key != -1)
+ if (nc_key != KEY_INITIALIZER)
pthread_key_delete(nc_key);
- if (rce_key != -1)
+ if (rce_key != KEY_INITIALIZER)
pthread_key_delete(rce_key);
return;
}
diff --git a/src/rpc_generic.c b/src/rpc_generic.c
index 2eb91ad..a43906c 100644
--- a/src/rpc_generic.c
+++ b/src/rpc_generic.c
@@ -228,16 +228,16 @@ __rpc_getconfip(nettype)
extern thread_key_t tcp_key, udp_key;
extern mutex_t tsd_lock;
- if (tcp_key == -1) {
+ if (tcp_key == KEY_INITIALIZER) {
mutex_lock(&tsd_lock);
- if (tcp_key == -1)
+ if (tcp_key == KEY_INITIALIZER)
thr_keycreate(&tcp_key, free);
mutex_unlock(&tsd_lock);
}
netid_tcp = (char *)thr_getspecific(tcp_key);
- if (udp_key == -1) {
+ if (udp_key == KEY_INITIALIZER) {
mutex_lock(&tsd_lock);
- if (udp_key == -1)
+ if (udp_key == KEY_INITIALIZER)
thr_keycreate(&udp_key, free);
mutex_unlock(&tsd_lock);
}
diff --git a/src/rpc_soc.c b/src/rpc_soc.c
index 4213ca0..338edbb 100644
--- a/src/rpc_soc.c
+++ b/src/rpc_soc.c
@@ -508,9 +508,9 @@ clnt_broadcast(prog, vers, proc, xargs, argsp, xresults, resultsp, eachresult)
{
extern mutex_t tsd_lock;
- if (clnt_broadcast_key == -1) {
+ if (clnt_broadcast_key == KEY_INITIALIZER) {
mutex_lock(&tsd_lock);
- if (clnt_broadcast_key == -1)
+ if (clnt_broadcast_key == KEY_INITIALIZER)
thr_keycreate(&clnt_broadcast_key, free);
mutex_unlock(&tsd_lock);
}
diff --git a/src/svc_auth_gss.c b/src/svc_auth_gss.c
index 9c74313..601a691 100644
--- a/src/svc_auth_gss.c
+++ b/src/svc_auth_gss.c
@@ -53,11 +53,11 @@ typedef struct gss_union_ctx_id_t {
-static bool_t svcauth_gss_destroy();
-static bool_t svcauth_gss_wrap();
-static bool_t svcauth_gss_unwrap();
+static bool_t svcauth_gss_wrap(SVCAUTH *, XDR *, xdrproc_t, caddr_t);
+static bool_t svcauth_gss_unwrap(SVCAUTH *, XDR *, xdrproc_t, caddr_t);
+static bool_t svcauth_gss_destroy(SVCAUTH *);
-struct svc_auth_ops svc_auth_gss_ops = {
+static struct svc_auth_ops svc_auth_gss_ops = {
svcauth_gss_wrap,
svcauth_gss_unwrap,
svcauth_gss_destroy
@@ -79,7 +79,7 @@ struct svc_rpc_gss_data {
((struct svc_rpc_gss_data *)(auth)->svc_ah_private)
/* Global server credentials. */
-gss_cred_id_t _svcauth_gss_creds;
+static gss_cred_id_t _svcauth_gss_creds;
static gss_name_t _svcauth_gss_name = NULL;
bool_t
@@ -332,7 +332,7 @@ svcauth_gss_validate(struct svc_rpc_gss_data *gd, struct rpc_msg *msg)
return (TRUE);
}
-bool_t
+static bool_t
svcauth_gss_nextverf(struct svc_req *rqst, u_int num)
{
struct svc_rpc_gss_data *gd;
@@ -513,7 +513,7 @@ _svcauth_gss(struct svc_req *rqst, struct rpc_msg *msg, bool_t *no_dispatch)
return (AUTH_OK);
}
-bool_t
+static bool_t
svcauth_gss_destroy(SVCAUTH *auth)
{
struct svc_rpc_gss_data *gd;
@@ -535,7 +535,7 @@ svcauth_gss_destroy(SVCAUTH *auth)
return (TRUE);
}
-bool_t
+static bool_t
svcauth_gss_wrap(SVCAUTH *auth, XDR *xdrs, xdrproc_t xdr_func, caddr_t xdr_ptr)
{
struct svc_rpc_gss_data *gd;
@@ -552,7 +552,7 @@ svcauth_gss_wrap(SVCAUTH *auth, XDR *xdrs, xdrproc_t xdr_func, caddr_t xdr_ptr)
gd->sec.svc, gd->seq));
}
-bool_t
+static bool_t
svcauth_gss_unwrap(SVCAUTH *auth, XDR *xdrs, xdrproc_t xdr_func, caddr_t xdr_ptr)
{
struct svc_rpc_gss_data *gd;
diff --git a/tirpc/reentrant.h b/tirpc/reentrant.h
index 9489b15..5f5c96e 100644
--- a/tirpc/reentrant.h
+++ b/tirpc/reentrant.h
@@ -46,6 +46,8 @@
#define once_t pthread_once_t
#define thread_key_t pthread_key_t
+
+#define KEY_INITIALIZER ((thread_key_t)-1)
#define MUTEX_INITIALIZER PTHREAD_MUTEX_INITIALIZER
#define RWLOCK_INITIALIZER PTHREAD_RWLOCK_INITIALIZER
#define ONCE_INITIALIZER PTHREAD_ONCE_INIT

View File

@ -1,893 +0,0 @@
diff --git a/configure.ac b/configure.ac
index 11df020..10d17ea 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,7 +1,6 @@
AC_INIT(libtirpc, 0.2.4)
AM_INIT_AUTOMAKE([silent-rules])
AM_SILENT_RULES([yes])
-AM_MAINTAINER_MODE
AC_CONFIG_SRCDIR([src/auth_des.c])
AC_CONFIG_MACRO_DIR([m4])
diff --git a/man/Makefile.am b/man/Makefile.am
index 8f764b7..a37c7da 100644
--- a/man/Makefile.am
+++ b/man/Makefile.am
@@ -1,11 +1,19 @@
+LOOKUP_MANS = getrpcent.3t getrpcport.3t
+NETCONFIG_MANS = getnetconfig.3t getnetpath.3t
+BIND_MANS = bindresvport.3t
+COMPAT_MANS = des_crypt.3t rpc_soc.3t rpc_secure.3t rtime.3t
+CLIENT_MANS = rpc_clnt_auth.3t rpc_clnt_calls.3t rpc_clnt_create.3t \
+ rpcbind.3t
+SERVER_MANS = rpc_svc_calls.3t rpc_svc_create.3t rpc_svc_err.3t \
+ rpc_svc_reg.3t
+GENERIC_MANS = rpc.3t rpc_xdr.3t
-man5_MANS = netconfig.5
-man3_MANS = bindresvport.3t des_crypt.3t getnetconfig.3t getnetpath.3t \
- getrpcent.3t getrpcport.3t rpc.3t rpc_clnt_auth.3t rpc_clnt_calls.3t \
- rpc_clnt_create.3t rpc_secure.3t rpc_soc.3t rpc_svc_calls.3t \
- rpc_svc_create.3t rpc_svc_err.3t rpc_svc_reg.3t rpc_xdr.3t rtime.3t
+dist_man5_MANS = netconfig.5
+dist_man3_MANS = $(LOOKUP_MANS) $(NETCONFIG_MANS) \
+ $(BIND_MANS) $(GENERIC_MANS) $(COMPAT_MANS) \
+ $(CLIENT_MANS) $(SERVER_MANS)
-EXTRA_DIST = $(man5_MANS) $(man3_MANS)
+EXTRA_DIST = publickey.3t publickey.5 rpc.5
-CLEANFILES = cscope.* *~
-DISTCLEANFILES = Makefile.in
+CLEANFILES = cscope.* *~
+DISTCLEANFILES = Makefile.in
diff --git a/man/bindresvport.3t b/man/bindresvport.3t
index 6724663..476e678 100644
--- a/man/bindresvport.3t
+++ b/man/bindresvport.3t
@@ -7,8 +7,6 @@
.Nm bindresvport ,
.Nm bindresvport_sa
.Nd bind a socket to a privileged IP port
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In sys/types.h
.In rpc/rpc.h
@@ -94,8 +92,11 @@ for any of the errors specified for the calls
.Xr getsockopt 2 ,
or
.Xr setsockopt 2 .
+.Sh AVAILABILITY
+The
+.Fn bindresvport
+function is part of libtirpc.
.Sh SEE ALSO
.Xr bind 2 ,
.Xr getsockopt 2 ,
-.Xr setsockopt 2 ,
-.Xr ip 4
+.Xr setsockopt 2
diff --git a/man/des_crypt.3t b/man/des_crypt.3t
index b708f76..a2be1bd 100644
--- a/man/des_crypt.3t
+++ b/man/des_crypt.3t
@@ -6,8 +6,6 @@
.Sh NAME
.Nm des_crypt , ecb_crypt , cbc_crypt , des_setparity
.Nd "fast DES encryption"
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/des_crypt.h
.Ft int
@@ -118,6 +116,13 @@ Given a result status
the macro
.Fn DES_FAILED stat
is false only for the first two statuses.
+.Sh AVAILABILITY
+The
+.Fn ecb_crypt ,
+.Fn cbc_crypt ,
+and
+.Fn des_setparity
+functions are part of libtirpc.
.Sh SEE ALSO
.\" .Xr des 1 ,
.Xr crypt 3
diff --git a/man/getnetconfig.3t b/man/getnetconfig.3t
index fbaa14d..6682319 100644
--- a/man/getnetconfig.3t
+++ b/man/getnetconfig.3t
@@ -12,8 +12,6 @@
.Nm nc_perror ,
.Nm nc_sperror
.Nd get network configuration database entry
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In netconfig.h
.Ft "struct netconfig *"
@@ -215,6 +213,8 @@ implemented as thread-specific data.
.Bl -tag -width /etc/netconfig -compact
.It Pa /etc/netconfig
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr getnetpath 3 ,
.Xr netconfig 5
diff --git a/man/getnetpath.3t b/man/getnetpath.3t
index b3712ad..474acf9 100644
--- a/man/getnetpath.3t
+++ b/man/getnetpath.3t
@@ -12,8 +12,6 @@
entry corresponding to
.Ev NETPATH
component
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In netconfig.h
.Ft "struct netconfig *"
@@ -162,6 +160,8 @@ has been exhausted,
.Fn getnetpath
returns
.Dv NULL .
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr getnetconfig 3 ,
.Xr netconfig 5 ,
diff --git a/man/getrpcent.3t b/man/getrpcent.3t
index 261a8f4..2796de9 100644
--- a/man/getrpcent.3t
+++ b/man/getrpcent.3t
@@ -10,8 +10,6 @@
.Nm endrpcent ,
.Nm setrpcent
.Nd get RPC entry
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft struct rpcent *
@@ -89,10 +87,11 @@ program number is found, or until end-of-file is encountered.
.Bl -tag -width /etc/rpc -compact
.It Pa /etc/rpc
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc 5 ,
-.Xr rpcinfo 8 ,
-.Xr ypserv 8
+.Xr rpcinfo 8
.Sh DIAGNOSTICS
A
.Dv NULL
diff --git a/man/getrpcport.3t b/man/getrpcport.3t
index 8a072c7..1aa5773 100644
--- a/man/getrpcport.3t
+++ b/man/getrpcport.3t
@@ -6,8 +6,6 @@
.Sh NAME
.Nm getrpcport
.Nd get RPC port number
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.Ft int
.Fn getrpcport "char *host" "int prognum" "int versnum" "int proto"
@@ -32,3 +30,7 @@ is registered but not with version
it will still return a port number (for some version of the program)
indicating that the program is indeed registered.
The version mismatch will be detected upon the first call to the service.
+.Sh AVAILABILITY
+The
+.Fn getrpcport
+function is part of libtirpc.
diff --git a/man/rpc.3t b/man/rpc.3t
index b2927b1..9ff7423 100644
--- a/man/rpc.3t
+++ b/man/rpc.3t
@@ -6,8 +6,6 @@
.Sh NAME
.Nm rpc
.Nd library routines for remote procedure calls
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.In netconfig.h
@@ -499,6 +497,8 @@ pages on which they are described:
.Bl -tag -width /etc/netconfig
.It Pa /etc/netconfig
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr getnetconfig 3 ,
.Xr getnetpath 3 ,
diff --git a/man/rpc_clnt_auth.3t b/man/rpc_clnt_auth.3t
index ee8fd1d..e20f322 100644
--- a/man/rpc_clnt_auth.3t
+++ b/man/rpc_clnt_auth.3t
@@ -13,8 +13,6 @@
.Nm authsys_create ,
.Nm authsys_create_default
.Nd library routines for client side remote procedure call authentication
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft "void"
@@ -90,6 +88,8 @@ Call
.Fn authsys_create
with the appropriate arguments.
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc 3 ,
.Xr rpc_clnt_calls 3 ,
diff --git a/man/rpc_clnt_calls.3t b/man/rpc_clnt_calls.3t
index 38b29d5..8c3804b 100644
--- a/man/rpc_clnt_calls.3t
+++ b/man/rpc_clnt_calls.3t
@@ -19,8 +19,6 @@
.Nm rpc_broadcast_exp ,
.Nm rpc_call
.Nd library routines for client side calls
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft "enum clnt_stat"
@@ -309,6 +307,8 @@ on which it can create a connection.
You do not have control of timeouts or authentication
using this routine.
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr printf 3 ,
.Xr rpc 3 ,
diff --git a/man/rpc_clnt_create.3t b/man/rpc_clnt_create.3t
index acdbab4..95b6fc8 100644
--- a/man/rpc_clnt_create.3t
+++ b/man/rpc_clnt_create.3t
@@ -27,8 +27,6 @@
.Nd "library routines for dealing with creation and manipulation of"
.Vt CLIENT
handles
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft bool_t
@@ -507,6 +505,8 @@ It is used by the routine
.Fn clnt_pcreateerror
to print the reason for the failure.
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc 3 ,
.Xr rpc_clnt_auth 3 ,
diff --git a/man/rpc_secure.3t b/man/rpc_secure.3t
index 7969a91..7ad6e49 100644
--- a/man/rpc_secure.3t
+++ b/man/rpc_secure.3t
@@ -258,10 +258,11 @@ if it succeeds and
if it fails.
Inverse of
.Fn netname2user .
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc 3 ,
-.Xr xdr 3 ,
-.Xr keyserv 8
+.Xr xdr 3
.Pp
The following manuals:
.Rs
diff --git a/man/rpc_soc.3t b/man/rpc_soc.3t
index 59058c0..f26c0af 100644
--- a/man/rpc_soc.3t
+++ b/man/rpc_soc.3t
@@ -72,8 +72,6 @@
.Nm xprt_register ,
.Nm xprt_unregister
.Nd "library routines for remote procedure calls"
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Pp
@@ -1707,6 +1705,8 @@ This routine modifies the global variable
.Va svc_fds .
Service implementors usually do not need this routine.
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc_secure 3 ,
.Xr xdr 3
diff --git a/man/rpc_svc_calls.3t b/man/rpc_svc_calls.3t
index 582b45d..4b3c08b 100644
--- a/man/rpc_svc_calls.3t
+++ b/man/rpc_svc_calls.3t
@@ -21,8 +21,6 @@
.Nm svc_run ,
.Nm svc_sendreply
.Nd library routines for RPC servers
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft int
@@ -258,6 +256,8 @@ if it succeeds,
.Dv FALSE
otherwise.
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr poll 2 ,
.Xr select 2 ,
diff --git a/man/rpc_svc_create.3t b/man/rpc_svc_create.3t
index d47be2b..6e28d2e 100644
--- a/man/rpc_svc_create.3t
+++ b/man/rpc_svc_create.3t
@@ -18,8 +18,6 @@
.Nm svc_tp_create ,
.Nm svc_vc_create
.Nd library routines for the creation of server handles
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft bool_t
@@ -329,6 +327,8 @@ The server is not registered with the
.Xr rpcbind 8
service.
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc 3 ,
.Xr rpc_svc_calls 3 ,
diff --git a/man/rpc_svc_err.3t b/man/rpc_svc_err.3t
index 49139cb..ffc7f53 100644
--- a/man/rpc_svc_err.3t
+++ b/man/rpc_svc_err.3t
@@ -17,8 +17,6 @@
.Nm svcerr_systemerr ,
.Nm svcerr_weakauth
.Nd library routines for server side remote procedure call errors
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft void
@@ -90,6 +88,8 @@ authentication arguments.
The routine calls
.Fn svcerr_auth "xprt" "AUTH_TOOWEAK" .
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc 3 ,
.Xr rpc_svc_calls 3 ,
diff --git a/man/rpc_svc_reg.3t b/man/rpc_svc_reg.3t
index 56dd530..e74f7fc 100644
--- a/man/rpc_svc_reg.3t
+++ b/man/rpc_svc_reg.3t
@@ -16,8 +16,6 @@
.Nm xprt_register ,
.Nm xprt_unregister
.Nd library routines for registering servers
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft int
@@ -173,6 +171,8 @@ This routine modifies the global variable
.Xr rpc_svc_calls 3 ) .
Service implementors usually do not need this routine.
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr select 2 ,
.Xr rpc 3 ,
diff --git a/man/rpc_xdr.3t b/man/rpc_xdr.3t
index feb708b..ae3d663 100644
--- a/man/rpc_xdr.3t
+++ b/man/rpc_xdr.3t
@@ -15,8 +15,6 @@
.Nm xdr_rejected_reply ,
.Nm xdr_replymsg
.Nd XDR library routines for remote procedure calls
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft bool_t
@@ -96,6 +94,8 @@ This reply could be either an acceptance,
rejection or
.Dv NULL .
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc 3 ,
.Xr xdr 3
diff --git a/man/rpcbind.3t b/man/rpcbind.3t
index 99b03cf..ec492cc 100644
--- a/man/rpcbind.3t
+++ b/man/rpcbind.3t
@@ -14,8 +14,6 @@
.Nm rpcb_set ,
.Nm rpcb_unset
.Nd library routines for RPC bind service
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In rpc/rpc.h
.Ft "rpcblist *"
@@ -187,6 +185,8 @@ Only the owner of the service or the super-user can destroy the mapping.
in
.Xr rpc_svc_calls 3 . )
.El
+.Sh AVAILABILITY
+These functions are part of libtirpc.
.Sh SEE ALSO
.Xr rpc_clnt_calls 3 ,
.Xr rpc_svc_calls 3 ,
diff --git a/man/rtime.3t b/man/rtime.3t
index 6e61350..bc93af6 100644
--- a/man/rtime.3t
+++ b/man/rtime.3t
@@ -7,8 +7,6 @@
.Sh NAME
.Nm rtime
.Nd "get remote time"
-.Sh LIBRARY
-.Lb libc
.Sh SYNOPSIS
.In sys/types.h
.In sys/time.h
@@ -46,5 +44,7 @@ however, the routine will instead use
and block until a reply is received from the time server.
.Sh RETURN VALUES
.Rv -std rtime
-.Sh SEE ALSO
-.Xr timed 8
+.Sh AVAILABILITY
+The
+.Fn rtime
+function is part of libtirpc.
diff --git a/src/auth_gss.c b/src/auth_gss.c
index 703bc3f..fd6191b 100644
--- a/src/auth_gss.c
+++ b/src/auth_gss.c
@@ -49,14 +49,14 @@
#include <netinet/in.h>
#include <gssapi/gssapi.h>
-static void authgss_nextverf();
-static bool_t authgss_marshal();
-static bool_t authgss_refresh();
-static bool_t authgss_validate();
-static void authgss_destroy();
-static void authgss_destroy_context();
-static bool_t authgss_wrap();
-static bool_t authgss_unwrap();
+static void authgss_nextverf(AUTH *);
+static bool_t authgss_marshal(AUTH *, XDR *);
+static bool_t authgss_refresh(AUTH *, void *);
+static bool_t authgss_validate(AUTH *, struct opaque_auth *);
+static void authgss_destroy(AUTH *);
+static void authgss_destroy_context(AUTH *);
+static bool_t authgss_wrap(AUTH *, XDR *, xdrproc_t, caddr_t);
+static bool_t authgss_unwrap(AUTH *, XDR *, xdrproc_t, caddr_t);
/*
@@ -198,7 +198,7 @@ authgss_create(CLIENT *clnt, gss_name_t name, struct rpc_gss_sec *sec)
save_auth = clnt->cl_auth;
clnt->cl_auth = auth;
- if (!authgss_refresh(auth))
+ if (!authgss_refresh(auth, NULL))
auth = NULL;
else
auth_get(auth); /* Reference for caller */
@@ -418,7 +418,7 @@ authgss_validate(AUTH *auth, struct opaque_auth *verf)
}
static bool_t
-authgss_refresh(AUTH *auth)
+authgss_refresh(AUTH *auth, void *dummy)
{
struct rpc_gss_data *gd;
struct rpc_gss_init_res gr;
@@ -639,7 +639,7 @@ authgss_destroy(AUTH *auth)
free(auth);
}
-bool_t
+static bool_t
authgss_wrap(AUTH *auth, XDR *xdrs, xdrproc_t xdr_func, caddr_t xdr_ptr)
{
struct rpc_gss_data *gd;
@@ -656,7 +656,7 @@ authgss_wrap(AUTH *auth, XDR *xdrs, xdrproc_t xdr_func, caddr_t xdr_ptr)
gd->sec.svc, gd->gc.gc_seq));
}
-bool_t
+static bool_t
authgss_unwrap(AUTH *auth, XDR *xdrs, xdrproc_t xdr_func, caddr_t xdr_ptr)
{
struct rpc_gss_data *gd;
diff --git a/src/clnt_simple.c b/src/clnt_simple.c
index e66da6a..7ee9542 100644
--- a/src/clnt_simple.c
+++ b/src/clnt_simple.c
@@ -104,9 +104,9 @@ rpc_call(host, prognum, versnum, procnum, inproc, in, outproc, out, nettype)
extern thread_key_t rpc_call_key;
extern mutex_t tsd_lock;
- if (rpc_call_key == -1) {
+ if (rpc_call_key == KEY_INITIALIZER) {
mutex_lock(&tsd_lock);
- if (rpc_call_key == -1)
+ if (rpc_call_key == KEY_INITIALIZER)
thr_keycreate(&rpc_call_key, rpc_call_destroy);
mutex_unlock(&tsd_lock);
}
diff --git a/src/getnetconfig.c b/src/getnetconfig.c
index 78de0f6..635c03a 100644
--- a/src/getnetconfig.c
+++ b/src/getnetconfig.c
@@ -137,10 +137,10 @@ __nc_error()
* (including non-threaded programs), or if an allocation
* fails.
*/
- if (nc_key == -1) {
+ if (nc_key == KEY_INITIALIZER) {
error = 0;
mutex_lock(&nc_lock);
- if (nc_key == -1)
+ if (nc_key == KEY_INITIALIZER)
error = thr_keycreate(&nc_key, free);
mutex_unlock(&nc_lock);
if (error)
diff --git a/src/mt_misc.c b/src/mt_misc.c
index d459dec..093086e 100644
--- a/src/mt_misc.c
+++ b/src/mt_misc.c
@@ -78,12 +78,12 @@ pthread_mutex_t svcraw_lock = PTHREAD_MUTEX_INITIALIZER;
pthread_mutex_t tsd_lock = PTHREAD_MUTEX_INITIALIZER;
/* Library global tsd keys */
-thread_key_t clnt_broadcast_key;
-thread_key_t rpc_call_key = -1;
-thread_key_t tcp_key = -1;
-thread_key_t udp_key = -1;
-thread_key_t nc_key = -1;
-thread_key_t rce_key = -1;
+thread_key_t clnt_broadcast_key = KEY_INITIALIZER;
+thread_key_t rpc_call_key = KEY_INITIALIZER;
+thread_key_t tcp_key = KEY_INITIALIZER;
+thread_key_t udp_key = KEY_INITIALIZER;
+thread_key_t nc_key = KEY_INITIALIZER;
+thread_key_t rce_key = KEY_INITIALIZER;
/* xprtlist (svc_generic.c) */
pthread_mutex_t xprtlist_lock = PTHREAD_MUTEX_INITIALIZER;
@@ -110,7 +110,7 @@ __rpc_createerr()
struct rpc_createerr *rce_addr;
mutex_lock(&tsd_lock);
- if (rce_key == -1)
+ if (rce_key == KEY_INITIALIZER)
thr_keycreate(&rce_key, free);
mutex_unlock(&tsd_lock);
@@ -131,17 +131,17 @@ __rpc_createerr()
void tsd_key_delete(void)
{
- if (clnt_broadcast_key != -1)
+ if (clnt_broadcast_key != KEY_INITIALIZER)
pthread_key_delete(clnt_broadcast_key);
- if (rpc_call_key != -1)
+ if (rpc_call_key != KEY_INITIALIZER)
pthread_key_delete(rpc_call_key);
- if (tcp_key != -1)
+ if (tcp_key != KEY_INITIALIZER)
pthread_key_delete(tcp_key);
- if (udp_key != -1)
+ if (udp_key != KEY_INITIALIZER)
pthread_key_delete(udp_key);
- if (nc_key != -1)
+ if (nc_key != KEY_INITIALIZER)
pthread_key_delete(nc_key);
- if (rce_key != -1)
+ if (rce_key != KEY_INITIALIZER)
pthread_key_delete(rce_key);
return;
}
diff --git a/src/rpc_generic.c b/src/rpc_generic.c
index 2eb91ad..a43906c 100644
--- a/src/rpc_generic.c
+++ b/src/rpc_generic.c
@@ -228,16 +228,16 @@ __rpc_getconfip(nettype)
extern thread_key_t tcp_key, udp_key;
extern mutex_t tsd_lock;
- if (tcp_key == -1) {
+ if (tcp_key == KEY_INITIALIZER) {
mutex_lock(&tsd_lock);
- if (tcp_key == -1)
+ if (tcp_key == KEY_INITIALIZER)
thr_keycreate(&tcp_key, free);
mutex_unlock(&tsd_lock);
}
netid_tcp = (char *)thr_getspecific(tcp_key);
- if (udp_key == -1) {
+ if (udp_key == KEY_INITIALIZER) {
mutex_lock(&tsd_lock);
- if (udp_key == -1)
+ if (udp_key == KEY_INITIALIZER)
thr_keycreate(&udp_key, free);
mutex_unlock(&tsd_lock);
}
diff --git a/src/rpc_soc.c b/src/rpc_soc.c
index 4213ca0..338edbb 100644
--- a/src/rpc_soc.c
+++ b/src/rpc_soc.c
@@ -508,9 +508,9 @@ clnt_broadcast(prog, vers, proc, xargs, argsp, xresults, resultsp, eachresult)
{
extern mutex_t tsd_lock;
- if (clnt_broadcast_key == -1) {
+ if (clnt_broadcast_key == KEY_INITIALIZER) {
mutex_lock(&tsd_lock);
- if (clnt_broadcast_key == -1)
+ if (clnt_broadcast_key == KEY_INITIALIZER)
thr_keycreate(&clnt_broadcast_key, free);
mutex_unlock(&tsd_lock);
}
diff --git a/src/svc.c b/src/svc.c
index 08cd6c9..8afd15d 100644
--- a/src/svc.c
+++ b/src/svc.c
@@ -649,6 +649,7 @@ svc_getreq_common (fd)
{
if (SVC_RECV (xprt, &msg))
{
+ bool_t no_dispatch;
/* now find the exported program and call it */
struct svc_callout *s;
@@ -660,11 +661,14 @@ svc_getreq_common (fd)
r.rq_proc = msg.rm_call.cb_proc;
r.rq_cred = msg.rm_call.cb_cred;
/* first authenticate the message */
- if ((why = _authenticate (&r, &msg)) != AUTH_OK)
+ why = _gss_authenticate(&r, &msg, &no_dispatch);
+ if (why != AUTH_OK)
{
svcerr_auth (xprt, why);
goto call_done;
}
+ if (no_dispatch)
+ goto call_done;
/* now match message with a registered service */
prog_found = FALSE;
low_vers = (rpcvers_t) - 1L;
diff --git a/src/svc_auth.c b/src/svc_auth.c
index e80d5f9..31241c9 100644
--- a/src/svc_auth.c
+++ b/src/svc_auth.c
@@ -82,9 +82,10 @@ static struct authsvc *Auths = NULL;
* invalid.
*/
enum auth_stat
-_authenticate(rqst, msg)
+_gss_authenticate(rqst, msg, no_dispatch)
struct svc_req *rqst;
struct rpc_msg *msg;
+ bool_t *no_dispatch;
{
int cred_flavor;
struct authsvc *asp;
@@ -97,6 +98,7 @@ _authenticate(rqst, msg)
rqst->rq_xprt->xp_verf.oa_flavor = _null_auth.oa_flavor;
rqst->rq_xprt->xp_verf.oa_length = 0;
cred_flavor = rqst->rq_cred.oa_flavor;
+ *no_dispatch = FALSE;
switch (cred_flavor) {
case AUTH_NONE:
dummy = _svcauth_none(rqst, msg);
@@ -112,6 +114,11 @@ _authenticate(rqst, msg)
dummy = _svcauth_des(rqst, msg);
return (dummy);
#endif
+#ifdef HAVE_RPCSEC_GSS
+ case RPCSEC_GSS:
+ dummy = _svcauth_gss(rqst, msg, no_dispatch);
+ return (dummy);
+#endif
default:
break;
}
@@ -132,6 +139,13 @@ _authenticate(rqst, msg)
return (AUTH_REJECTEDCRED);
}
+enum auth_stat
+_authenticate(struct svc_req *rqst, struct rpc_msg *msg)
+{
+ bool_t no_dispatch;
+ return _gss_authenticate(rqst, msg, &no_dispatch);
+}
+
/*
* Allow the rpc service to register new authentication types that it is
* prepared to handle. When an authentication flavor is registered,
@@ -161,6 +175,9 @@ svc_auth_reg(cred_flavor, handler)
#ifdef DES_BUILTIN
case AUTH_DES:
#endif
+#ifdef HAVE_RPCSEC_GSS
+ case RPCSEC_GSS:
+#endif
/* already registered */
return (1);
diff --git a/src/svc_auth_gss.c b/src/svc_auth_gss.c
index 9c74313..26c1065 100644
--- a/src/svc_auth_gss.c
+++ b/src/svc_auth_gss.c
@@ -53,11 +53,11 @@ typedef struct gss_union_ctx_id_t {
-static bool_t svcauth_gss_destroy();
-static bool_t svcauth_gss_wrap();
-static bool_t svcauth_gss_unwrap();
+static bool_t svcauth_gss_wrap(SVCAUTH *, XDR *, xdrproc_t, caddr_t);
+static bool_t svcauth_gss_unwrap(SVCAUTH *, XDR *, xdrproc_t, caddr_t);
+static bool_t svcauth_gss_destroy(SVCAUTH *);
-struct svc_auth_ops svc_auth_gss_ops = {
+static struct svc_auth_ops svc_auth_gss_ops = {
svcauth_gss_wrap,
svcauth_gss_unwrap,
svcauth_gss_destroy
@@ -79,7 +79,7 @@ struct svc_rpc_gss_data {
((struct svc_rpc_gss_data *)(auth)->svc_ah_private)
/* Global server credentials. */
-gss_cred_id_t _svcauth_gss_creds;
+static gss_cred_id_t _svcauth_gss_creds;
static gss_name_t _svcauth_gss_name = NULL;
bool_t
@@ -286,21 +286,19 @@ svcauth_gss_validate(struct svc_rpc_gss_data *gd, struct rpc_msg *msg)
struct opaque_auth *oa;
gss_buffer_desc rpcbuf, checksum;
OM_uint32 maj_stat, min_stat, qop_state;
- u_char rpchdr[128];
+ u_char *rpchdr;
int32_t *buf;
gss_log_debug("in svcauth_gss_validate()");
- memset(rpchdr, 0, sizeof(rpchdr));
-
/* XXX - Reconstruct RPC header for signing (from xdr_callmsg). */
oa = &msg->rm_call.cb_cred;
if (oa->oa_length > MAX_AUTH_BYTES)
return (FALSE);
-
- /* 8 XDR units from the IXDR macro calls. */
- if (sizeof(rpchdr) < (8 * BYTES_PER_XDR_UNIT +
- RNDUP(oa->oa_length)))
+
+ rpchdr = (u_char *)calloc(((8 * BYTES_PER_XDR_UNIT) +
+ RNDUP(oa->oa_length)), 1);
+ if (rpchdr == NULL)
return (FALSE);
buf = (int32_t *)rpchdr;
@@ -325,6 +323,8 @@ svcauth_gss_validate(struct svc_rpc_gss_data *gd, struct rpc_msg *msg)
maj_stat = gss_verify_mic(&min_stat, gd->ctx, &rpcbuf, &checksum,
&qop_state);
+ free(rpchdr);
+
if (maj_stat != GSS_S_COMPLETE) {
gss_log_status("gss_verify_mic", maj_stat, min_stat);
return (FALSE);
@@ -332,7 +332,7 @@ svcauth_gss_validate(struct svc_rpc_gss_data *gd, struct rpc_msg *msg)
return (TRUE);
}
-bool_t
+static bool_t
svcauth_gss_nextverf(struct svc_req *rqst, u_int num)
{
struct svc_rpc_gss_data *gd;
@@ -513,7 +513,7 @@ _svcauth_gss(struct svc_req *rqst, struct rpc_msg *msg, bool_t *no_dispatch)
return (AUTH_OK);
}
-bool_t
+static bool_t
svcauth_gss_destroy(SVCAUTH *auth)
{
struct svc_rpc_gss_data *gd;
@@ -535,7 +535,7 @@ svcauth_gss_destroy(SVCAUTH *auth)
return (TRUE);
}
-bool_t
+static bool_t
svcauth_gss_wrap(SVCAUTH *auth, XDR *xdrs, xdrproc_t xdr_func, caddr_t xdr_ptr)
{
struct svc_rpc_gss_data *gd;
@@ -552,7 +552,7 @@ svcauth_gss_wrap(SVCAUTH *auth, XDR *xdrs, xdrproc_t xdr_func, caddr_t xdr_ptr)
gd->sec.svc, gd->seq));
}
-bool_t
+static bool_t
svcauth_gss_unwrap(SVCAUTH *auth, XDR *xdrs, xdrproc_t xdr_func, caddr_t xdr_ptr)
{
struct svc_rpc_gss_data *gd;
diff --git a/tirpc/reentrant.h b/tirpc/reentrant.h
index 9489b15..5f5c96e 100644
--- a/tirpc/reentrant.h
+++ b/tirpc/reentrant.h
@@ -46,6 +46,8 @@
#define once_t pthread_once_t
#define thread_key_t pthread_key_t
+
+#define KEY_INITIALIZER ((thread_key_t)-1)
#define MUTEX_INITIALIZER PTHREAD_MUTEX_INITIALIZER
#define RWLOCK_INITIALIZER PTHREAD_RWLOCK_INITIALIZER
#define ONCE_INITIALIZER PTHREAD_ONCE_INIT
diff --git a/tirpc/rpc/auth.h b/tirpc/rpc/auth.h
index 4ce11f0..7c8f813 100644
--- a/tirpc/rpc/auth.h
+++ b/tirpc/rpc/auth.h
@@ -399,6 +399,7 @@ struct rpc_msg;
enum auth_stat _svcauth_none (struct svc_req *, struct rpc_msg *);
enum auth_stat _svcauth_short (struct svc_req *, struct rpc_msg *);
enum auth_stat _svcauth_unix (struct svc_req *, struct rpc_msg *);
+enum auth_stat _svcauth_gss (struct svc_req *, struct rpc_msg *, bool_t *);
__END_DECLS
#define AUTH_NONE 0 /* no authentication */
diff --git a/tirpc/rpc/svc_auth.h b/tirpc/rpc/svc_auth.h
index 14269d1..723c989 100644
--- a/tirpc/rpc/svc_auth.h
+++ b/tirpc/rpc/svc_auth.h
@@ -66,6 +66,8 @@ typedef struct SVCAUTH {
* Server side authenticator
*/
__BEGIN_DECLS
+extern enum auth_stat _gss_authenticate(struct svc_req *, struct rpc_msg *,
+ bool_t *);
extern enum auth_stat _authenticate(struct svc_req *, struct rpc_msg *);
extern int svc_auth_reg(int, enum auth_stat (*)(struct svc_req *,
struct rpc_msg *));

View File

@ -1,270 +0,0 @@
diff --git a/INSTALL b/INSTALL
index 8b641e3..f812f5a 120000
--- a/INSTALL
+++ b/INSTALL
@@ -1 +1 @@
-/usr/share/automake-1.13/INSTALL
\ No newline at end of file
+/usr/share/automake-1.14/INSTALL
\ No newline at end of file
diff --git a/configure.ac b/configure.ac
index bcbe911..10d17ea 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,4 +1,4 @@
-AC_INIT(libtirpc, 0.2.5)
+AC_INIT(libtirpc, 0.2.4)
AM_INIT_AUTOMAKE([silent-rules])
AM_SILENT_RULES([yes])
AC_CONFIG_SRCDIR([src/auth_des.c])
diff --git a/libtirpc.pc.in b/libtirpc.pc.in
index ec4cf75..38034c5 100644
--- a/libtirpc.pc.in
+++ b/libtirpc.pc.in
@@ -8,4 +8,5 @@ Description: Transport Independent RPC Library
Requires:
Version: @PACKAGE_VERSION@
Libs: -L@libdir@ -ltirpc
+Libs.private: -lpthread
Cflags: -I@includedir@/tirpc
diff --git a/src/clnt_bcast.c b/src/clnt_bcast.c
index 373d8a5..ddcb694 100644
--- a/src/clnt_bcast.c
+++ b/src/clnt_bcast.c
@@ -142,7 +142,8 @@ __rpc_getbroadifs(int af, int proto, int socktype, broadlist_t *list)
return 0;
for (ifap = ifp; ifap != NULL; ifap = ifap->ifa_next) {
- if (ifap->ifa_addr->sa_family != af ||
+ if (ifap->ifa_addr == NULL || /* happens for eg tuntap devices */
+ ifap->ifa_addr->sa_family != af ||
!(ifap->ifa_flags & IFF_UP))
continue;
bip = (struct broadif *)malloc(sizeof *bip);
@@ -588,9 +589,11 @@ rpc_broadcast_exp(prog, vers, proc, xargs, argsp, xresults, resultsp,
LIBTIRPC_DEBUG(3, ("rpc_broadcast_exp: uaddr %s\n", uaddrp));
np = uaddr2taddr(
fdlist[i].nconf, uaddrp);
- done = (*eachresult)(resultsp,
- np, fdlist[i].nconf);
- free(np);
+ if (np != NULL) {
+ done = (*eachresult)(resultsp,
+ np, fdlist[i].nconf);
+ free(np);
+ }
#ifdef PORTMAP
}
#endif /* PORTMAP */
diff --git a/src/debug.h b/src/debug.h
index afc8d57..c971ac3 100644
--- a/src/debug.h
+++ b/src/debug.h
@@ -21,6 +21,8 @@
#ifndef _DEBUG_H
#define _DEBUG_H
+
+#include <stdarg.h>
#include <syslog.h>
extern int libtirpc_debug_level;
diff --git a/src/rpc_generic.c b/src/rpc_generic.c
index a43906c..764a25c 100644
--- a/src/rpc_generic.c
+++ b/src/rpc_generic.c
@@ -608,6 +608,7 @@ __rpc_taddr2uaddr_af(int af, const struct netbuf *nbuf)
struct sockaddr_in6 *sin6;
char namebuf6[INET6_ADDRSTRLEN];
#endif
+ int path_len;
u_int16_t port;
if (nbuf->len <= 0)
@@ -638,13 +639,12 @@ __rpc_taddr2uaddr_af(int af, const struct netbuf *nbuf)
#endif
case AF_LOCAL:
sun = nbuf->buf;
- /* if (asprintf(&ret, "%.*s", (int)(sun->sun_len -
- offsetof(struct sockaddr_un, sun_path)),
- sun->sun_path) < 0)*/
- if (asprintf(&ret, "%.*s", (int)(sizeof(*sun) -
- offsetof(struct sockaddr_un, sun_path)),
- sun->sun_path) < 0)
+ path_len = nbuf->len - offsetof(struct sockaddr_un, sun_path);
+ if (path_len < 0)
+ return NULL;
+
+ if (asprintf(&ret, "%.*s", path_len, sun->sun_path) < 0)
return (NULL);
break;
default:
diff --git a/src/rpc_soc.c b/src/rpc_soc.c
index 338edbb..e146ed4 100644
--- a/src/rpc_soc.c
+++ b/src/rpc_soc.c
@@ -564,16 +564,12 @@ clntunix_create(raddr, prog, vers, sockp, sendsz, recvsz)
u_int sendsz;
u_int recvsz;
{
- struct netbuf *svcaddr;
- CLIENT *cl;
+ struct netbuf svcaddr = {0, 0, NULL};
+ CLIENT *cl = NULL;
int len;
- cl = NULL;
- svcaddr = NULL;
- if (((svcaddr = malloc(sizeof(struct netbuf))) == NULL ) ||
- ((svcaddr->buf = malloc(sizeof(struct sockaddr_un))) == NULL)) {
- if (svcaddr != NULL)
- free(svcaddr);
+ memset(&svcaddr, 0, sizeof(svcaddr));
+ if (__rpc_set_netbuf(&svcaddr, raddr, sizeof(*raddr)) == NULL) {
rpc_createerr.cf_stat = RPC_SYSTEMERROR;
rpc_createerr.cf_error.re_errno = errno;
return(cl);
@@ -590,14 +586,10 @@ clntunix_create(raddr, prog, vers, sockp, sendsz, recvsz)
goto done;
}
}
- svcaddr->buf = raddr;
- svcaddr->len = sizeof(raddr);
- svcaddr->maxlen = sizeof (struct sockaddr_un);
- cl = clnt_vc_create(*sockp, svcaddr, prog,
+ cl = clnt_vc_create(*sockp, &svcaddr, prog,
vers, sendsz, recvsz);
done:
- free(svcaddr->buf);
- free(svcaddr);
+ free(svcaddr.buf);
return(cl);
}
diff --git a/src/rpcb_clnt.c b/src/rpcb_clnt.c
index a796593..f1c71a2 100644
--- a/src/rpcb_clnt.c
+++ b/src/rpcb_clnt.c
@@ -401,6 +401,44 @@ out_err:
return (client);
}
+/*
+ * Create a PMAP client handle.
+ */
+static CLIENT *
+getpmaphandle(nconf, hostname, tgtaddr)
+ const struct netconfig *nconf;
+ const char *hostname;
+ char **tgtaddr;
+{
+ CLIENT *client = NULL;
+ rpcvers_t pmapvers = 2;
+
+ /*
+ * Try UDP only - there are some portmappers out
+ * there that use UDP only.
+ */
+ if (nconf == NULL || strcmp(nconf->nc_proto, NC_TCP) == 0) {
+ struct netconfig *newnconf;
+
+ if ((newnconf = getnetconfigent("udp")) == NULL) {
+ rpc_createerr.cf_stat = RPC_UNKNOWNPROTO;
+ return NULL;
+ }
+ client = getclnthandle(hostname, newnconf, tgtaddr);
+ freenetconfigent(newnconf);
+ } else if (strcmp(nconf->nc_proto, NC_UDP) == 0) {
+ if (strcmp(nconf->nc_protofmly, NC_INET) != 0)
+ return NULL;
+ client = getclnthandle(hostname, nconf, tgtaddr);
+ }
+
+ /* Set version */
+ if (client != NULL)
+ CLNT_CONTROL(client, CLSET_VERS, (char *)&pmapvers);
+
+ return client;
+}
+
/* XXX */
#define IN4_LOCALHOST_STRING "127.0.0.1"
#define IN6_LOCALHOST_STRING "::1"
@@ -733,34 +771,20 @@ __rpcb_findaddr_timed(program, version, nconf, host, clpp, tp)
if (strcmp(nconf->nc_protofmly, NC_INET) == 0) {
u_short port = 0;
struct netbuf remote;
- rpcvers_t pmapvers = 2;
struct pmap pmapparms;
- /*
- * Try UDP only - there are some portmappers out
- * there that use UDP only.
- */
- if (strcmp(nconf->nc_proto, NC_TCP) == 0) {
- struct netconfig *newnconf;
-
- if ((newnconf = getnetconfigent("udp")) == NULL) {
- rpc_createerr.cf_stat = RPC_UNKNOWNPROTO;
- return (NULL);
- }
- client = getclnthandle(host, newnconf, &parms.r_addr);
- freenetconfigent(newnconf);
- } else if (strcmp(nconf->nc_proto, NC_UDP) == 0)
- client = getclnthandle(host, nconf, &parms.r_addr);
- else
+ if (strcmp(nconf->nc_proto, NC_UDP) != 0
+ && strcmp(nconf->nc_proto, NC_TCP) != 0)
goto try_rpcbind;
+
+ client = getpmaphandle(nconf, host, &parms.r_addr);
if (client == NULL)
return (NULL);
/*
- * Set version and retry timeout.
+ * Set retry timeout.
*/
CLNT_CONTROL(client, CLSET_RETRY_TIMEOUT, (char *)&rpcbrmttime);
- CLNT_CONTROL(client, CLSET_VERS, (char *)&pmapvers);
pmapparms.pm_prog = program;
pmapparms.pm_vers = version;
diff --git a/src/svc_vc.c b/src/svc_vc.c
index 4c70de8..4d3ea51 100644
--- a/src/svc_vc.c
+++ b/src/svc_vc.c
@@ -559,20 +559,19 @@ write_vc(xprtp, buf, len)
cd->strm_stat = XPRT_DIED;
return (-1);
}
- if (cd->nonblock && i != cnt) {
- /*
- * For non-blocking connections, do not
- * take more than 2 seconds writing the
- * data out.
- *
- * XXX 2 is an arbitrary amount.
- */
- gettimeofday(&tv1, NULL);
- if (tv1.tv_sec - tv0.tv_sec >= 2) {
- cd->strm_stat = XPRT_DIED;
- return (-1);
- }
+ /*
+ * For non-blocking connections, do not
+ * take more than 2 seconds writing the
+ * data out.
+ *
+ * XXX 2 is an arbitrary amount.
+ */
+ gettimeofday(&tv1, NULL);
+ if (tv1.tv_sec - tv0.tv_sec >= 2) {
+ cd->strm_stat = XPRT_DIED;
+ return (-1);
}
+ i = 0; /* Don't change buf and cnt */
}
}

File diff suppressed because it is too large Load Diff

View File

@ -1,8 +1,8 @@
%define _root_libdir /%{_lib}
Name: libtirpc
Version: 0.2.5
Release: 3.0%{?dist}
Version: 0.3.0
Release: 0.0%{?dist}
Summary: Transport Independent RPC Library
Group: System Environment/Libraries
License: SISSL and BSD
@ -10,8 +10,6 @@ URL: http://nfsv4.bullopensource.org/
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Source0: http://downloads.sourceforge.net/libtirpc/libtirpc-%{version}.tar.bz2
Patch001: libtirpc-0.2.6-rc3.patch
BuildRequires: automake, autoconf, libtool, pkgconfig
BuildRequires: krb5-devel
@ -41,9 +39,6 @@ developing programs which use the tirpc library.
%prep
%setup -q
rm -f INSTALL
%patch001 -p1
# Remove .orig files
find . -name "*.orig" | xargs rm -f
@ -101,15 +96,13 @@ rm -rf %{buildroot}
%{_libdir}/pkgconfig/libtirpc.pc
%{_includedir}/tirpc/netconfig.h
%{_includedir}/tirpc/rpc/auth.h
%{_includedir}/tirpc/rpc/auth_des.h
%{_includedir}/tirpc/rpc/auth_gss.h
%{_includedir}/tirpc/rpc/auth_kerb.h
%{_includedir}/tirpc/rpc/auth_unix.h
%{_includedir}/tirpc/rpc/rpcsec_gss.h
%{_includedir}/tirpc/rpc/clnt.h
%{_includedir}/tirpc/rpc/clnt_soc.h
%{_includedir}/tirpc/rpc/clnt_stat.h
%{_includedir}/tirpc/rpc/des.h
%{_includedir}/tirpc/rpc/des_crypt.h
%{_includedir}/tirpc/rpc/nettype.h
%{_includedir}/tirpc/rpc/pmap_clnt.h
%{_includedir}/tirpc/rpc/pmap_prot.h
@ -133,6 +126,9 @@ rm -rf %{buildroot}
%{_mandir}/*/*
%changelog
* Thu May 7 2015 Steve Dickson <steved@redhat.com> 0.3.0-0.0
- Updated to latest upstream release: libtirpc-0-3-3
* Thu Apr 23 2015 Steve Dickson <steved@redhat.com> 0.2.5-3.0
- Update to latest RC release: libtirpc-0-2-6-rc3

View File

@ -1 +1 @@
8cd41a5ef5a9b50d0fb6abb98af15368 libtirpc-0.2.5.tar.bz2
34b07c50e6e3fc1ca18182e9f0fd5a67 libtirpc-0.3.0.tar.bz2