b69b4cec972ba9e3b13a301dfbf088fdb1ff5e82
[reactos.git] / reactos / dll / win32 / libtirpc / tirpc / rpc / rpcb_prot.h
1 /*
2 * Please do not edit this file.
3 * It was generated using rpcgen.
4 */
5
6 #ifndef _RPCB_PROT_H_RPCGEN
7 #define _RPCB_PROT_H_RPCGEN
8
9 #include <rpc/rpc.h>
10
11 #ifndef IXDR_GET_INT32
12 #define IXDR_GET_INT32(buf) IXDR_GET_LONG((buf))
13 #endif
14 #ifndef IXDR_PUT_INT32
15 #define IXDR_PUT_INT32(buf, v) IXDR_PUT_LONG((buf), (v))
16 #endif
17 #ifndef IXDR_GET_U_INT32
18 #define IXDR_GET_U_INT32(buf) IXDR_GET_U_LONG((buf))
19 #endif
20 #ifndef IXDR_PUT_U_INT32
21 #define IXDR_PUT_U_INT32(buf, v) IXDR_PUT_U_LONG((buf), (v))
22 #endif
23 /*
24 * $FreeBSD: src/include/rpc/rpcb_prot.x,v 1.3 2002/03/13 10:29:06 obrien Exp $
25 *
26 * Copyright (c) 2009, Sun Microsystems, Inc.
27 * All rights reserved.
28 *
29 * Redistribution and use in source and binary forms, with or without
30 * modification, are permitted provided that the following conditions are met:
31 * - Redistributions of source code must retain the above copyright notice,
32 * this list of conditions and the following disclaimer.
33 * - Redistributions in binary form must reproduce the above copyright notice,
34 * this list of conditions and the following disclaimer in the documentation
35 * and/or other materials provided with the distribution.
36 * - Neither the name of Sun Microsystems, Inc. nor the names of its
37 * contributors may be used to endorse or promote products derived
38 * from this software without specific prior written permission.
39 *
40 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
41 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
42 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
43 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
44 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
45 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
46 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
47 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
48 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
49 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
50 * POSSIBILITY OF SUCH DAMAGE.
51 */
52 /*
53 * Copyright (c) 1988 by Sun Microsystems, Inc.
54 */
55 /* from rpcb_prot.x */
56
57 /* #pragma ident "@(#)rpcb_prot.x 1.5 94/04/29 SMI" */
58
59 #ifndef _KERNEL
60
61
62 /*
63 * The following procedures are supported by the protocol in version 3:
64 *
65 * RPCBPROC_NULL() returns ()
66 * takes nothing, returns nothing
67 *
68 * RPCBPROC_SET(rpcb) returns (bool_t)
69 * TRUE is success, FALSE is failure. Registers the tuple
70 * [prog, vers, address, owner, netid].
71 * Finds out owner and netid information on its own.
72 *
73 * RPCBPROC_UNSET(rpcb) returns (bool_t)
74 * TRUE is success, FALSE is failure. Un-registers tuple
75 * [prog, vers, netid]. addresses is ignored.
76 * If netid is NULL, unregister all.
77 *
78 * RPCBPROC_GETADDR(rpcb) returns (string).
79 * 0 is failure. Otherwise returns the universal address where the
80 * triple [prog, vers, netid] is registered. Ignore address and owner.
81 *
82 * RPCBPROC_DUMP() RETURNS (rpcblist_ptr)
83 * used to dump the entire rpcbind maps
84 *
85 * RPCBPROC_CALLIT(rpcb_rmtcallargs)
86 * RETURNS (rpcb_rmtcallres);
87 * Calls the procedure on the remote machine. If it is not registered,
88 * this procedure is quiet; i.e. it does not return error information!!!
89 * This routine only passes null authentication parameters.
90 * It has no interface to xdr routines for RPCBPROC_CALLIT.
91 *
92 * RPCBPROC_GETTIME() returns (int).
93 * Gets the remote machines time
94 *
95 * RPCBPROC_UADDR2TADDR(strint) RETURNS (struct netbuf)
96 * Returns the netbuf address from universal address.
97 *
98 * RPCBPROC_TADDR2UADDR(struct netbuf) RETURNS (string)
99 * Returns the universal address from netbuf address.
100 *
101 * END OF RPCBIND VERSION 3 PROCEDURES
102 */
103 /*
104 * Except for RPCBPROC_CALLIT, the procedures above are carried over to
105 * rpcbind version 4. Those below are added or modified for version 4.
106 * NOTE: RPCBPROC_BCAST HAS THE SAME FUNCTIONALITY AND PROCEDURE NUMBER
107 * AS RPCBPROC_CALLIT.
108 *
109 * RPCBPROC_BCAST(rpcb_rmtcallargs)
110 * RETURNS (rpcb_rmtcallres);
111 * Calls the procedure on the remote machine. If it is not registered,
112 * this procedure IS quiet; i.e. it DOES NOT return error information!!!
113 * This routine should be used for broadcasting and nothing else.
114 *
115 * RPCBPROC_GETVERSADDR(rpcb) returns (string).
116 * 0 is failure. Otherwise returns the universal address where the
117 * triple [prog, vers, netid] is registered. Ignore address and owner.
118 * Same as RPCBPROC_GETADDR except that if the given version number
119 * is not available, the address is not returned.
120 *
121 * RPCBPROC_INDIRECT(rpcb_rmtcallargs)
122 * RETURNS (rpcb_rmtcallres);
123 * Calls the procedure on the remote machine. If it is not registered,
124 * this procedure is NOT quiet; i.e. it DOES return error information!!!
125 * as any normal application would expect.
126 *
127 * RPCBPROC_GETADDRLIST(rpcb) returns (rpcb_entry_list_ptr).
128 * Same as RPCBPROC_GETADDR except that it returns a list of all the
129 * addresses registered for the combination (prog, vers) (for all
130 * transports).
131 *
132 * RPCBPROC_GETSTAT(void) returns (rpcb_stat_byvers)
133 * Returns the statistics about the kind of requests received by rpcbind.
134 */
135
136 /*
137 * A mapping of (program, version, network ID) to address
138 */
139
140 struct rpcb {
141 rpcprog_t r_prog;
142 rpcvers_t r_vers;
143 char *r_netid;
144 char *r_addr;
145 char *r_owner;
146 };
147 typedef struct rpcb rpcb;
148 #ifdef __cplusplus
149 extern "C" bool_t xdr_rpcb(XDR *, rpcb*);
150 #elif __STDC__
151 extern bool_t xdr_rpcb(XDR *, rpcb*);
152 #else /* Old Style C */
153 //bool_t xdr_rpcb();
154 bool_t xdr_rpcb(XDR *, rpcb*);
155 #endif /* Old Style C */
156
157
158 typedef rpcb RPCB;
159
160
161 /*
162 * A list of mappings
163 *
164 * Below are two definitions for the rpcblist structure. This is done because
165 * xdr_rpcblist() is specified to take a struct rpcblist **, rather than a
166 * struct rpcblist * that rpcgen would produce. One version of the rpcblist
167 * structure (actually called rp__list) is used with rpcgen, and the other is
168 * defined only in the header file for compatibility with the specified
169 * interface.
170 */
171
172 struct rp__list {
173 rpcb rpcb_map;
174 struct rp__list *rpcb_next;
175 };
176 typedef struct rp__list rp__list;
177 #ifdef __cplusplus
178 extern "C" bool_t xdr_rp__list(XDR *, rp__list*);
179 #elif __STDC__
180 extern bool_t xdr_rp__list(XDR *, rp__list*);
181 #else /* Old Style C */
182 //bool_t xdr_rp__list();
183 bool_t xdr_rp__list(XDR *, rp__list*);
184 #endif /* Old Style C */
185
186
187 typedef rp__list *rpcblist_ptr;
188 #ifdef __cplusplus
189 extern "C" bool_t xdr_rpcblist_ptr(XDR *, rpcblist_ptr*);
190 #elif __STDC__
191 extern bool_t xdr_rpcblist_ptr(XDR *, rpcblist_ptr*);
192 #else /* Old Style C */
193 //bool_t xdr_rpcblist_ptr();
194 bool_t xdr_rpcblist_ptr(XDR *, rpcblist_ptr*);
195 #endif /* Old Style C */
196
197
198 typedef struct rp__list rpcblist;
199 typedef struct rp__list RPCBLIST;
200
201 #ifndef __cplusplus
202 struct rpcblist {
203 RPCB rpcb_map;
204 struct rpcblist *rpcb_next;
205 };
206 #endif
207
208 #ifdef __cplusplus
209 extern "C" {
210 #endif
211 extern bool_t xdr_rpcblist(XDR *, rpcblist**);
212 #ifdef __cplusplus
213 }
214 #endif
215
216
217 /*
218 * Arguments of remote calls
219 */
220
221 struct rpcb_rmtcallargs {
222 rpcprog_t prog;
223 rpcvers_t vers;
224 rpcproc_t proc;
225 struct {
226 u_int args_len;
227 char *args_val;
228 } args;
229 };
230 typedef struct rpcb_rmtcallargs rpcb_rmtcallargs;
231 #ifdef __cplusplus
232 extern "C" bool_t xdr_rpcb_rmtcallargs(XDR *, rpcb_rmtcallargs*);
233 #elif __STDC__
234 extern bool_t xdr_rpcb_rmtcallargs(XDR *, rpcb_rmtcallargs*);
235 #else /* Old Style C */
236 //bool_t xdr_rpcb_rmtcallargs();
237 bool_t xdr_rpcb_rmtcallargs(XDR *, rpcb_rmtcallargs*);
238 #endif /* Old Style C */
239
240
241 /*
242 * Client-side only representation of rpcb_rmtcallargs structure.
243 *
244 * The routine that XDRs the rpcb_rmtcallargs structure must deal with the
245 * opaque arguments in the "args" structure. xdr_rpcb_rmtcallargs() needs to
246 * be passed the XDR routine that knows the args' structure. This routine
247 * doesn't need to go over-the-wire (and it wouldn't make sense anyway) since
248 * the application being called already knows the args structure. So we use a
249 * different "XDR" structure on the client side, r_rpcb_rmtcallargs, which
250 * includes the args' XDR routine.
251 */
252 struct r_rpcb_rmtcallargs {
253 rpcprog_t prog;
254 rpcvers_t vers;
255 rpcproc_t proc;
256 struct {
257 u_int args_len;
258 char *args_val;
259 } args;
260 xdrproc_t xdr_args; /* encodes args */
261 };
262
263
264 /*
265 * Results of the remote call
266 */
267
268 struct rpcb_rmtcallres {
269 char *addr;
270 struct {
271 u_int results_len;
272 char *results_val;
273 } results;
274 };
275 typedef struct rpcb_rmtcallres rpcb_rmtcallres;
276 #ifdef __cplusplus
277 extern "C" bool_t xdr_rpcb_rmtcallres(XDR *, rpcb_rmtcallres*);
278 #elif __STDC__
279 extern bool_t xdr_rpcb_rmtcallres(XDR *, rpcb_rmtcallres*);
280 #else /* Old Style C */
281 //bool_t xdr_rpcb_rmtcallres();
282 bool_t xdr_rpcb_rmtcallres(XDR *, rpcb_rmtcallres*);
283 #endif /* Old Style C */
284
285
286 /*
287 * Client-side only representation of rpcb_rmtcallres structure.
288 */
289 struct r_rpcb_rmtcallres {
290 char *addr;
291 struct {
292 u_int32_t results_len;
293 char *results_val;
294 } results;
295 xdrproc_t xdr_res; /* decodes results */
296 };
297
298 /*
299 * rpcb_entry contains a merged address of a service on a particular
300 * transport, plus associated netconfig information. A list of rpcb_entrys
301 * is returned by RPCBPROC_GETADDRLIST. See netconfig.h for values used
302 * in r_nc_* fields.
303 */
304
305 struct rpcb_entry {
306 char *r_maddr;
307 char *r_nc_netid;
308 u_int r_nc_semantics;
309 char *r_nc_protofmly;
310 char *r_nc_proto;
311 };
312 typedef struct rpcb_entry rpcb_entry;
313 #ifdef __cplusplus
314 extern "C" bool_t xdr_rpcb_entry(XDR *, rpcb_entry*);
315 #elif __STDC__
316 extern bool_t xdr_rpcb_entry(XDR *, rpcb_entry*);
317 #else /* Old Style C */
318 bool_t xdr_rpcb_entry();
319 #endif /* Old Style C */
320
321
322 /*
323 * A list of addresses supported by a service.
324 */
325
326 struct rpcb_entry_list {
327 rpcb_entry rpcb_entry_map;
328 struct rpcb_entry_list *rpcb_entry_next;
329 };
330 typedef struct rpcb_entry_list rpcb_entry_list;
331 #ifdef __cplusplus
332 extern "C" bool_t xdr_rpcb_entry_list(XDR *, rpcb_entry_list*);
333 #elif __STDC__
334 extern bool_t xdr_rpcb_entry_list(XDR *, rpcb_entry_list*);
335 #else /* Old Style C */
336 bool_t xdr_rpcb_entry_list();
337 #endif /* Old Style C */
338
339
340 typedef rpcb_entry_list *rpcb_entry_list_ptr;
341 #ifdef __cplusplus
342 extern "C" bool_t xdr_rpcb_entry_list_ptr(XDR *, rpcb_entry_list_ptr*);
343 #elif __STDC__
344 extern bool_t xdr_rpcb_entry_list_ptr(XDR *, rpcb_entry_list_ptr*);
345 #else /* Old Style C */
346 bool_t xdr_rpcb_entry_list_ptr();
347 #endif /* Old Style C */
348
349
350 /*
351 * rpcbind statistics
352 */
353
354 #define rpcb_highproc_2 RPCBPROC_CALLIT
355 #define rpcb_highproc_3 RPCBPROC_TADDR2UADDR
356 #define rpcb_highproc_4 RPCBPROC_GETSTAT
357 #define RPCBSTAT_HIGHPROC 13
358 #define RPCBVERS_STAT 3
359 #define RPCBVERS_4_STAT 2
360 #define RPCBVERS_3_STAT 1
361 #define RPCBVERS_2_STAT 0
362
363 /* Link list of all the stats about getport and getaddr */
364
365 struct rpcbs_addrlist {
366 rpcprog_t prog;
367 rpcvers_t vers;
368 int success;
369 int failure;
370 char *netid;
371 struct rpcbs_addrlist *next;
372 };
373 typedef struct rpcbs_addrlist rpcbs_addrlist;
374 #ifdef __cplusplus
375 extern "C" bool_t xdr_rpcbs_addrlist(XDR *, rpcbs_addrlist*);
376 #elif __STDC__
377 extern bool_t xdr_rpcbs_addrlist(XDR *, rpcbs_addrlist*);
378 #else /* Old Style C */
379 bool_t xdr_rpcbs_addrlist();
380 #endif /* Old Style C */
381
382
383 /* Link list of all the stats about rmtcall */
384
385 struct rpcbs_rmtcalllist {
386 rpcprog_t prog;
387 rpcvers_t vers;
388 rpcproc_t proc;
389 int success;
390 int failure;
391 int indirect;
392 char *netid;
393 struct rpcbs_rmtcalllist *next;
394 };
395 typedef struct rpcbs_rmtcalllist rpcbs_rmtcalllist;
396 #ifdef __cplusplus
397 extern "C" bool_t xdr_rpcbs_rmtcalllist(XDR *, rpcbs_rmtcalllist*);
398 #elif __STDC__
399 extern bool_t xdr_rpcbs_rmtcalllist(XDR *, rpcbs_rmtcalllist*);
400 #else /* Old Style C */
401 bool_t xdr_rpcbs_rmtcalllist();
402 #endif /* Old Style C */
403
404
405 typedef int rpcbs_proc[RPCBSTAT_HIGHPROC];
406 #ifdef __cplusplus
407 extern "C" bool_t xdr_rpcbs_proc(XDR *, rpcbs_proc);
408 #elif __STDC__
409 extern bool_t xdr_rpcbs_proc(XDR *, rpcbs_proc);
410 #else /* Old Style C */
411 bool_t xdr_rpcbs_proc();
412 #endif /* Old Style C */
413
414
415 typedef rpcbs_addrlist *rpcbs_addrlist_ptr;
416 #ifdef __cplusplus
417 extern "C" bool_t xdr_rpcbs_addrlist_ptr(XDR *, rpcbs_addrlist_ptr*);
418 #elif __STDC__
419 extern bool_t xdr_rpcbs_addrlist_ptr(XDR *, rpcbs_addrlist_ptr*);
420 #else /* Old Style C */
421 bool_t xdr_rpcbs_addrlist_ptr();
422 #endif /* Old Style C */
423
424
425 typedef rpcbs_rmtcalllist *rpcbs_rmtcalllist_ptr;
426 #ifdef __cplusplus
427 extern "C" bool_t xdr_rpcbs_rmtcalllist_ptr(XDR *, rpcbs_rmtcalllist_ptr*);
428 #elif __STDC__
429 extern bool_t xdr_rpcbs_rmtcalllist_ptr(XDR *, rpcbs_rmtcalllist_ptr*);
430 #else /* Old Style C */
431 //bool_t xdr_rpcbs_rmtcalllist_ptr();
432 bool_t xdr_rpcbs_rmtcalllist_ptr(XDR *, rpcbs_rmtcalllist_ptr*);
433 #endif /* Old Style C */
434
435
436 struct rpcb_stat {
437 rpcbs_proc info;
438 int setinfo;
439 int unsetinfo;
440 rpcbs_addrlist_ptr addrinfo;
441 rpcbs_rmtcalllist_ptr rmtinfo;
442 };
443 typedef struct rpcb_stat rpcb_stat;
444 #ifdef __cplusplus
445 extern "C" bool_t xdr_rpcb_stat(XDR *, rpcb_stat*);
446 #elif __STDC__
447 extern bool_t xdr_rpcb_stat(XDR *, rpcb_stat*);
448 #else /* Old Style C */
449 bool_t xdr_rpcb_stat();
450 #endif /* Old Style C */
451
452
453 /*
454 * One rpcb_stat structure is returned for each version of rpcbind
455 * being monitored.
456 */
457
458 typedef rpcb_stat rpcb_stat_byvers[RPCBVERS_STAT];
459 #ifdef __cplusplus
460 extern "C" bool_t xdr_rpcb_stat_byvers(XDR *, rpcb_stat_byvers);
461 #elif __STDC__
462 extern bool_t xdr_rpcb_stat_byvers(XDR *, rpcb_stat_byvers);
463 #else /* Old Style C */
464 bool_t xdr_rpcb_stat_byvers();
465 #endif /* Old Style C */
466
467
468 /*
469 * We don't define netbuf in RPCL, since it would contain structure member
470 * names that would conflict with the definition of struct netbuf in
471 * <tiuser.h>. Instead we merely declare the XDR routine xdr_netbuf() here,
472 * and implement it ourselves in rpc/rpcb_prot.c.
473 */
474 #ifdef __cplusplus
475 extern "C" bool_t xdr_netbuf(XDR *, struct netbuf *);
476
477 #else /* __STDC__ */
478 extern bool_t xdr_netbuf(XDR *, struct netbuf *);
479
480 #endif
481
482 #define RPCBVERS_3 RPCBVERS
483 #define RPCBVERS_4 RPCBVERS4
484
485 #define _PATH_RPCBINDSOCK "/var/run/rpcbind.sock"
486
487 #else /* ndef _KERNEL */
488 #ifdef __cplusplus
489 extern "C" {
490 #endif
491
492 /*
493 * A mapping of (program, version, network ID) to address
494 */
495 struct rpcb {
496 rpcprog_t r_prog; /* program number */
497 rpcvers_t r_vers; /* version number */
498 char *r_netid; /* network id */
499 char *r_addr; /* universal address */
500 char *r_owner; /* owner of the mapping */
501 };
502 typedef struct rpcb RPCB;
503
504 /*
505 * A list of mappings
506 */
507 struct rpcblist {
508 RPCB rpcb_map;
509 struct rpcblist *rpcb_next;
510 };
511 typedef struct rpcblist RPCBLIST;
512 typedef struct rpcblist *rpcblist_ptr;
513
514 /*
515 * Remote calls arguments
516 */
517 struct rpcb_rmtcallargs {
518 rpcprog_t prog; /* program number */
519 rpcvers_t vers; /* version number */
520 rpcproc_t proc; /* procedure number */
521 u_int32_t arglen; /* arg len */
522 caddr_t args_ptr; /* argument */
523 xdrproc_t xdr_args; /* XDR routine for argument */
524 };
525 typedef struct rpcb_rmtcallargs rpcb_rmtcallargs;
526
527 /*
528 * Remote calls results
529 */
530 struct rpcb_rmtcallres {
531 char *addr_ptr; /* remote universal address */
532 u_int32_t resultslen; /* results length */
533 caddr_t results_ptr; /* results */
534 xdrproc_t xdr_results; /* XDR routine for result */
535 };
536 typedef struct rpcb_rmtcallres rpcb_rmtcallres;
537
538 struct rpcb_entry {
539 char *r_maddr;
540 char *r_nc_netid;
541 unsigned int r_nc_semantics;
542 char *r_nc_protofmly;
543 char *r_nc_proto;
544 };
545 typedef struct rpcb_entry rpcb_entry;
546
547 /*
548 * A list of addresses supported by a service.
549 */
550
551 struct rpcb_entry_list {
552 rpcb_entry rpcb_entry_map;
553 struct rpcb_entry_list *rpcb_entry_next;
554 };
555 typedef struct rpcb_entry_list rpcb_entry_list;
556
557 typedef rpcb_entry_list *rpcb_entry_list_ptr;
558
559 /*
560 * rpcbind statistics
561 */
562
563 #define rpcb_highproc_2 RPCBPROC_CALLIT
564 #define rpcb_highproc_3 RPCBPROC_TADDR2UADDR
565 #define rpcb_highproc_4 RPCBPROC_GETSTAT
566 #define RPCBSTAT_HIGHPROC 13
567 #define RPCBVERS_STAT 3
568 #define RPCBVERS_4_STAT 2
569 #define RPCBVERS_3_STAT 1
570 #define RPCBVERS_2_STAT 0
571
572 /* Link list of all the stats about getport and getaddr */
573
574 struct rpcbs_addrlist {
575 rpcprog_t prog;
576 rpcvers_t vers;
577 int success;
578 int failure;
579 char *netid;
580 struct rpcbs_addrlist *next;
581 };
582 typedef struct rpcbs_addrlist rpcbs_addrlist;
583
584 /* Link list of all the stats about rmtcall */
585
586 struct rpcbs_rmtcalllist {
587 rpcprog_t prog;
588 rpcvers_t vers;
589 rpcproc_t proc;
590 int success;
591 int failure;
592 int indirect;
593 char *netid;
594 struct rpcbs_rmtcalllist *next;
595 };
596 typedef struct rpcbs_rmtcalllist rpcbs_rmtcalllist;
597
598 typedef int rpcbs_proc[RPCBSTAT_HIGHPROC];
599
600 typedef rpcbs_addrlist *rpcbs_addrlist_ptr;
601
602 typedef rpcbs_rmtcalllist *rpcbs_rmtcalllist_ptr;
603
604 struct rpcb_stat {
605 rpcbs_proc info;
606 int setinfo;
607 int unsetinfo;
608 rpcbs_addrlist_ptr addrinfo;
609 rpcbs_rmtcalllist_ptr rmtinfo;
610 };
611 typedef struct rpcb_stat rpcb_stat;
612
613 /*
614 * One rpcb_stat structure is returned for each version of rpcbind
615 * being monitored.
616 */
617
618 typedef rpcb_stat rpcb_stat_byvers[RPCBVERS_STAT];
619
620 #ifdef __cplusplus
621 }
622 #endif
623
624 #endif /* ndef _KERNEL */
625
626 #define RPCBPROG ((u_int32_t)100000)
627 #define RPCBVERS ((u_int32_t)3)
628
629 #ifdef __cplusplus
630 #define RPCBPROC_SET ((u_int32_t)1)
631 extern "C" bool_t * rpcbproc_set_3(rpcb *, CLIENT *);
632 extern "C" bool_t * rpcbproc_set_3_svc(rpcb *, struct svc_req *);
633 #define RPCBPROC_UNSET ((u_int32_t)2)
634 extern "C" bool_t * rpcbproc_unset_3(rpcb *, CLIENT *);
635 extern "C" bool_t * rpcbproc_unset_3_svc(rpcb *, struct svc_req *);
636 #define RPCBPROC_GETADDR ((u_int32_t)3)
637 extern "C" char ** rpcbproc_getaddr_3(rpcb *, CLIENT *);
638 extern "C" char ** rpcbproc_getaddr_3_svc(rpcb *, struct svc_req *);
639 #define RPCBPROC_DUMP ((u_int32_t)4)
640 extern "C" rpcblist_ptr * rpcbproc_dump_3(void *, CLIENT *);
641 extern "C" rpcblist_ptr * rpcbproc_dump_3_svc(void *, struct svc_req *);
642 #define RPCBPROC_CALLIT ((u_int32_t)5)
643 extern "C" rpcb_rmtcallres * rpcbproc_callit_3(rpcb_rmtcallargs *, CLIENT *);
644 extern "C" rpcb_rmtcallres * rpcbproc_callit_3_svc(rpcb_rmtcallargs *, struct svc_req *);
645 #define RPCBPROC_GETTIME ((u_int32_t)6)
646 extern "C" u_int * rpcbproc_gettime_3(void *, CLIENT *);
647 extern "C" u_int * rpcbproc_gettime_3_svc(void *, struct svc_req *);
648 #define RPCBPROC_UADDR2TADDR ((u_int32_t)7)
649 extern "C" struct netbuf * rpcbproc_uaddr2taddr_3(char **, CLIENT *);
650 extern "C" struct netbuf * rpcbproc_uaddr2taddr_3_svc(char **, struct svc_req *);
651 #define RPCBPROC_TADDR2UADDR ((u_int32_t)8)
652 extern "C" char ** rpcbproc_taddr2uaddr_3(struct netbuf *, CLIENT *);
653 extern "C" char ** rpcbproc_taddr2uaddr_3_svc(struct netbuf *, struct svc_req *);
654
655 #elif __STDC__
656 #define RPCBPROC_SET ((u_int32_t)1)
657 extern bool_t * rpcbproc_set_3(rpcb *, CLIENT *);
658 extern bool_t * rpcbproc_set_3_svc(rpcb *, struct svc_req *);
659 #define RPCBPROC_UNSET ((u_int32_t)2)
660 extern bool_t * rpcbproc_unset_3(rpcb *, CLIENT *);
661 extern bool_t * rpcbproc_unset_3_svc(rpcb *, struct svc_req *);
662 #define RPCBPROC_GETADDR ((u_int32_t)3)
663 extern char ** rpcbproc_getaddr_3(rpcb *, CLIENT *);
664 extern char ** rpcbproc_getaddr_3_svc(rpcb *, struct svc_req *);
665 #define RPCBPROC_DUMP ((u_int32_t)4)
666 extern rpcblist_ptr * rpcbproc_dump_3(void *, CLIENT *);
667 extern rpcblist_ptr * rpcbproc_dump_3_svc(void *, struct svc_req *);
668 #define RPCBPROC_CALLIT ((u_int32_t)5)
669 extern rpcb_rmtcallres * rpcbproc_callit_3(rpcb_rmtcallargs *, CLIENT *);
670 extern rpcb_rmtcallres * rpcbproc_callit_3_svc(rpcb_rmtcallargs *, struct svc_req *);
671 #define RPCBPROC_GETTIME ((u_int32_t)6)
672 extern u_int * rpcbproc_gettime_3(void *, CLIENT *);
673 extern u_int * rpcbproc_gettime_3_svc(void *, struct svc_req *);
674 #define RPCBPROC_UADDR2TADDR ((u_int32_t)7)
675 extern struct netbuf * rpcbproc_uaddr2taddr_3(char **, CLIENT *);
676 extern struct netbuf * rpcbproc_uaddr2taddr_3_svc(char **, struct svc_req *);
677 #define RPCBPROC_TADDR2UADDR ((u_int32_t)8)
678 extern char ** rpcbproc_taddr2uaddr_3(struct netbuf *, CLIENT *);
679 extern char ** rpcbproc_taddr2uaddr_3_svc(struct netbuf *, struct svc_req *);
680
681 #else /* Old Style C */
682 #define RPCBPROC_SET ((u_int32_t)1)
683 extern bool_t * rpcbproc_set_3();
684 extern bool_t * rpcbproc_set_3_svc();
685 #define RPCBPROC_UNSET ((u_int32_t)2)
686 extern bool_t * rpcbproc_unset_3();
687 extern bool_t * rpcbproc_unset_3_svc();
688 #define RPCBPROC_GETADDR ((u_int32_t)3)
689 extern char ** rpcbproc_getaddr_3();
690 extern char ** rpcbproc_getaddr_3_svc();
691 #define RPCBPROC_DUMP ((u_int32_t)4)
692 extern rpcblist_ptr * rpcbproc_dump_3();
693 extern rpcblist_ptr * rpcbproc_dump_3_svc();
694 #define RPCBPROC_CALLIT ((u_int32_t)5)
695 extern rpcb_rmtcallres * rpcbproc_callit_3();
696 extern rpcb_rmtcallres * rpcbproc_callit_3_svc();
697 #define RPCBPROC_GETTIME ((u_int32_t)6)
698 extern u_int * rpcbproc_gettime_3();
699 extern u_int * rpcbproc_gettime_3_svc();
700 #define RPCBPROC_UADDR2TADDR ((u_int32_t)7)
701 extern struct netbuf * rpcbproc_uaddr2taddr_3();
702 extern struct netbuf * rpcbproc_uaddr2taddr_3_svc();
703 #define RPCBPROC_TADDR2UADDR ((u_int32_t)8)
704 extern char ** rpcbproc_taddr2uaddr_3();
705 extern char ** rpcbproc_taddr2uaddr_3_svc();
706 #endif /* Old Style C */
707 #define RPCBVERS4 ((u_int32_t)4)
708
709 #ifdef __cplusplus
710 extern "C" bool_t * rpcbproc_set_4(rpcb *, CLIENT *);
711 extern "C" bool_t * rpcbproc_set_4_svc(rpcb *, struct svc_req *);
712 extern "C" bool_t * rpcbproc_unset_4(rpcb *, CLIENT *);
713 extern "C" bool_t * rpcbproc_unset_4_svc(rpcb *, struct svc_req *);
714 extern "C" char ** rpcbproc_getaddr_4(rpcb *, CLIENT *);
715 extern "C" char ** rpcbproc_getaddr_4_svc(rpcb *, struct svc_req *);
716 extern "C" rpcblist_ptr * rpcbproc_dump_4(void *, CLIENT *);
717 extern "C" rpcblist_ptr * rpcbproc_dump_4_svc(void *, struct svc_req *);
718 #define RPCBPROC_BCAST ((u_int32_t)RPCBPROC_CALLIT)
719 extern "C" rpcb_rmtcallres * rpcbproc_bcast_4(rpcb_rmtcallargs *, CLIENT *);
720 extern "C" rpcb_rmtcallres * rpcbproc_bcast_4_svc(rpcb_rmtcallargs *, struct svc_req *);
721 extern "C" u_int * rpcbproc_gettime_4(void *, CLIENT *);
722 extern "C" u_int * rpcbproc_gettime_4_svc(void *, struct svc_req *);
723 extern "C" struct netbuf * rpcbproc_uaddr2taddr_4(char **, CLIENT *);
724 extern "C" struct netbuf * rpcbproc_uaddr2taddr_4_svc(char **, struct svc_req *);
725 extern "C" char ** rpcbproc_taddr2uaddr_4(struct netbuf *, CLIENT *);
726 extern "C" char ** rpcbproc_taddr2uaddr_4_svc(struct netbuf *, struct svc_req *);
727 #define RPCBPROC_GETVERSADDR ((u_int32_t)9)
728 extern "C" char ** rpcbproc_getversaddr_4(rpcb *, CLIENT *);
729 extern "C" char ** rpcbproc_getversaddr_4_svc(rpcb *, struct svc_req *);
730 #define RPCBPROC_INDIRECT ((u_int32_t)10)
731 extern "C" rpcb_rmtcallres * rpcbproc_indirect_4(rpcb_rmtcallargs *, CLIENT *);
732 extern "C" rpcb_rmtcallres * rpcbproc_indirect_4_svc(rpcb_rmtcallargs *, struct svc_req *);
733 #define RPCBPROC_GETADDRLIST ((u_int32_t)11)
734 extern "C" rpcb_entry_list_ptr * rpcbproc_getaddrlist_4(rpcb *, CLIENT *);
735 extern "C" rpcb_entry_list_ptr * rpcbproc_getaddrlist_4_svc(rpcb *, struct svc_req *);
736 #define RPCBPROC_GETSTAT ((u_int32_t)12)
737 extern "C" rpcb_stat * rpcbproc_getstat_4(void *, CLIENT *);
738 extern "C" rpcb_stat * rpcbproc_getstat_4_svc(void *, struct svc_req *);
739
740 #elif __STDC__
741 extern bool_t * rpcbproc_set_4(rpcb *, CLIENT *);
742 extern bool_t * rpcbproc_set_4_svc(rpcb *, struct svc_req *);
743 extern bool_t * rpcbproc_unset_4(rpcb *, CLIENT *);
744 extern bool_t * rpcbproc_unset_4_svc(rpcb *, struct svc_req *);
745 extern char ** rpcbproc_getaddr_4(rpcb *, CLIENT *);
746 extern char ** rpcbproc_getaddr_4_svc(rpcb *, struct svc_req *);
747 extern rpcblist_ptr * rpcbproc_dump_4(void *, CLIENT *);
748 extern rpcblist_ptr * rpcbproc_dump_4_svc(void *, struct svc_req *);
749 #define RPCBPROC_BCAST ((u_int32_t)RPCBPROC_CALLIT)
750 extern rpcb_rmtcallres * rpcbproc_bcast_4(rpcb_rmtcallargs *, CLIENT *);
751 extern rpcb_rmtcallres * rpcbproc_bcast_4_svc(rpcb_rmtcallargs *, struct svc_req *);
752 extern u_int * rpcbproc_gettime_4(void *, CLIENT *);
753 extern u_int * rpcbproc_gettime_4_svc(void *, struct svc_req *);
754 extern struct netbuf * rpcbproc_uaddr2taddr_4(char **, CLIENT *);
755 extern struct netbuf * rpcbproc_uaddr2taddr_4_svc(char **, struct svc_req *);
756 extern char ** rpcbproc_taddr2uaddr_4(struct netbuf *, CLIENT *);
757 extern char ** rpcbproc_taddr2uaddr_4_svc(struct netbuf *, struct svc_req *);
758 #define RPCBPROC_GETVERSADDR ((u_int32_t)9)
759 extern char ** rpcbproc_getversaddr_4(rpcb *, CLIENT *);
760 extern char ** rpcbproc_getversaddr_4_svc(rpcb *, struct svc_req *);
761 #define RPCBPROC_INDIRECT ((u_int32_t)10)
762 extern rpcb_rmtcallres * rpcbproc_indirect_4(rpcb_rmtcallargs *, CLIENT *);
763 extern rpcb_rmtcallres * rpcbproc_indirect_4_svc(rpcb_rmtcallargs *, struct svc_req *);
764 #define RPCBPROC_GETADDRLIST ((u_int32_t)11)
765 extern rpcb_entry_list_ptr * rpcbproc_getaddrlist_4(rpcb *, CLIENT *);
766 extern rpcb_entry_list_ptr * rpcbproc_getaddrlist_4_svc(rpcb *, struct svc_req *);
767 #define RPCBPROC_GETSTAT ((u_int32_t)12)
768 extern rpcb_stat * rpcbproc_getstat_4(void *, CLIENT *);
769 extern rpcb_stat * rpcbproc_getstat_4_svc(void *, struct svc_req *);
770
771 #else /* Old Style C */
772 extern bool_t * rpcbproc_set_4();
773 extern bool_t * rpcbproc_set_4_svc();
774 extern bool_t * rpcbproc_unset_4();
775 extern bool_t * rpcbproc_unset_4_svc();
776 extern char ** rpcbproc_getaddr_4();
777 extern char ** rpcbproc_getaddr_4_svc();
778 extern rpcblist_ptr * rpcbproc_dump_4();
779 extern rpcblist_ptr * rpcbproc_dump_4_svc();
780 #define RPCBPROC_BCAST ((u_int32_t)RPCBPROC_CALLIT)
781 extern rpcb_rmtcallres * rpcbproc_bcast_4();
782 extern rpcb_rmtcallres * rpcbproc_bcast_4_svc();
783 extern u_int * rpcbproc_gettime_4();
784 extern u_int * rpcbproc_gettime_4_svc();
785 extern struct netbuf * rpcbproc_uaddr2taddr_4();
786 extern struct netbuf * rpcbproc_uaddr2taddr_4_svc();
787 extern char ** rpcbproc_taddr2uaddr_4();
788 extern char ** rpcbproc_taddr2uaddr_4_svc();
789 #define RPCBPROC_GETVERSADDR ((u_int32_t)9)
790 extern char ** rpcbproc_getversaddr_4();
791 extern char ** rpcbproc_getversaddr_4_svc();
792 #define RPCBPROC_INDIRECT ((u_int32_t)10)
793 extern rpcb_rmtcallres * rpcbproc_indirect_4();
794 extern rpcb_rmtcallres * rpcbproc_indirect_4_svc();
795 #define RPCBPROC_GETADDRLIST ((u_int32_t)11)
796 extern rpcb_entry_list_ptr * rpcbproc_getaddrlist_4();
797 extern rpcb_entry_list_ptr * rpcbproc_getaddrlist_4_svc();
798 #define RPCBPROC_GETSTAT ((u_int32_t)12)
799 extern rpcb_stat * rpcbproc_getstat_4();
800 extern rpcb_stat * rpcbproc_getstat_4_svc();
801 #endif /* Old Style C */
802
803 #endif /* !_RPCB_PROT_H_RPCGEN */