associated changes that had to happen to make this possible as well as bugs fixed along the way. Bring in required TLI library routines to support this. Since we don't support TLI we've essentially copied what NetBSD has done, adding a thin layer to emulate direct the TLI calls into BSD socket calls. This is mostly from Sun's tirpc release that was made in 1994, however some fixes were backported from the 1999 release (supposedly only made available after this porting effort was underway). The submitter has agreed to continue on and bring us up to the 1999 release. Several key features are introduced with this update: Client calls are thread safe. (1999 code has server side thread safe) Updated, a more modern interface. Many userland updates were done to bring the code up to par with the recent RPC API. There is an update to the pthreads library, a function pthread_main_np() was added to emulate a function of Sun's threads library. While we're at it, bring in NetBSD's lockd, it's been far too long of a wait. New rpcbind(8) replaces portmap(8) (supporting communication over an authenticated Unix-domain socket, and by default only allowing set and unset requests over that channel). It's much more secure than the old portmapper. Umount(8), mountd(8), mount_nfs(8), nfsd(8) have also been upgraded to support TI-RPC and to support IPV6. Umount(8) is also fixed to unmount pathnames longer than 80 chars, which are currently truncated by the Kernel statfs structure. Submitted by: Martin Blapp <mb@imp.ch> Manpage review: ru Secure RPC implemented by: wpaul
84 lines
2.1 KiB
C
84 lines
2.1 KiB
C
/* $FreeBSD$ */
|
|
/*
|
|
* Copyright (c) 1986 - 1991, 1994, 1996, 1997 by Sun Microsystems, Inc.
|
|
* All rights reserved.
|
|
*/
|
|
|
|
/*
|
|
* clnt_stat.h - Client side remote procedure call enum
|
|
*
|
|
*/
|
|
|
|
#ifndef _RPC_CLNT_STAT_H
|
|
#define _RPC_CLNT_STAT_H
|
|
|
|
#pragma ident "@(#)clnt_stat.h 1.2 97/04/28 SMI"
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
enum clnt_stat {
|
|
RPC_SUCCESS = 0, /* call succeeded */
|
|
/*
|
|
* local errors
|
|
*/
|
|
RPC_CANTENCODEARGS = 1, /* can't encode arguments */
|
|
RPC_CANTDECODERES = 2, /* can't decode results */
|
|
RPC_CANTSEND = 3, /* failure in sending call */
|
|
RPC_CANTRECV = 4,
|
|
/* failure in receiving result */
|
|
RPC_TIMEDOUT = 5, /* call timed out */
|
|
RPC_INTR = 18, /* call interrupted */
|
|
RPC_UDERROR = 23, /* recv got uderr indication */
|
|
/*
|
|
* remote errors
|
|
*/
|
|
RPC_VERSMISMATCH = 6, /* rpc versions not compatible */
|
|
RPC_AUTHERROR = 7, /* authentication error */
|
|
RPC_PROGUNAVAIL = 8, /* program not available */
|
|
RPC_PROGVERSMISMATCH = 9, /* program version mismatched */
|
|
RPC_PROCUNAVAIL = 10, /* procedure unavailable */
|
|
RPC_CANTDECODEARGS = 11, /* decode arguments error */
|
|
RPC_SYSTEMERROR = 12, /* generic "other problem" */
|
|
|
|
/*
|
|
* rpc_call & clnt_create errors
|
|
*/
|
|
RPC_UNKNOWNHOST = 13, /* unknown host name */
|
|
RPC_UNKNOWNPROTO = 17, /* unknown protocol */
|
|
RPC_UNKNOWNADDR = 19, /* Remote address unknown */
|
|
RPC_NOBROADCAST = 21, /* Broadcasting not supported */
|
|
|
|
/*
|
|
* rpcbind errors
|
|
*/
|
|
RPC_RPCBFAILURE = 14, /* the pmapper failed in its call */
|
|
#define RPC_PMAPFAILURE RPC_RPCBFAILURE
|
|
RPC_PROGNOTREGISTERED = 15, /* remote program is not registered */
|
|
RPC_N2AXLATEFAILURE = 22,
|
|
/* Name to address translation failed */
|
|
/*
|
|
* Misc error in the TLI library
|
|
*/
|
|
RPC_TLIERROR = 20,
|
|
/*
|
|
* unspecified error
|
|
*/
|
|
RPC_FAILED = 16,
|
|
/*
|
|
* asynchronous errors
|
|
*/
|
|
RPC_INPROGRESS = 24,
|
|
RPC_STALERACHANDLE = 25,
|
|
RPC_CANTCONNECT = 26, /* couldn't make connection (cots) */
|
|
RPC_XPRTFAILED = 27, /* received discon from remote (cots) */
|
|
RPC_CANTCREATESTREAM = 28 /* can't push rpc module (cots) */
|
|
};
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif /* !_RPC_CLNT_STAT_H */
|