1*45066Smckusick /* @(#)pmap_clnt.h 2.1 88/07/29 4.0 RPCSRC; from 1.11 88/02/08 SMI */ 2*45066Smckusick /* 3*45066Smckusick * Sun RPC is a product of Sun Microsystems, Inc. and is provided for 4*45066Smckusick * unrestricted use provided that this legend is included on all tape 5*45066Smckusick * media and as a part of the software program in whole or part. Users 6*45066Smckusick * may copy or modify Sun RPC without charge, but are not authorized 7*45066Smckusick * to license or distribute it to anyone else except as part of a product or 8*45066Smckusick * program developed by the user. 9*45066Smckusick * 10*45066Smckusick * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE 11*45066Smckusick * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR 12*45066Smckusick * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. 13*45066Smckusick * 14*45066Smckusick * Sun RPC is provided with no support and without any obligation on the 15*45066Smckusick * part of Sun Microsystems, Inc. to assist in its use, correction, 16*45066Smckusick * modification or enhancement. 17*45066Smckusick * 18*45066Smckusick * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE 19*45066Smckusick * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC 20*45066Smckusick * OR ANY PART THEREOF. 21*45066Smckusick * 22*45066Smckusick * In no event will Sun Microsystems, Inc. be liable for any lost revenue 23*45066Smckusick * or profits or other special, indirect and consequential damages, even if 24*45066Smckusick * Sun has been advised of the possibility of such damages. 25*45066Smckusick * 26*45066Smckusick * Sun Microsystems, Inc. 27*45066Smckusick * 2550 Garcia Avenue 28*45066Smckusick * Mountain View, California 94043 29*45066Smckusick */ 30*45066Smckusick 31*45066Smckusick /* 32*45066Smckusick * pmap_clnt.h 33*45066Smckusick * Supplies C routines to get to portmap services. 34*45066Smckusick * 35*45066Smckusick * Copyright (C) 1984, Sun Microsystems, Inc. 36*45066Smckusick */ 37*45066Smckusick 38*45066Smckusick /* 39*45066Smckusick * Usage: 40*45066Smckusick * success = pmap_set(program, version, protocol, port); 41*45066Smckusick * success = pmap_unset(program, version); 42*45066Smckusick * port = pmap_getport(address, program, version, protocol); 43*45066Smckusick * head = pmap_getmaps(address); 44*45066Smckusick * clnt_stat = pmap_rmtcall(address, program, version, procedure, 45*45066Smckusick * xdrargs, argsp, xdrres, resp, tout, port_ptr) 46*45066Smckusick * (works for udp only.) 47*45066Smckusick * clnt_stat = clnt_broadcast(program, version, procedure, 48*45066Smckusick * xdrargs, argsp, xdrres, resp, eachresult) 49*45066Smckusick * (like pmap_rmtcall, except the call is broadcasted to all 50*45066Smckusick * locally connected nets. For each valid response received, 51*45066Smckusick * the procedure eachresult is called. Its form is: 52*45066Smckusick * done = eachresult(resp, raddr) 53*45066Smckusick * bool_t done; 54*45066Smckusick * caddr_t resp; 55*45066Smckusick * struct sockaddr_in raddr; 56*45066Smckusick * where resp points to the results of the call and raddr is the 57*45066Smckusick * address if the responder to the broadcast. 58*45066Smckusick */ 59*45066Smckusick 60*45066Smckusick extern bool_t pmap_set(); 61*45066Smckusick extern bool_t pmap_unset(); 62*45066Smckusick extern struct pmaplist *pmap_getmaps(); 63*45066Smckusick enum clnt_stat pmap_rmtcall(); 64*45066Smckusick enum clnt_stat clnt_broadcast(); 65*45066Smckusick extern u_short pmap_getport(); 66