]> granicus.if.org Git - libtirpc/log
libtirpc
9 years agoRelease 0.3.0 master libtirpc-0-3-0
Steve Dickson [Wed, 6 May 2015 14:05:22 +0000 (10:05 -0400)]
Release 0.3.0

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoSymbol versioning patch libtirpc-0-2-6-rc5
Thorsten Kukuk [Wed, 6 May 2015 13:53:28 +0000 (09:53 -0400)]
Symbol versioning patch

Added the functions, which are not marked
static and for which we provide a protoype
in the public installed header files.

Additional, there is the function __libc_clntudp_bufcreate
for glibc compatibility and the three functions:
__svc_clean_idle; svc_auth_none; libtirpc_set_debug
used by rpcbind.

I have added them as "TIRPC_PRIVATE". If we want to provide them
as official functions for everybody, we should add prototypes
to the header files and move them to the TIRPC_0.3.0 section.

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoFix: unresolved _crypt() symbols
Thorsten Kukuk [Wed, 6 May 2015 13:21:52 +0000 (09:21 -0400)]
Fix: unresolved _crypt() symbols

auth_des.c is using the finctions from des_crypt.c.
So we should add this file, if we compile
auth_des.c, too.  Solves the problem with unresolved
functions cbc_crypt() and ebc_crypt().

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoconfigure.ac: Disable DES auth by default
Steve Dickson [Wed, 6 May 2015 12:07:28 +0000 (08:07 -0400)]
configure.ac: Disable DES auth by default

The DES authentication is no a supported
authentication so turn it off by default

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoMakefile.am: Removed unsupported c-files libtirpc-0-2-6-rc4
Steve Dickson [Wed, 29 Apr 2015 19:14:54 +0000 (15:14 -0400)]
Makefile.am: Removed unsupported c-files

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoauth.h: Remove unsupported routine declarations
Steve Dickson [Wed, 29 Apr 2015 19:11:33 +0000 (15:11 -0400)]
auth.h: Remove unsupported routine declarations

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoDon't link against libnsl
Thorsten Kukuk [Wed, 29 Apr 2015 16:12:32 +0000 (12:12 -0400)]
Don't link against libnsl

all source files containing references to yp_get_default_domain
are disabled in the Makefile and will never be compiled.
As long as we don't change that, we shouldn't link libtirpc against
libnsl.

Since libnsl uses RPC functions, this could lead to a dependency loop
in worst case on some systems.

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoFix xdr_rpc* defines in xdr.h
Thorsten Kukuk [Wed, 29 Apr 2015 14:03:54 +0000 (10:03 -0400)]
Fix xdr_rpc* defines in xdr.h

The defines for xdr_rpc* in xdr.h are wrong. It could be
very well that Solaris did strip the '_t' from xdr_u_int32_t,
but Solaris has a xdr_u_int32 function, we don't have this.
So all of this defines will lead to an unresolved symbol.

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agodisable *rpcent functions if they exist in libc
Thorsten Kukuk [Wed, 29 Apr 2015 13:58:06 +0000 (09:58 -0400)]
disable *rpcent functions if they exist in libc

Per default we disable getrpcbyname and getrpcbynumber, if
this functions are available in libc. But with glibc, all
*rpcent* functions are using NSS, inside tirpc only /etc/rpc.
What happens now is that getrpcbyname/getrpcbynumber can return
other results as getrpcent. This should not happen. So check for
all functions if available from libc and don't use them if this
is the case.

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoconfigure.ac: Allow for disabling auth DES
Bernhard Reutner-Fischer [Wed, 29 Apr 2015 15:11:30 +0000 (11:11 -0400)]
configure.ac: Allow for disabling auth DES

DES encryption might not be available.

Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoMake sure to include config.h
Bernhard Reutner-Fischer [Wed, 29 Apr 2015 14:57:06 +0000 (10:57 -0400)]
Make sure to include config.h

Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agogetrpcent: Fix compilation on glibc
Bernhard Reutner-Fischer [Wed, 29 Apr 2015 14:51:33 +0000 (10:51 -0400)]
getrpcent: Fix compilation on glibc

implicit declaration of function '_yp_check' [-Wimplicit-function-declaration]

Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agodelete src/config.h
Bernhard Reutner-Fischer [Wed, 29 Apr 2015 14:44:55 +0000 (10:44 -0400)]
delete src/config.h

Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoFinish server-side rpc_gss_*() APIs
Chuck Lever [Wed, 22 Apr 2015 15:04:04 +0000 (11:04 -0400)]
Finish server-side rpc_gss_*() APIs

In a previous patch, rpc_gss_set_callback(3t) was added as a
stub function.  Now, plumb in real support for callbacks.

As I understand it:

The libtirpc API consumer can register any number of callbacks.
Each callback function is invoked once when a GSS context is
established.

The callback function return value indicates whether the API
consumer wants to allow the new GSS context, or refuse it.  It can
also specify whether the client may use other qop or svc settings
for subsequent requests using this GSS context (locked).

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoExtract caller's qop setting from svcauth_gss_validate()
Chuck Lever [Wed, 22 Apr 2015 15:02:27 +0000 (11:02 -0400)]
Extract caller's qop setting from svcauth_gss_validate()

svcauth_gss_validate's caller will need to know the caller's qop in
a moment.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by Steve Dickson <steved@redhat.com>

9 years agoAdd server-side rpc_gss_*() APIs
Chuck Lever [Wed, 22 Apr 2015 15:00:35 +0000 (11:00 -0400)]
Add server-side rpc_gss_*() APIs

Introduce new RPCSEC API functions that match the same libtirpc API
in FreeBSD and Solaris.  This includes rpc_gss_getcred(3t),
rpc_gss_svc_max_data_length(3t), rpc_gss_set_svc_name(3t),
rpc_gss_set_callback(3t), and rpc_gss_get_principal_name(3t).

The man pages, written by Doug Rabson, come from FreeBSD, with
some adjustments by me.

The new code was written from scratch based on FreeBSD's
implementation, but adapted to invoke the existing legacy U-M APIs
in our implementation.  We will maintain the legacy APIs until
consumers are switched to the new ones.  FreeBSD never had the
legacy U-M API.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoRefactor authgss_refresh()
Chuck Lever [Wed, 22 Apr 2015 14:54:07 +0000 (10:54 -0400)]
Refactor authgss_refresh()

rpc_gss_seccreate() can report a rich set of information about
the newly created GSS context, if the caller provides the
"options_ret" argument.

This argument has to be available to authgss_refresh() so that
it can be filled in properly.

This appears to be the "official" way of doing what
authgss_get_private_data() does now, though I suspect it's not a
perfect match.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoAdd client-side rpc_gss_*() APIs
Chuck Lever [Wed, 22 Apr 2015 14:45:05 +0000 (10:45 -0400)]
Add client-side rpc_gss_*() APIs

Introduce new client-side RPCSEC API functions that match the same
libtirpc API in FreeBSD and Solaris. This includes
rpc_gss_seccreate(3t), rpc_gss_set_defaults(3t), and
rpc_gss_max_data_length(3t).

The man pages, written by Doug Rabson, come from FreeBSD, with
some adjustments by me.

The new code was written from scratch based on FreeBSD's
implementation, but adapted to invoke the existing legacy U-M APIs
in our implementation. We will continue to provide the legaacy APIs
until API consumers are switched to the new ones. FreeBSD never had
the legacy U-M GSS APIs.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoAdd utility rpc_gss_*() APIs
Chuck Lever [Mon, 9 Feb 2015 15:47:30 +0000 (10:47 -0500)]
Add utility rpc_gss_*() APIs

These are utility functions used by both client and server consumers
of RPCSEC GSS. The man pages, written by Doug Rabson, come from
FreeBSD, with some adjustments by me. The following functions are
added:

rpc_gss_get_error(3t), rpc_gss_get_mechanisms(3t),
rpc_gss_get_mech_info(3t), rpc_gss_get_versions(3t)
rpc_gss_is_installed(3t), rpc_gss_mech_to_oid(3t), and
rpc_gss_qop_to_num(3t)

This is a relatively simple patch, but there are a couple of
important design points to call out.

1.  Don't add a new DLL

Solaris and FreeBSD keep a dynamic library separate from libtirpc
for RPCSEC_GSS support, called librpcsec_gss. Our existing
RPCSEC_GSS support, though unfinished, is already built into our
fork of the libtirpc library. This patch continues with that
approach by adding these new functions in libtirpc instead of
introducing another library.

2.  Don't bother with /etc/gss/{mech,qop}

The Solaris gssapi implementation uses the files
/etc/gss/{mech,qop} to define supported GSS mechanisms. The
rpc_gss_*() API provides the utility functions added in this patch
so that RPC consumers can easily discover what GSS mechanisms are
available.

FreeBSD and Linux use the MIT gssapi implementation, which does not
use /etc/gss/{mech,qop} .

The FreeBSD implementation of the rpc_gss_*() API emulates support
for these configuration files, rather than invoking gssapi functions
that don't exist in the MIT gssapi library.

For Linux, I don't see a need for the extra config files:

  o  Our fork of libtirpc will support only the Kerberos GSS
     mechanism for the foreseeable future.
  o  It's easy to add another GSS mechanism in the static data
     structures, and that should be done only after thorough
     testing.
  o  It should be a simple change to add support for /etc/gss/* if
     we find we need it.
  o  Consumers of the rpc_gss_*() API ported from FreeBSD or
     Solaris should see exactly the same result when calling the
     new utility functions.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoAdd header definitions for rpc_gss_*() APIs
Chuck Lever [Mon, 9 Feb 2015 15:42:20 +0000 (10:42 -0500)]
Add header definitions for rpc_gss_*() APIs

This patch describes the API defined in Solaris and FreeBSD to
provide RPCSEC GSS support for user space TI-RPC consumers.

The header file is based on the API provided in Solaris, but was
written from scratch. The man page was written by Doug Rabson
for the FreeBSD implementation of this API, and updated by me
where needed.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoconfigure.ac: Check for features.h libtirpc-0-2-6-rc3
Bernhard Reutner-Fischer [Thu, 23 Apr 2015 15:32:19 +0000 (11:32 -0400)]
configure.ac: Check for features.h

Fixes http://sourceforge.net/p/libtirpc/bugs/34/

The netconfig header attempts to include features.h which is only
available in glibc.
This is necessary for backporting the package for FreeBSD.

Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agolibtirpc: fix prototyp
Thorsten Kukuk [Thu, 23 Apr 2015 12:44:31 +0000 (08:44 -0400)]
libtirpc: fix prototyp

gcc complains about the "simple" key_encryptsession_pk
prototype in auth_des:

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agolibtirpc: missing NULL pointer checks
Thorsten Kukuk [Thu, 23 Apr 2015 12:42:00 +0000 (08:42 -0400)]
libtirpc: missing NULL pointer checks

This patch fixes various unexpected segfaults caused by
invoking rpcb_* functions with NULL arguments.

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agorpc_broadcast: handle misformed rpcbind replies
Olaf Kirch [Thu, 23 Apr 2015 12:39:50 +0000 (08:39 -0400)]
rpc_broadcast: handle misformed rpcbind replies

Some rpcbind implementations seem to return IPv6 uaddrs
in response to an IPv4 broadcast (which is probably due
to their using a single v6 socket to handle both v6 and
v4 requests).

We can either discard these replies, or fix them up silently.
Here's a patch that implements the latter.

Signed-off-by: Olaf Kirch <okir@suse.de>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agolibtirpc: fix bootstrap script/libtool
Thorsten Kukuk [Thu, 23 Apr 2015 12:34:25 +0000 (08:34 -0400)]
libtirpc: fix bootstrap script/libtool

The bootstrap script in the libtirpc directory currently doesn't
work because it doesn't setup libtool. This leads to a for me non
working configure script and missing Makefile.in

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoAdd a HACKING file which tells where to send patches
Natanael Copa [Wed, 22 Apr 2015 18:52:29 +0000 (14:52 -0400)]
Add a HACKING file which tells where to send patches

Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoFix location of various standard header includes
Natanael Copa [Wed, 22 Apr 2015 18:50:27 +0000 (14:50 -0400)]
Fix location of various standard header includes

poll.h, signal.h, errno.h and fcntl.h are all defined in POSIX
and their location are not under sys/

This fixes various compile warning when building with musl libc like:

In file included from clnt_dg.c:40:0:
/usr/include/sys/poll.h:1:2: warning: #warning redirecting
incorrect #include <sys/poll.h> to <poll.h> [-Wcpp]

In file included from clnt_generic.c:32:0:
/usr/include/sys/fcntl.h:1:2: warning: #warning redirecting
incorrect #include <sys/fcntl.h> to <fcntl.h> [-Wcpp]

In file included from auth_time.c:34:0:
/usr/include/sys/signal.h:1:2: warning: #warning redirecting
incorrect #include <sys/signal.h> to <signal.h> [-Wcpp]

In file included from auth_time.c:35:0:
/usr/include/sys/errno.h:1:2: warning: #warning redirecting
incorrect #include <sys/errno.h> to <errno.h> [-Wcpp]

Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoInclude string.h for memset
Natanael Copa [Wed, 22 Apr 2015 18:48:03 +0000 (14:48 -0400)]
Include string.h for memset

This fixes warning: implicit declaration of function 'memset'

Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoAvoid use of internal glibc sys/cdefs.h header
Natanael Copa [Wed, 22 Apr 2015 18:43:52 +0000 (14:43 -0400)]
Avoid use of internal glibc sys/cdefs.h header

This header was never intended to be used by programs.

Expand the macros used, __BEGIN_CDECLS, __END_CDECLS and __P()

The __THROW macro is a non-portable hint for optimization so we simply
remove those.

Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoFix compile error: 'IPPORT_RESERVED' undeclared
Natanael Copa [Wed, 22 Apr 2015 16:26:14 +0000 (12:26 -0400)]
Fix compile error: 'IPPORT_RESERVED' undeclared

The IPPORT_RESERVED is declared in netdb.h. This fixes the following
compile error with musl libc:

bindresvport.c: In function 'bindresvport_sa':
bindresvport.c:67:18: error: 'IPPORT_RESERVED' undeclared (first use in
this function)
 #define ENDPORT (IPPORT_RESERVED - 1)
                   ^
Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoAdd configure option to disable DES authentication
Natanael Copa [Wed, 22 Apr 2015 16:23:57 +0000 (12:23 -0400)]
Add configure option to disable DES authentication

DES is not good for encryption anymore and some C libraries does not
even implement it. We add a --disable-authdes to optionally disable
it, but let it be enabled by default for compatibility.

This is needed for musl libc.

Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoProvide getrpcbynumber and getrpcbyname if those are missing
Natanael Copa [Wed, 22 Apr 2015 16:17:33 +0000 (12:17 -0400)]
Provide getrpcbynumber and getrpcbyname if those are missing

We enable the config.h again and check if getrpcbynumber and
getrpcbyname exists on the building patform. If it does not exist, then
provide those functions.

This is needed for musl libc.

Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoReplace INSTALL symlink with a copy of the file
Natanael Copa [Wed, 22 Apr 2015 15:38:52 +0000 (11:38 -0400)]
Replace INSTALL symlink with a copy of the file

The INSTALL symlink is broken when automake version does not match.
We fix this by using a copy of the file instead of a symlink.

Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agolibtirpc: fix crash with tuntap devices libtirpc-0-2-6-rc2
Olaf Kirch [Tue, 16 Dec 2014 19:02:39 +0000 (14:02 -0500)]
libtirpc: fix crash with tuntap devices

Linux tuntap devices and other virtual network devices, if not
configured, will be reported by getifaddrs() with a NULL ifa_addr
pointer. __rpc_getifaddrs would trip over that, because it derefenced
the ifa_addr pointer without checking.

Signed-off-by: Olaf Kirch <okir@suse.de>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agotirpc: fix taddr2uaddr for AF_LOCAL
Thorsten Kukuk [Tue, 16 Dec 2014 19:00:12 +0000 (14:00 -0500)]
tirpc: fix taddr2uaddr for AF_LOCAL

taddr2uaddr would return trailing garbage for AF_LOCAL addresses

taddr2uaddr assumed that the sun_path field of an AF_LOCAL address
was always NULL terminated, but that is not necessarily the case,
especially if the buffer was allocated using the correct SUN_LEN().

Signed-off-by: Olaf Kirch <okir@suse.de>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoFix a crash in clntunix_create
Olaf Kirch [Tue, 16 Dec 2014 18:48:52 +0000 (13:48 -0500)]
Fix a crash in clntunix_create

Programs using clntunix_create would abort because glibc detected an
attempt to free a bad pointer. It turns out that clntunix_create
has two bugs:

 - it sets up a struct netbuf to hold the sockaddr_un passed
into the function, but instead of copying the data, it
just assigns the sockaddr pointer - and eventually tries to
free that pointer.

 - when setting up the netbuf, it uses sizeof(raddr) instead
of sizeof(*raddr).

Instead of doing the trivial fixes, I changed the function to use
the __rpc_set_netbuf utility function. While I was at it, I removed
an unused local variable.

Signed-off-by: Olaf Kirch <okir@suse.de>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoIntroduce new helper function getpmaphandle
Olaf Kirch [Tue, 16 Dec 2014 18:43:30 +0000 (13:43 -0500)]
Introduce new helper function getpmaphandle

This moves some code for creation of PMAP handles out of the getaddr
code and into a function of its own.

Signed-off-by: Olaf Kirch <okir@suse.de>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoFix a bug in clnt broadcast
Olaf Kirch [Tue, 16 Dec 2014 18:38:33 +0000 (13:38 -0500)]
Fix a bug in clnt broadcast

Before calling the replyproc function on a broadcast reply,
we convert the server-provided address using uaddr2taddr.
This may fail (eg if the server provided a garbage address),
and return NULL. In this case, we should not call the replyproc
function - because the caller expects the address netbuf to
be a valid pointer, rather than NULL.

Signed-off-by: Olaf Kirch <okir@suse.de>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agopkg-config: needs pthread as private library
Yann E. MORIN [Sat, 13 Dec 2014 14:38:54 +0000 (09:38 -0500)]
pkg-config: needs pthread as private library

libtirpc needs pthreads. This is automatically pulled in when linking
with the shared library, thanks to the DT_NEEDED ELF tags.

But for a static library, there is no such mechanism to identify
required libraries.

Thus, add -lpthread to the private libraries in the pkg-config file.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agowrite_vc: fix write retry loop for nonblocking mode libtirpc-0-2-6-rc1
Bodo Stroesser [Thu, 6 Nov 2014 18:26:00 +0000 (13:26 -0500)]
write_vc: fix write retry loop for nonblocking mode

This is a simple fix for the write retry loop that is used on
non-blocking connections if write() failed with -EAGAIN.

Additionally it removes a redundant if () {}

Erroneously at each cycle of the loop the length of the data
to send is incremented and the buffer pointer is decremented.
Thus, it might happen that:
* the application crashes
* data from the memory before the buffer is sent

Signed-off-by: Bodo Stroesser <bstroesser@ts.fujitsu.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agolibtirpc: include stdarg.h when used
Mike Frysinger [Tue, 12 Aug 2014 14:50:34 +0000 (10:50 -0400)]
libtirpc: include stdarg.h when used

The debug.h header uses va_list but doesn't include stdarg.h which
can lead to random build failures.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoSet the initial value of libtirpc_debug_level to zero libtirpc-0-2-5-rc4
Steve Dickson [Fri, 8 Aug 2014 16:03:54 +0000 (12:03 -0400)]
Set the initial value of libtirpc_debug_level to zero

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoauth_des: Converted some of the debugging syslog calls to LIBTIRPC_DEBUG() calls
Steve Dickson [Mon, 14 Jul 2014 16:55:12 +0000 (12:55 -0400)]
auth_des: Converted some of the debugging syslog calls to LIBTIRPC_DEBUG() calls

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agosvc_dg: Convert fprintf calls to LIBTIRPC_DEBUG() calls
Steve Dickson [Mon, 14 Jul 2014 16:46:19 +0000 (12:46 -0400)]
svc_dg: Convert fprintf calls to LIBTIRPC_DEBUG() calls

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agorpcb_clnt: Convert fprintf calls to LIBTIRPC_DEBUG() calls
Steve Dickson [Mon, 14 Jul 2014 16:34:14 +0000 (12:34 -0400)]
rpcb_clnt: Convert fprintf calls to LIBTIRPC_DEBUG() calls

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoclnt_bcast: Convert local debug() calls to LIBTIRPC_DEBUG() calls
Steve Dickson [Mon, 14 Jul 2014 16:10:09 +0000 (12:10 -0400)]
clnt_bcast: Convert local debug() calls to LIBTIRPC_DEBUG() calls

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agokey_call: Convert local debug() calls to LIBTIRPC_DEBUG() calls
Steve Dickson [Mon, 14 Jul 2014 14:46:00 +0000 (10:46 -0400)]
key_call: Convert local debug() calls to LIBTIRPC_DEBUG() calls

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agosvcauth_des: Convert local debug() calls to LIBTIRPC_DEBUG() calls
Steve Dickson [Mon, 14 Jul 2014 14:42:22 +0000 (10:42 -0400)]
svcauth_des: Convert local debug() calls to LIBTIRPC_DEBUG() calls

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoClean up: Remove newlines from a couple debugging calls.
Steve Dickson [Mon, 14 Jul 2014 13:40:14 +0000 (09:40 -0400)]
Clean up: Remove newlines from a couple debugging calls.

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoprint_rpc_gss_sec: Make sure logging to stderr is enabled.
Steve Dickson [Mon, 14 Jul 2014 13:21:11 +0000 (09:21 -0400)]
print_rpc_gss_sec: Make sure logging to stderr is enabled.

It does not make sense to try an covert this routine to
used the new debugging macro. So just insure the correct
debugging level and printing to stderr is enabled.

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agogss_log: Replace gss_log_debug with LIBTIRPC_DEBUG macros
Steve Dickson [Mon, 14 Jul 2014 13:02:10 +0000 (09:02 -0400)]
gss_log: Replace gss_log_debug with LIBTIRPC_DEBUG macros

A couple gss_log_debug() calls are reporting errors.
To allow errors to be logged with the least amount
of debugging on, replace those calls the LIBTIRPC_DEBUG
macro

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agolibtirpc_debug: Converted the rest of the #ifdef DEBUGs
Steve Dickson [Mon, 14 Jul 2014 12:46:12 +0000 (08:46 -0400)]
libtirpc_debug: Converted the rest of the #ifdef DEBUGs

Replace the rest of the fprintf(stderr) surrounded
by ifdef DEBUGS with the LIBTIRPC_DEBUG macro

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agogit_log_status: Add function name to status message
Steve Dickson [Mon, 14 Jul 2014 12:19:17 +0000 (08:19 -0400)]
git_log_status: Add function name to status message

Added the function name to the status message to
identify where the status is coming from.

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agogss_log_status: reformat output to use one line.
Steve Dickson [Mon, 14 Jul 2014 11:54:00 +0000 (07:54 -0400)]
gss_log_status: reformat output to use one line.

With the new LIBTIRPC_DEBUG() macros a new-line
is appended on each output buffer. So concatenate
gss_log_status()'s output into one buffer.

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agogss_log: Removed DEBUG defines
Steve Dickson [Mon, 14 Jul 2014 11:50:04 +0000 (07:50 -0400)]
gss_log: Removed DEBUG defines

Enable the gss_log_XXX routines by remove the
ifdef DEBUGs that surround them.

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agogss_log: Convert existing gss debugging routines
Steve Dickson [Mon, 14 Jul 2014 11:20:35 +0000 (07:20 -0400)]
gss_log: Convert existing gss debugging routines

Convert the gss_log_XXX routines to used the
new LIBTIRPC_DEBUG() macros.

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agolibtirpc: New configurable debugging routines
Steve Dickson [Mon, 14 Jul 2014 17:05:35 +0000 (13:05 -0400)]
libtirpc: New configurable debugging routines

This patch added new configurable debugging interface that
will allow existing debugging statements to be enabled
and disabled by the calling application.

    libtirpc_set_debug(char *name, int level, int use_stderr)

       * This called by the application to set the debugging level.
         If use_stderr is set, all message will go to stderr,
         otherwise syslog() will be used.

    LIBTIRPC_DEBUG(level, msg)
        * This is the macro called by functions within the library.

    libtirpc_log_dbg(char *fmt, ...)
        * This is the routine the LIBTIRPC_DEBUG macro uses to
          log the messages and can be called directly by internal
          routines

    vlibtirpc_log_dbg(int level, const char *fmt, va_list args)
        * This routine is used by existing debugging routines
          that have already obtained their arguments using
          stdarg(3) macros.

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoxdr_rejected_reply: Don't crash with invalid server rejection
Steve Dickson [Thu, 5 Jun 2014 13:40:23 +0000 (09:40 -0400)]
xdr_rejected_reply: Don't crash with invalid server rejection

It seems legacy servers like to return invalid
rejection status when a RPC is rejected. This
should not crash the app then it happens.

Signed-off-by: Steve Dickson <steved@redhat.com>
9 years agoAvoid buffer overruns by allocating buffer in svcauth_gss_validate() libtirpc-0-2-5-rc3
Steve Dickson [Thu, 29 May 2014 13:40:59 +0000 (09:40 -0400)]
Avoid buffer overruns by allocating buffer in svcauth_gss_validate()

Reviewed-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoPre-register server side RPCSEC GSS support libtirpc-0-2-5-rc2
Chuck Lever [Wed, 9 Apr 2014 18:00:56 +0000 (14:00 -0400)]
Pre-register server side RPCSEC GSS support

When --enable-gss is specified on the ./configure command line,
have the library automatically register server-side support for the
RPCSEC_GSS auth flavor.

The complication is that specific interaction is required with the
RPC client if GSS authentication fails. GSS authentication sometimes
has to squelch the normal reply done by svc_getreq(), and substitute
its own.

_svcauth_gss() already has a boolean argument to do this.  But
_authenticate() is an official API (see rpc/svc_auth.h). We can't
alter its synopsis.

Instead of adding a "no_dispatch" argument to our existing
_authenticate() API, preserve its synopsis for backwards
compatibility, and introduce a second external authentication API
for the dispatcher.

This matches a similar API change done in the Solaris libtirpc.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoman: Replace outdated Solaris and BSD references in the man pages libtirpc-0-2-5-rc1
Chuck Lever [Thu, 23 Jan 2014 16:26:21 +0000 (11:26 -0500)]
man: Replace outdated Solaris and BSD references in the man pages

The .Lb macro in these man pages lists "libc" as the containing
library, which is not correct for Linux.

However, our .Lb macro does not appear to support the value
"libtirpc."  List the containing library in an AVAILABILITY section instead.

Lastly, remove references to man pages that do not exist on Linux.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoman: Organize man/Makefile.am
Chuck Lever [Thu, 23 Jan 2014 16:24:24 +0000 (11:24 -0500)]
man: Organize man/Makefile.am

Clean up man/Makefile.

Document man pages we maintain upstream but that are typically not
installed by distributions.

Finally, restore the man page which describes the libtirpc rpcbind
client API.  This includes rpcb_getmaps(3t), rpcb_getaddr(3t),
rpcb_gettime(3t), rpcb_rmtcall(3t), rpcb_set(3t), and
rpcb_unset(3t).

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoClean up forward declarations in src/svc_auth_gss.c
Chuck Lever [Thu, 23 Jan 2014 16:21:29 +0000 (11:21 -0500)]
Clean up forward declarations in src/svc_auth_gss.c

Address some sparse complaints

Bring the forward declarations for the auth_ops defined in
svc_auth_gss.c up to recent C standards.  These should match the
function prototypes used to declare the auth_ops structure.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoClean up forward declarations in src/auth_gss.c
Chuck Lever [Thu, 23 Jan 2014 16:19:55 +0000 (11:19 -0500)]
Clean up forward declarations in src/auth_gss.c

Address some sparse complaints

Bring the forward declarations for the auth_ops defined in auth_gss.c
up to recent C standards.  These should match the function prototypes
used to declare the auth_ops structure.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoAdd a pthread key initializer constant
Chuck Lever [Thu, 23 Jan 2014 16:17:09 +0000 (11:17 -0500)]
Add a pthread key initializer constant

Clean up: replace the naked "-1" with a symbolic constant that helps
document what is going on.  The name matches the name of the other
pthread initializer constants.

Also, since pthread_key_t is an unsigned integer, use a type cast to
eliminate the implicit cast that occurs every time foo_key is
compared to -1.  This eliminates a number of compiler warnings.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoconfigure: permanently enable maintainer mode
Chuck Lever [Thu, 23 Jan 2014 16:13:51 +0000 (11:13 -0500)]
configure: permanently enable maintainer mode

I noticed that "make" doesn't run configure again when a patch is
applied that changes the build environment.  Maintainer mode appears
to be disabled by default.

Section 27.2 of the Automake manual suggests that disabling
Maintainer Mode causes unreliable builds because it removes the
guarantee that the build environment is up to date.

Remove the configure.ac macro to disable or enable maintainer mode.
This leaves Maintainer Mode enabled all the time.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoRelease 0.2.4 libtirpc-0-2-4
Steve Dickson [Mon, 9 Dec 2013 20:59:51 +0000 (15:59 -0500)]
Release 0.2.4

Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoClean up src/rpcb_clnt.c
Chuck Lever [Mon, 9 Dec 2013 20:54:54 +0000 (15:54 -0500)]
Clean up src/rpcb_clnt.c

Remove some unused code.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoUpdate "make clean" and "make distclean" targets
Chuck Lever [Mon, 9 Dec 2013 20:50:35 +0000 (15:50 -0500)]
Update "make clean" and "make distclean" targets

Get rid of cscope and editor turds as well as intermediate
Makefiles.  The top level Makefile should remove old tarballs.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoUpdate .gitignore
Chuck Lever [Mon, 9 Dec 2013 20:46:59 +0000 (15:46 -0500)]
Update .gitignore

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoUse stock automake rules to install netconfig
Chuck Lever [Mon, 9 Dec 2013 20:46:08 +0000 (15:46 -0500)]
Use stock automake rules to install netconfig

Following guidelines in section 27.10 of the Automake manual,
with some help from section 9.3.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoconfigure.ac: Remove gssglue configuration knobs
Steve Dickson [Mon, 9 Dec 2013 19:57:13 +0000 (14:57 -0500)]
configure.ac: Remove gssglue configuration knobs

Its really not a good idea for libtirpc to link with
libgssglue so this patch remove the ability to do that.

Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoconfigure.ac: enable the GSSAPI by default
Steve Dickson [Mon, 9 Dec 2013 18:24:06 +0000 (13:24 -0500)]
configure.ac: enable the GSSAPI by default

This changes GSSAPI support to be enabled by default.
To disable the support use --disable-gssapi

Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoFix "make dist" and "make distcheck"
Chuck Lever [Mon, 9 Dec 2013 17:59:51 +0000 (12:59 -0500)]
Fix "make dist" and "make distcheck"

The "dist" target gives us a libtirpc.tar.gz tarball for
distribution.

The "distcheck" target is a useful test of libtirpc's Makefile
infrastructure.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agolibtirpc: remove tirpc/fpmath.h
Chuck Lever [Mon, 9 Dec 2013 17:02:41 +0000 (12:02 -0500)]
libtirpc: remove tirpc/fpmath.h

No libtirpc source files include this header, so remove it.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agolibtirpc: remove tirpc/nss_tls.h
Chuck Lever [Mon, 9 Dec 2013 16:59:49 +0000 (11:59 -0500)]
libtirpc: remove tirpc/nss_tls.h

No libtirpc source files include this header, so remove it.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agolibtirpc: remove tirpc/spinlock.h
Chuck Lever [Mon, 9 Dec 2013 16:54:22 +0000 (11:54 -0500)]
libtirpc: remove tirpc/spinlock.h

No libtirpc source files include this header, so remove it.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agolibtirpc: remove tirpc/misc/event.h
Chuck Lever [Mon, 9 Dec 2013 16:48:47 +0000 (11:48 -0500)]
libtirpc: remove tirpc/misc/event.h

No libtirpc source file includes this header, so remove it.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agolibtirpc: remove tirpc/misc/socket.h
Chuck Lever [Mon, 9 Dec 2013 16:47:15 +0000 (11:47 -0500)]
libtirpc: remove tirpc/misc/socket.h

No libtirpc source files include this header, so remove it.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agolibtirpc: remove tirpc/misc/queue.h
Chuck Lever [Mon, 9 Dec 2013 16:45:39 +0000 (11:45 -0500)]
libtirpc: remove tirpc/misc/queue.h

The contents of this header are unneeded on Linux, so remove the header.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agolibtirpc: remove tirpc/namespace.h
Chuck Lever [Mon, 9 Dec 2013 16:42:01 +0000 (11:42 -0500)]
libtirpc: remove tirpc/namespace.h

This header is empty, so remove it.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agobuild: set enable-silent-rules to be on by default
Steve Dickson [Mon, 9 Dec 2013 16:34:00 +0000 (11:34 -0500)]
build: set enable-silent-rules to be on by default

To disable the build from using silent rulues, use:
   ./configure --disable-silent-rules

Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agobuild: Make compiler warnings easier to see
Chuck Lever [Mon, 9 Dec 2013 16:27:38 +0000 (11:27 -0500)]
build: Make compiler warnings easier to see

Enable quiet building to make compiler and linker warnings easier to
see.  After this patch, with "make -s" we get:

  ...

Making all in src
  CC       libtirpc_la-auth_none.lo
  CC       libtirpc_la-auth_unix.lo

  ...

making warnings stand out clearly.

Enable this behavior via:

  ./configure --enable-silent-rules

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoglibc rpcgen compatibility
Chuck Lever [Mon, 9 Dec 2013 16:17:50 +0000 (11:17 -0500)]
glibc rpcgen compatibility

xdr_quad_t() and xdr_u_quad_t() call sites are generated by glibc's
rpcgen, which uses them to marshal 64-bit integers.

Since we want libtirpc to maintain glibc compatibility, introduce
xdr_quad_t() and xdr_u_quad_t() to libtirpc.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoAdd compatibility XDR functions for unsigned integers
Chuck Lever [Mon, 9 Dec 2013 16:15:42 +0000 (11:15 -0500)]
Add compatibility XDR functions for unsigned integers

For compatibility with glibc and Solaris, add synonyms for the
existing XDR functions that handle sized unsigned integers.

Note that the NFSv4 protocol specifications define the protocol in
terms of "uint32" and "uint64" rather than using the "u_int"
versions.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoAdd xdr_int8_t() and xdr_u_int8_t()
Chuck Lever [Mon, 9 Dec 2013 16:13:03 +0000 (11:13 -0500)]
Add xdr_int8_t() and xdr_u_int8_t()

The legacy RPC implementation in glibc has XDR functions for 8-bit
integers.  For glibc compatibility, introduce similar functions in
libtirpc.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoRace in Race in clnt_vc_create libtirpc-0-2-4-rc3
Signed-off-by: Susant Sahani [Mon, 25 Nov 2013 19:09:04 +0000 (14:09 -0500)]
Race in Race in clnt_vc_create

 The function clnt_create is *not* thread safe. Race conditions in the
function clnt_vc_create that accesses static data disrupt, which is
*not* protected by any mutex. When more than one thread access it
it has become a nonlocal side effect . This race conditions can lead to
undesired behaviour . By introducing the mutex disrupt_lock
the function clnt_vc_create is serialized

Signed-off-by: Susant Sahani <ssahani@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoRace condition in bindresvport
Signed-off-by: Susant Sahani [Mon, 25 Nov 2013 18:53:28 +0000 (13:53 -0500)]
Race condition in bindresvport

 The function clnt_create is *not* thread safe . Race conditions in
the function bindresvport that accesses static data port and startport,
which are *not* protected by any mutex. When more than one thread
access them the variables become a nonlocal side effect. These race
conditions
can lead to undesired behaviour . By introducing the mutex port_lock
the function bindresvport is serialized.

Signed-off-by: Susant Sahani <ssahani@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoRace conditions in getnetconfig
Signed-off-by: Susant Sahani [Mon, 25 Nov 2013 18:48:32 +0000 (13:48 -0500)]
Race conditions in getnetconfig

The clnt_* functions are *not* thread safe. Race conditions are caused
by the functions setnetconfig , getnetconfig, endnetconfig and
getnetconfigent that accesses global static data nc_file and ni which
are defined in the file getnetconfig are *not* protected by any mutex.
When more than one thread access them the variables become a nonlocal
side effect . These race conditions causing process to give undesired
behavior and leading to crash on file operations mostly on fclose. By
introducing the mutex nc_db_lock the netconfig database is synchronized
and prevented from crash.

Signed-off-by: Susant Sahani <ssahani@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years ago__nc_error() does not check return value from malloc
Signed-off-by: Susant Sahani [Fri, 22 Nov 2013 15:53:41 +0000 (10:53 -0500)]
__nc_error() does not check return value from malloc

Signed-off-by: Susant Sahani <ssahani@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agobuild: fix for automake>=1.13 libtirpc-0-2-4-rc2
Tom Gundersen [Mon, 1 Jul 2013 13:55:35 +0000 (09:55 -0400)]
build: fix for automake>=1.13

Also fix a couple of related deprecation warnings.

Signed-off-by: Tom Gundersen <teg@jklm.no>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoRemove variadic macro invocation
Chuck Lever [Mon, 1 Jul 2013 13:40:02 +0000 (09:40 -0400)]
Remove variadic macro invocation

Commit f8104ba9 "Fix debugging reference from non-GSS to optional"
GSS code.", Thu Apr 26 15:12:08 2012, introduces a variadic macro
invocation (a GNU C extension) in the rpc/auth.h header.

An attempt was made to hide the extension behind #ifdef __GNUC__
but the #else arm also uses the same synopsis, so the variadic macro
is visible for non-GNU C compiles as well.

With gcc (GCC) 4.7.2 20121109 (Red Hat 4.7.2-8) on Fedora 18, I
see:

/usr/include/tirpc/rpc/auth.h:255:32: warning: ISO C does not permit
  named variadic macros [-Wvariadic-macros]

I imagine this warning is produced by the "-pedantic" gcc option,
which I use in various projects that depend on libtirpc headers.

Rather than further cluttering the code in auth.h, we can live
without this debugging message.

Cc: Nick Alcock <nick.alcock@oracle.com>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
10 years agoclnt_vc_control: fix VERS/PROG size
Jan Stancek [Tue, 28 May 2013 17:45:43 +0000 (13:45 -0400)]
clnt_vc_control: fix VERS/PROG size

Commit fac3eb51 converted some operations to use memcpy, but the size
of copied areas is now u_long, previously it was u_int32_t.

This broke mount on ppc64/s390x:
  # ./mount.nfs -vvv -onfsvers=3,tcp rhel6-nfs:/export/home /mnt/test
  mount.nfs: timeout set for Fri May  3 15:20:14 2013
  mount.nfs: trying text-based options 'nfsvers=3,tcp,addr=10.1.1.5'
  mount.nfs: prog 100003, trying vers=3, prot=6
  mount.nfs: portmap query failed: RPC: Program/version mismatch
  mount.nfs: Protocol not supported

Signed-off-by: Jan Stancek <jstancek@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
11 years agosvc_getargs(): Should not be freeing arg pointers on failures libtirpc-0-2-4-rc1
Steve Dickson [Thu, 18 Apr 2013 18:29:58 +0000 (14:29 -0400)]
svc_getargs(): Should not be freeing arg pointers on failures

commit 82cc2e61 (SVCAUTH_WRAP/SVCAUTH_UNWRAP) introduce a regression
that causes callers of svc_getargs() to crash when svc_freeargs() frees
args points that are allocated on the stack.

svc_getargs() should let the callers do the freeing and not make any
assumptions on the type of memory passed in.

Also see:
    https://bugzilla.redhat.com/show_bug.cgi?id=948378
and
    CVE-2013-1950 EMBARGOED rpcbind: invalid pointer free leads to crash

Signed-off-by: Steve Dickson <steved@redhat.com>
11 years agogss: Fix private data giveaway
Simo Sorce [Wed, 10 Apr 2013 15:38:14 +0000 (11:38 -0400)]
gss: Fix private data giveaway

When the private data is given away the gss context also needs to go,
because the caller may destroy it, such as when the context is exported
into a lucid context to hand it to the kernel.

Signed-off-by: Simo Sorce <simo@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
11 years agoSwitch to use standard GSSAPI by default
Simo Sorce [Tue, 26 Mar 2013 15:13:05 +0000 (11:13 -0400)]
Switch to use standard GSSAPI by default

Make libgssglue configurable still but disabled by default.
There is no reason to use libgssglue anymore, and modern gssapi
supports all needed features for libtirpc and its dependencies.

Signed-off-by: Steve Dickson <steved@redhat.com>
11 years agoRevert "Include crypt_client in build" libtirpc-0-2-3
Steve Dickson [Wed, 13 Feb 2013 15:13:59 +0000 (10:13 -0500)]
Revert "Include crypt_client in build"

This reverts commit 26a263169 due to xdr_desresp()
and des_crypt_1() not being defined

Signed-off-by: Steve Dickson <steved@redhat.com>
11 years agoRelease 0.2.3
Steve Dickson [Tue, 12 Feb 2013 19:31:54 +0000 (14:31 -0500)]
Release 0.2.3

Signed-off-by: Steve Dickson <steved@redhat.com>
11 years agoclnt_vc_control: Removed a strict-aliasing warning
Steve Dickson [Tue, 12 Feb 2013 19:26:31 +0000 (14:26 -0500)]
clnt_vc_control: Removed a strict-aliasing warning

clnt_vc.c:587:7: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
clnt_vc.c:593:7: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
clnt_vc.c:605:7: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
clnt_vc.c:611:7: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]

Signed-off-by: Steve Dickson <steved@redhat.com>
11 years agoclnt_dg_call: Removed a unused-but-set-variable warning
Steve Dickson [Tue, 12 Feb 2013 18:51:42 +0000 (13:51 -0500)]
clnt_dg_call: Removed a unused-but-set-variable warning

clnt_dg.c:312:12: warning: variable 'inlen' set but not used
[-Wunused-but-set-variable]

Signed-off-by: Steve Dickson <steved@redhat.com>