summaryrefslogtreecommitdiffstats
path: root/lib/libc/rpc
Commit message (Collapse)AuthorAgeFilesLines
* mdoc(7) police: consistently use the .Ux macro.ru2001-11-201-4/+4
|
* s/kernal/kernelalfred2001-10-192-2/+2
|
* Add compatibility functions for the AF_LOCAL RPC transport stuffwpaul2001-10-043-0/+235
| | | | | that used to live in RPC 4.0. This is needed for yppasswd and rpc.yppasswdd to work correctly. Patch supplied by Martin Blapp.
* Hopefully improve control message passing over Unix domain sockets.dwmalone2001-10-042-14/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1) Allow the sending of more than one control message at a time over a unix domain socket. This should cover the PR 29499. 2) This requires that unp_{ex,in}ternalize and unp_scan understand mbufs with more than one control message at a time. 3) Internalize and externalize used to work on the mbuf in-place. This made life quite complicated and the code for sizeof(int) < sizeof(file *) could end up doing the wrong thing. The patch always create a new mbuf/cluster now. This resulted in the change of the prototype for the domain externalise function. 4) You can now send SCM_TIMESTAMP messages. 5) Always use CMSG_DATA(cm) to determine the start where the data in unp_{ex,in}ternalize. It was using ((struct cmsghdr *)cm + 1) in some places, which gives the wrong alignment on the alpha. (NetBSD made this fix some time ago). This results in an ABI change for discriptor passing and creds passing on the alpha. (Probably on the IA64 and Spare ports too). 6) Fix userland programs to use CMSG_* macros too. 7) Be more careful about freeing mbufs containing (file *)s. This is made possible by the prototype change of externalise. PR: 29499 MFC after: 6 weeks
* Fixed bitrot in synopsis. The TI-RPC changes gave mounds of it, mainlybde2001-10-0310-31/+33
| | | | | inconsistently weird const poisoning in the man pages relative to the headers.
* mdoc(7) police: Use the new .In macro for #include statements.ru2001-10-0119-24/+24
|
* Fixed namespace pollution related to `warn' in libc (but not in otherbde2001-08-291-1/+1
| | | | | | libraries or for other members of the err() family). This fixes world breakage in bc and rcs/* for NOSHARED worlds.
* Handle snrintf() returning -1.brian2001-08-201-16/+30
| | | | MFC after: 2 weeks
* mdoc(7) police: join split punctuation to macro calls.ru2001-08-101-2/+2
|
* In getclnthandle(), if the address is found in the cache we neediedowse2001-08-021-2/+5
| | | | | | | | | | to strdup() the address string before returning it via *targaddr because the caller will free the string. Change the comment at the top of getclnthandle() to clarify that the caller is responsible for freeing *targaddr. Noticed by: sobomax
* Finish the sweep of changes that fix doubled 'the'.sheldonh2001-07-241-1/+1
|
* Remove whitespace at EOL.dd2001-07-154-5/+5
|
* Fix a memory leak in __rpcb_findaddr(), avoid compiler warnings.iedowse2001-07-141-1/+4
| | | | Submitted by: Martin Blapp <mb@imp.ch>
* mdoc(7) police: sort SEE ALSO xrefs (sort -b -f +2 -3 +1 -2).ru2001-07-062-2/+2
|
* mdoc(7) police: sort xrefs.ru2001-07-041-2/+2
|
* Remove duplicate words.dd2001-06-242-2/+2
|
* Add a new clnt_control() request `CLSET_CONNECT' that controlsiedowse2001-06-232-4/+27
| | | | | | | | | | whether or not connect(2) is used for UDP client sockets. The default is not to connect(), so existing clients will see no change in behaviour. The use of connect(2) for UDP clients has a number of advantages: only replies from the intended address are received, and ICMP errors pertaining to the connection are reported back to the application.
* Fix typo: clnt_destroy() only takes one arg.mikeh2001-06-181-1/+1
| | | | MFC after: 2 weeks
* Correct cross-reference:sobomax2001-06-071-15/+15
| | | | | | portmap.8 --> rpcbind.8 Submitted by: .Xr testing script
* Fix cross-references:sobomax2001-06-051-2/+2
| | | | | | | | ipnat.8 --> ipnat.1 environ.5 --> environ.7 isssetugid.2 --> issetugid.2 MFC after: 1 week
* Copy the sockaddr from the netbuf data area, not from the netbufiedowse2001-06-011-1/+1
| | | | | | | | data pointer. This bug has been here since the ti-rpc import; it apparently broke the clnt_control CLGET_SVC_ADDR options. PR: misc/27813 Submitted by: Jean-Luc Richier <Jean-Luc.Richier@imag.fr>
* The function clnt_dg_call(), which is used for UDP RPC calls, couldiedowse2001-05-181-4/+2
| | | | | | | | | accidentally clobber the server address if a stray packet arrived at the client port. This would result in any further retransmits going to the wrong address. For now, fix this by not saving the source address of the reply; this matches the pre-tirpc behaviour.
* Extract the path from an AF_LOCAL sockaddr_un in a way that correctlyiedowse2001-05-121-2/+5
| | | | | | | | | | | terminates the string in all cases, based on code from netstat(1). The path in a sockaddr_un is terminated either by a '\0', or by the end of the sockaddr as defined by sun_len. Previously, the code could write the "safety" '\0' beyond the end of the sockaddr (sockaddr_un's need only be large enough to store sun_len bytes), and writing into the the supplied sockaddr is bad anyway.
* The function __rpc_uaddr2taddr_af() converts an RPC "universaliedowse2001-04-261-0/+2
| | | | | | | | | address" string to a netbuf/sockaddr "transport address". In the case of an AF_LOCAL address, it was missing the code to actually point the netbuf at the newly allocated sockaddr_un, so the caller ended up with a netbuf containing junk. Submitted by: Martin Blapp <mb@imp.ch>
* The maximum RPC message size was set at 8k for UDP. This is loweriedowse2001-04-081-5/+6
| | | | | | | | | | | | | | | than the default buffer size in the old RPC code (8800 bytes), and it could not be overriden by the application. This caused problems with CFS (/usr/port/security/cfs). Change this default back to UDPMSGSIZE (8800 bytes), but more importantly, allow applications to use larger message sizes for all protocols if desired. Choose an arbitrary maximum message size of 256k instead of using the default as the maximum (which is silly). Reported by: ache Reviewed by: alfred, Martin Blapp <mb@imp.ch>
* Fix some very broken code in __nc_error() that implements per-threadiedowse2001-04-032-17/+28
| | | | | | | | | | | | | | | `nc_error' variables. Move the nc_lock mutex from mt_misc.c to a static variable within this function, since it is only used here. Add a new getnetconfigent() error code `NC_NOTFOUND' to report the case where the specified netid was not found. Set nc_error in all error cases in getnetconfigent() so that the error messages returned by nc_(s)perror are always meaningful. Add a terminating \n to the output of nc_perror() to match both our manpage and other implementations of this function. Reviewed by: deischen, alfred, Martin Blapp <mb@imp.ch>
* Remove some hacks that were apparently added to avoid problems withiedowse2001-04-032-4/+2
| | | | | | | RPC clients hanging. The real problem turned out to be missing cleanup code; this was fixed in clnt_vc.c r1.5 and clnt_dg.c r1.4. Submitted by: Martin Blapp <mb@imp.ch>
* There were a few error cases where the RPC code would return withiedowse2001-04-022-1/+5
| | | | | | all signals masked (whoops). Add the missing cleanup code. Reviewed by: Martin Blapp <mb@imp.ch>, alfred
* Move the #includes of reentrant.h to after the `#include "namespace.h"',iedowse2001-04-0223-23/+23
| | | | | | | | so that the underscored versions of the pthread functions get declared. This removes around 300 lines of 'implicit declaration of XXX' warnings from the output of a libc build with -Wall. Reviewed by: Martin Blapp <mb@imp.ch>, alfred
* Add a CLSET_ASYNC command, which allows us to (ab)use the clnt_dg transportwpaul2001-03-271-3/+19
| | | | | | | | | | | | | | | | | | to make asynchronous RPCs. This is needed to help fix ypbind, which can no longer override the clnt_dg_call() method (formerly the clntudp_call() method) due to all the internal descriptor locking code in TI-RPC. Turning on this flag allows us to send an RPC request, then return immediately, and handle a reply later, rather than being forced to do the request and reply in a single function call. Also fix a byte ordering bug: when clnt_dg_call() increments the XID prior to transmitting a request, it uses the raw value, which is wrong. The XID is stored in network byte order, i.e. big-endian. The CLSET_XID and CLGET_XID commands in clnt_dg_control() use ntohl()/htonl() to get the byte ordering right, but because clnt_dg_call() does not do this, using CLSET_XID/CLGET_XID doesn't actually work, unless you're on a big endian host, which we aren't (yet). Fix clnt_dg_call() to byte swap properly when doing the increment.
* MAN[1-9] -> MAN.ru2001-03-271-2/+2
|
* const'ifyalfred2001-03-271-1/+1
|
* Fix rcsid/$FreeBSD$.obrien2001-03-241-2/+15
| | | | Reduce diff from what I think is the original sources.
* fix Alpha supportalfred2001-03-241-10/+0
|
* change callrpc() from taking "char *" args, I'm quite sure they really meantalfred2001-03-232-3/+3
| | | | | | to use "void *". remove a duplicate prototype for callrpc() from libexec/ypxfr/ypxfr_extern.h
* Remove struct cmessage from sys/socket.h and reintroduce the privatealfred2001-03-222-2/+9
| | | | | | definitions. Requested by: wollman
* Hopefully fix some of the bugs in passing credentials over UNIX ↵alfred2001-03-222-26/+32
| | | | | | | | | | | | domain sockets. Make struct cmessage visible from socket.h (about 4 places were defining it for themselves which wasn't good) Make __rpc_get_local_uid() useable and give it prototype that's visible. Fix some issues with printing out usernames from rpcbind and keyserv.
* whitespace cleanupalfred2001-03-201-16/+14
|
* Fixed some typos.ru2001-03-203-3/+3
|
* This manpage is heavily based on the old rpc.3 manpage, andru2001-03-201-1355/+1139
| | | | | | | should have been repo-copied from it in the first place. Apply all of our fixes up to and including revision 1.14 to the original rpc.3 manpage, including conversion to mdoc(7).
* Removed the second copy of the manual page!ru2001-03-201-311/+0
|
* Removed duplicate $FreeBSD$.ru2001-03-201-1/+0
|
* Bring in a hybrid of SunSoft's transport-independent RPC (TI-RPC) andalfred2001-03-1980-6851/+16088
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* Submitted by: Ian Dowse <iedowse@maths.tcd.ie>, David Cross <dec@freebsd.org>dec2001-03-082-0/+2
| | | | | | | | | | | | | Reviewed by: David Cross <dec@freebsd.org>, jkh <jkh@freebsd.org> Approved by: jkh <jkh@freebsd.org> Obtained from: Ian Dowse <iedowse@maths.tcd.ie>, David Cross <dec@freebsd.org> We have been running this patch on a production NIS server for 2.5 weeks now. Normally we would have ypserv die at least once a week, and often many times a day. This patch treats and error from select as zeroing out the FD_SET to indicate that no fds are ready for reading. This is safe because the rpc code always re-inits the FDSET before calling select.
* mdoc(7) police: C types should be declared with either .Ft or .Vt.ru2001-02-081-1/+3
|
* Fixed errors in prototypes. Many were hiding under mdoc errors.bde2001-02-051-5/+30
|
* Remove _THREAD_SAFE and make libc thread-safe by default bydeischen2001-01-2421-78/+114
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | adding (weak definitions to) stubs for some of the pthread functions. If the threads library is linked in, the real pthread functions will pulled in. Use the following convention for system calls wrapped by the threads library: __sys_foo - actual system call _foo - weak definition to __sys_foo foo - weak definition to __sys_foo Change all libc uses of system calls wrapped by the threads library from foo to _foo. In order to define the prototypes for _foo(), we introduce namespace.h and un-namespace.h (suggested by bde). All files that need to reference these system calls, should include namespace.h before any standard includes, then include un-namespace.h after the standard includes and before any local includes. <db.h> is an exception and shouldn't be included in between namespace.h and un-namespace.h namespace.h will define foo to _foo, and un-namespace.h will undefine foo. Try to eliminate some of the recursive calls to MT-safe functions in libc/stdio in preparation for adding a mutex to FILE. We have recursive mutexes, but would like to avoid using them if possible. Remove uneeded includes of <errno.h> from a few files. Add $FreeBSD$ to a few files in order to pass commitprep. Approved by: -arch
* man(7) -> mdoc(7).ru2001-01-175-1416/+1143
|
* rstat(1) and rstat_svc(8) are the early versions ofru2001-01-173-88/+0
| | | | the rup(1) and rpc.rstatd(8) manpages respectively.
* Prepare for mdoc(7)NG.ru2000-12-291-1/+1
|
OpenPOWER on IntegriCloud