1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
|
/*
* Please do not edit this file.
* It was generated using rpcgen.
*/
#ifndef _AUTOFS_WEBNFS_H_RPCGEN
#define _AUTOFS_WEBNFS_H_RPCGEN
#include <rpc/rpc.h>
#ifndef _KERNEL
#include <synch.h>
#include <thread.h>
#endif /* !_KERNEL */
#ifdef __cplusplus
extern "C" {
#endif
#define WNL_PORT 2049
#define WNL_MAXDATA 8192
#define WNL_MAXNAMLEN 255
#define WNL_FHSIZE 32
#define WNL_FIFO_DEV -1
#define WNL_NATIVEPATH 0x80
#define WNL_SEC_NEGO 0x81
#define WNLMODE_FMT 0170000
#define WNLMODE_DIR 0040000
#define WNLMODE_CHR 0020000
#define WNLMODE_BLK 0060000
#define WNLMODE_REG 0100000
#define WNLMODE_LNK 0120000
#define WNLMODE_SOCK 0140000
#define WNLMODE_FIFO 0010000
enum wnl_stat {
WNL_OK = 0,
WNLERR_PERM = 1,
WNLERR_NOENT = 2,
WNLERR_IO = 5,
WNLERR_NXIO = 6,
WNLERR_ACCES = 13,
WNLERR_EXIST = 17,
WNLERR_XDEV = 18,
WNLERR_NODEV = 19,
WNLERR_NOTDIR = 20,
WNLERR_ISDIR = 21,
WNLERR_INVAL = 22,
WNLERR_FBIG = 27,
WNLERR_NOSPC = 28,
WNLERR_ROFS = 30,
WNLERR_OPNOTSUPP = 45,
WNLERR_NAMETOOLONG = 63,
WNLERR_NOTEMPTY = 66,
WNLERR_DQUOT = 69,
WNLERR_STALE = 70,
WNLERR_REMOTE = 71,
WNLERR_WFLUSH = 72
};
typedef enum wnl_stat wnl_stat;
enum wnl_ftype {
WNL_NON = 0,
WNL_REG = 1,
WNL_DIR = 2,
WNL_BLK = 3,
WNL_CHR = 4,
WNL_LNK = 5,
WNL_SOCK = 6,
WNL_BAD = 7,
WNL_FIFO = 8
};
typedef enum wnl_ftype wnl_ftype;
struct wnl_fh {
char data[WNL_FHSIZE];
};
typedef struct wnl_fh wnl_fh;
struct wnl_time {
u_int seconds;
u_int useconds;
};
typedef struct wnl_time wnl_time;
struct wnl_fattr {
wnl_ftype type;
u_int mode;
u_int nlink;
u_int uid;
u_int gid;
u_int size;
u_int blocksize;
u_int rdev;
u_int blocks;
u_int fsid;
u_int fileid;
wnl_time atime;
wnl_time mtime;
wnl_time ctime;
};
typedef struct wnl_fattr wnl_fattr;
typedef char *wnl_filename;
struct wnl_diropargs {
wnl_fh dir;
wnl_filename name;
};
typedef struct wnl_diropargs wnl_diropargs;
struct wnl_diropokres {
wnl_fh file;
wnl_fattr attributes;
};
typedef struct wnl_diropokres wnl_diropokres;
struct wnl_diropres {
wnl_stat status;
union {
wnl_diropokres wnl_diropres;
} wnl_diropres_u;
};
typedef struct wnl_diropres wnl_diropres;
#define WNL3_FHSIZE 64
typedef u_longlong_t wnl_uint64;
typedef longlong_t wnl_int64;
typedef u_int wnl_uint32;
typedef char *wnl_filename3;
typedef wnl_uint64 wnl_fileid3;
typedef wnl_uint32 wnl_uid3;
typedef wnl_uint32 wnl_gid3;
typedef wnl_uint64 wnl_size3;
typedef wnl_uint32 wnl_mode3;
enum wnl_stat3 {
WNL3_OK = 0,
WNL3ERR_PERM = 1,
WNL3ERR_NOENT = 2,
WNL3ERR_IO = 5,
WNL3ERR_NXIO = 6,
WNL3ERR_ACCES = 13,
WNL3ERR_EXIST = 17,
WNL3ERR_XDEV = 18,
WNL3ERR_NODEV = 19,
WNL3ERR_NOTDIR = 20,
WNL3ERR_ISDIR = 21,
WNL3ERR_INVAL = 22,
WNL3ERR_FBIG = 27,
WNL3ERR_NOSPC = 28,
WNL3ERR_ROFS = 30,
WNL3ERR_MLINK = 31,
WNL3ERR_NAMETOOLONG = 63,
WNL3ERR_NOTEMPTY = 66,
WNL3ERR_DQUOT = 69,
WNL3ERR_STALE = 70,
WNL3ERR_REMOTE = 71,
WNL3ERR_BADHANDLE = 10001,
WNL3ERR_NOT_SYNC = 10002,
WNL3ERR_BAD_COOKIE = 10003,
WNL3ERR_NOTSUPP = 10004,
WNL3ERR_TOOSMALL = 10005,
WNL3ERR_SERVERFAULT = 10006,
WNL3ERR_BADTYPE = 10007,
WNL3ERR_JUKEBOX = 10008
};
typedef enum wnl_stat3 wnl_stat3;
enum wnl_ftype3 {
WNL_3REG = 1,
WNL_3DIR = 2,
WNL_3BLK = 3,
WNL_3CHR = 4,
WNL_3LNK = 5,
WNL_3SOCK = 6,
WNL_3FIFO = 7
};
typedef enum wnl_ftype3 wnl_ftype3;
struct wnl_specdata3 {
wnl_uint32 specdata1;
wnl_uint32 specdata2;
};
typedef struct wnl_specdata3 wnl_specdata3;
struct wnl_fh3 {
struct {
u_int data_len;
char *data_val;
} data;
};
typedef struct wnl_fh3 wnl_fh3;
struct wnl_time3 {
wnl_uint32 seconds;
wnl_uint32 nseconds;
};
typedef struct wnl_time3 wnl_time3;
struct wnl_fattr3 {
wnl_ftype3 type;
wnl_mode3 mode;
wnl_uint32 nlink;
wnl_uid3 uid;
wnl_gid3 gid;
wnl_size3 size;
wnl_size3 used;
wnl_specdata3 rdev;
wnl_uint64 fsid;
wnl_fileid3 fileid;
wnl_time3 atime;
wnl_time3 mtime;
wnl_time3 ctime;
};
typedef struct wnl_fattr3 wnl_fattr3;
struct wnl_post_op_attr {
bool_t attributes_follow;
union {
wnl_fattr3 attributes;
} wnl_post_op_attr_u;
};
typedef struct wnl_post_op_attr wnl_post_op_attr;
struct wln_post_op_fh3 {
bool_t handle_follows;
union {
wnl_fh3 handle;
} wln_post_op_fh3_u;
};
typedef struct wln_post_op_fh3 wln_post_op_fh3;
struct wnl_diropargs3 {
wnl_fh3 dir;
wnl_filename3 name;
};
typedef struct wnl_diropargs3 wnl_diropargs3;
struct WNL_LOOKUP3args {
wnl_diropargs3 what;
};
typedef struct WNL_LOOKUP3args WNL_LOOKUP3args;
struct WNL_LOOKUP3resok {
wnl_fh3 object;
wnl_post_op_attr obj_attributes;
wnl_post_op_attr dir_attributes;
};
typedef struct WNL_LOOKUP3resok WNL_LOOKUP3resok;
struct WNL_LOOKUP3resfail {
wnl_post_op_attr dir_attributes;
};
typedef struct WNL_LOOKUP3resfail WNL_LOOKUP3resfail;
struct WNL_LOOKUP3res {
wnl_stat3 status;
union {
WNL_LOOKUP3resok res_ok;
WNL_LOOKUP3resfail res_fail;
} WNL_LOOKUP3res_u;
};
typedef struct WNL_LOOKUP3res WNL_LOOKUP3res;
#define MAX_FLAVORS 128
struct snego_t {
int cnt;
int array[MAX_FLAVORS];
};
typedef struct snego_t snego_t;
enum snego_stat {
SNEGO_SUCCESS = 0,
SNEGO_DEF_VALID = 1,
SNEGO_ARRAY_TOO_SMALL = 2,
SNEGO_FAILURE = 3
};
typedef enum snego_stat snego_stat;
#define WNL_PROGRAM 100003
#define WNL_V2 2
#if defined(__STDC__) || defined(__cplusplus)
#define WNLPROC_NULL 0
extern enum clnt_stat wnlproc_null_2(void *, void *, CLIENT *);
extern bool_t wnlproc_null_2_svc(void *, void *, struct svc_req *);
#define WNLPROC_LOOKUP 4
extern enum clnt_stat wnlproc_lookup_2(wnl_diropargs *, wnl_diropres *, CLIENT *);
extern bool_t wnlproc_lookup_2_svc(wnl_diropargs *, wnl_diropres *, struct svc_req *);
extern int wnl_program_2_freeresult(SVCXPRT *, xdrproc_t, caddr_t);
#else /* K&R C */
#define WNLPROC_NULL 0
extern enum clnt_stat wnlproc_null_2();
extern bool_t wnlproc_null_2_svc();
#define WNLPROC_LOOKUP 4
extern enum clnt_stat wnlproc_lookup_2();
extern bool_t wnlproc_lookup_2_svc();
extern int wnl_program_2_freeresult();
#endif /* K&R C */
#define WNL_V3 3
#if defined(__STDC__) || defined(__cplusplus)
#define WNLPROC3_NULL 0
extern enum clnt_stat wnlproc3_null_3(void *, void *, CLIENT *);
extern bool_t wnlproc3_null_3_svc(void *, void *, struct svc_req *);
#define WNLPROC3_LOOKUP 3
extern enum clnt_stat wnlproc3_lookup_3(WNL_LOOKUP3args *, WNL_LOOKUP3res *, CLIENT *);
extern bool_t wnlproc3_lookup_3_svc(WNL_LOOKUP3args *, WNL_LOOKUP3res *, struct svc_req *);
extern int wnl_program_3_freeresult(SVCXPRT *, xdrproc_t, caddr_t);
#else /* K&R C */
#define WNLPROC3_NULL 0
extern enum clnt_stat wnlproc3_null_3();
extern bool_t wnlproc3_null_3_svc();
#define WNLPROC3_LOOKUP 3
extern enum clnt_stat wnlproc3_lookup_3();
extern bool_t wnlproc3_lookup_3_svc();
extern int wnl_program_3_freeresult();
#endif /* K&R C */
#define WNL_V4 4
#if defined(__STDC__) || defined(__cplusplus)
#define WNLPROC4_NULL 0
extern enum clnt_stat wnlproc4_null_4(void *, void *, CLIENT *);
extern bool_t wnlproc4_null_4_svc(void *, void *, struct svc_req *);
extern int wnl_program_4_freeresult(SVCXPRT *, xdrproc_t, caddr_t);
#else /* K&R C */
#define WNLPROC4_NULL 0
extern enum clnt_stat wnlproc4_null_4();
extern bool_t wnlproc4_null_4_svc();
extern int wnl_program_4_freeresult();
#endif /* K&R C */
/* the xdr functions */
#if defined(__STDC__) || defined(__cplusplus)
extern bool_t xdr_wnl_stat(XDR *, wnl_stat*);
extern bool_t xdr_wnl_ftype(XDR *, wnl_ftype*);
extern bool_t xdr_wnl_fh(XDR *, wnl_fh*);
extern bool_t xdr_wnl_time(XDR *, wnl_time*);
extern bool_t xdr_wnl_fattr(XDR *, wnl_fattr*);
extern bool_t xdr_wnl_filename(XDR *, wnl_filename*);
extern bool_t xdr_wnl_diropargs(XDR *, wnl_diropargs*);
extern bool_t xdr_wnl_diropokres(XDR *, wnl_diropokres*);
extern bool_t xdr_wnl_diropres(XDR *, wnl_diropres*);
extern bool_t xdr_wnl_uint64(XDR *, wnl_uint64*);
extern bool_t xdr_wnl_int64(XDR *, wnl_int64*);
extern bool_t xdr_wnl_uint32(XDR *, wnl_uint32*);
extern bool_t xdr_wnl_filename3(XDR *, wnl_filename3*);
extern bool_t xdr_wnl_fileid3(XDR *, wnl_fileid3*);
extern bool_t xdr_wnl_uid3(XDR *, wnl_uid3*);
extern bool_t xdr_wnl_gid3(XDR *, wnl_gid3*);
extern bool_t xdr_wnl_size3(XDR *, wnl_size3*);
extern bool_t xdr_wnl_mode3(XDR *, wnl_mode3*);
extern bool_t xdr_wnl_stat3(XDR *, wnl_stat3*);
extern bool_t xdr_wnl_ftype3(XDR *, wnl_ftype3*);
extern bool_t xdr_wnl_specdata3(XDR *, wnl_specdata3*);
extern bool_t xdr_wnl_fh3(XDR *, wnl_fh3*);
extern bool_t xdr_wnl_time3(XDR *, wnl_time3*);
extern bool_t xdr_wnl_fattr3(XDR *, wnl_fattr3*);
extern bool_t xdr_wnl_post_op_attr(XDR *, wnl_post_op_attr*);
extern bool_t xdr_wln_post_op_fh3(XDR *, wln_post_op_fh3*);
extern bool_t xdr_wnl_diropargs3(XDR *, wnl_diropargs3*);
extern bool_t xdr_WNL_LOOKUP3args(XDR *, WNL_LOOKUP3args*);
extern bool_t xdr_WNL_LOOKUP3resok(XDR *, WNL_LOOKUP3resok*);
extern bool_t xdr_WNL_LOOKUP3resfail(XDR *, WNL_LOOKUP3resfail*);
extern bool_t xdr_WNL_LOOKUP3res(XDR *, WNL_LOOKUP3res*);
extern bool_t xdr_snego_t(XDR *, snego_t*);
extern bool_t xdr_snego_stat(XDR *, snego_stat*);
#else /* K&R C */
extern bool_t xdr_wnl_stat();
extern bool_t xdr_wnl_ftype();
extern bool_t xdr_wnl_fh();
extern bool_t xdr_wnl_time();
extern bool_t xdr_wnl_fattr();
extern bool_t xdr_wnl_filename();
extern bool_t xdr_wnl_diropargs();
extern bool_t xdr_wnl_diropokres();
extern bool_t xdr_wnl_diropres();
extern bool_t xdr_wnl_uint64();
extern bool_t xdr_wnl_int64();
extern bool_t xdr_wnl_uint32();
extern bool_t xdr_wnl_filename3();
extern bool_t xdr_wnl_fileid3();
extern bool_t xdr_wnl_uid3();
extern bool_t xdr_wnl_gid3();
extern bool_t xdr_wnl_size3();
extern bool_t xdr_wnl_mode3();
extern bool_t xdr_wnl_stat3();
extern bool_t xdr_wnl_ftype3();
extern bool_t xdr_wnl_specdata3();
extern bool_t xdr_wnl_fh3();
extern bool_t xdr_wnl_time3();
extern bool_t xdr_wnl_fattr3();
extern bool_t xdr_wnl_post_op_attr();
extern bool_t xdr_wln_post_op_fh3();
extern bool_t xdr_wnl_diropargs3();
extern bool_t xdr_WNL_LOOKUP3args();
extern bool_t xdr_WNL_LOOKUP3resok();
extern bool_t xdr_WNL_LOOKUP3resfail();
extern bool_t xdr_WNL_LOOKUP3res();
extern bool_t xdr_snego_t();
extern bool_t xdr_snego_stat();
#endif /* K&R C */
#ifdef __cplusplus
}
#endif
#endif /* !_AUTOFS_WEBNFS_H_RPCGEN */
|