home *** CD-ROM | disk | FTP | other *** search
/ The Datafile PD-CD 4 / DATAFILE_PDCD4.iso / utilities / utilss / sockets / include / rpc / h / pmap_prot < prev    next >
Encoding:
Text File  |  1995-01-11  |  3.6 KB  |  110 lines

  1. /* -*-C-*-
  2.  *
  3.  * $Header: /ax/networking:include/rpc/pmap_prot.h:networking  1.1  $
  4.  * $Source: /ax/networking:include/rpc/pmap_prot.h: $
  5.  *
  6.  * Copyright (c) 1995 Acorn Computers Ltd., Cambridge, England
  7.  *
  8.  * $Log:    pmap_prot.h,v $
  9.  * Revision 1.1  95/01/11  10:18:30  kwelton
  10.  * Initial revision
  11.  * 
  12.  */
  13.  
  14. /* @(#)pmap_prot.h    2.1 88/07/29 4.0 RPCSRC; from 1.14 88/02/08 SMI */
  15. /*
  16.  * Sun RPC is a product of Sun Microsystems, Inc. and is provided for
  17.  * unrestricted use provided that this legend is included on all tape
  18.  * media and as a part of the software program in whole or part.  Users
  19.  * may copy or modify Sun RPC without charge, but are not authorized
  20.  * to license or distribute it to anyone else except as part of a product or
  21.  * program developed by the user.
  22.  * 
  23.  * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
  24.  * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
  25.  * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
  26.  * 
  27.  * Sun RPC is provided with no support and without any obligation on the
  28.  * part of Sun Microsystems, Inc. to assist in its use, correction,
  29.  * modification or enhancement.
  30.  * 
  31.  * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
  32.  * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
  33.  * OR ANY PART THEREOF.
  34.  * 
  35.  * In no event will Sun Microsystems, Inc. be liable for any lost revenue
  36.  * or profits or other special, indirect and consequential damages, even if
  37.  * Sun has been advised of the possibility of such damages.
  38.  * 
  39.  * Sun Microsystems, Inc.
  40.  * 2550 Garcia Avenue
  41.  * Mountain View, California  94043
  42.  */
  43.  
  44. /*
  45.  * pmap_prot.h
  46.  * Protocol for the local binder service, or pmap.
  47.  *
  48.  * Copyright (C) 1984, Sun Microsystems, Inc.
  49.  *
  50.  * The following procedures are supported by the protocol:
  51.  *
  52.  * PMAPPROC_NULL() returns ()
  53.  *     takes nothing, returns nothing
  54.  *
  55.  * PMAPPROC_SET(struct pmap) returns (bool_t)
  56.  *     TRUE is success, FALSE is failure.  Registers the tuple
  57.  *    [prog, vers, prot, port].
  58.  *
  59.  * PMAPPROC_UNSET(struct pmap) returns (bool_t)
  60.  *    TRUE is success, FALSE is failure.  Un-registers pair
  61.  *    [prog, vers].  prot and port are ignored.
  62.  *
  63.  * PMAPPROC_GETPORT(struct pmap) returns (long unsigned).
  64.  *    0 is failure.  Otherwise returns the port number where the pair
  65.  *    [prog, vers] is registered.  It may lie!
  66.  *
  67.  * PMAPPROC_DUMP() RETURNS (struct pmaplist *)
  68.  *
  69.  * PMAPPROC_CALLIT(unsigned, unsigned, unsigned, string<>)
  70.  *     RETURNS (port, string<>);
  71.  * usage: encapsulatedresults = PMAPPROC_CALLIT(prog, vers, proc, encapsulatedargs);
  72.  *     Calls the procedure on the local machine.  If it is not registered,
  73.  *    this procedure is quite; ie it does not return error information!!!
  74.  *    This procedure only is supported on rpc/udp and calls via
  75.  *    rpc/udp.  This routine only passes null authentication parameters.
  76.  *    This file has no interface to xdr routines for PMAPPROC_CALLIT.
  77.  *
  78.  * The service supports remote procedure calls on udp/ip or tcp/ip socket 111.
  79.  */
  80.  
  81. #define PMAPPORT        ((u_short)111)
  82. #define PMAPPROG        ((u_long)100000)
  83. #define PMAPVERS        ((u_long)2)
  84. #define PMAPVERS_PROTO        ((u_long)2)
  85. #define PMAPVERS_ORIG        ((u_long)1)
  86. #define PMAPPROC_NULL        ((u_long)0)
  87. #define PMAPPROC_SET        ((u_long)1)
  88. #define PMAPPROC_UNSET        ((u_long)2)
  89. #define PMAPPROC_GETPORT    ((u_long)3)
  90. #define PMAPPROC_DUMP        ((u_long)4)
  91. #define PMAPPROC_CALLIT        ((u_long)5)
  92.  
  93. struct pmap {
  94.     long unsigned pm_prog;
  95.     long unsigned pm_vers;
  96.     long unsigned pm_prot;
  97.     long unsigned pm_port;
  98. };
  99.  
  100. extern bool_t xdr_pmap();
  101.  
  102. struct pmaplist {
  103.     struct pmap    pml_map;
  104.     struct pmaplist *pml_next;
  105. };
  106.  
  107. extern bool_t xdr_pmaplist();
  108.  
  109. /* EOF pmap_prot.h */
  110.