BSD 4_4 release
[unix-history] / usr / src / lib / librpc / rpcsvc / rnusers.x
CommitLineData
ad787160
C
1/* @(#)rnusers.x 2.1 88/08/01 4.0 RPCSRC */
2/* @(#)rnusers.x 1.2 87/09/20 Copyr 1987 Sun Micro */
3
cfbe44a4
KM
4/*
5 * Sun RPC is a product of Sun Microsystems, Inc. and is provided for
6 * unrestricted use provided that this legend is included on all tape
7 * media and as a part of the software program in whole or part. Users
8 * may copy or modify Sun RPC without charge, but are not authorized
9 * to license or distribute it to anyone else except as part of a product or
10 * program developed by the user.
11 *
12 * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
13 * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
14 * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
15 *
16 * Sun RPC is provided with no support and without any obligation on the
17 * part of Sun Microsystems, Inc. to assist in its use, correction,
18 * modification or enhancement.
19 *
20 * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
21 * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
22 * OR ANY PART THEREOF.
23 *
24 * In no event will Sun Microsystems, Inc. be liable for any lost revenue
25 * or profits or other special, indirect and consequential damages, even if
26 * Sun has been advised of the possibility of such damages.
27 *
28 * Sun Microsystems, Inc.
29 * 2550 Garcia Avenue
30 * Mountain View, California 94043
31 */
32
33/*
ad787160 34 * Find out about remote users
cfbe44a4
KM
35 */
36
ad787160
C
37const MAXUSERS = 100;
38const MAXUTLEN = 256;
39
40struct utmp {
41 string ut_line<MAXUTLEN>;
42 string ut_name<MAXUTLEN>;
43 string ut_host<MAXUTLEN>;
44 int ut_time;
cfbe44a4
KM
45};
46
cfbe44a4 47
ad787160
C
48struct utmpidle {
49 utmp ui_utmp;
50 unsigned int ui_idle;
cfbe44a4
KM
51};
52
ad787160
C
53typedef utmp utmparr<MAXUSERS>;
54
55typedef utmpidle utmpidlearr<MAXUSERS>;
56
57program RUSERSPROG {
58 /*
59 * Includes idle information
60 */
61 version RUSERSVERS_IDLE {
62 int
63 RUSERSPROC_NUM(void) = 1;
95f51977 64
ad787160
C
65 utmpidlearr
66 RUSERSPROC_NAMES(void) = 2;
95f51977 67
ad787160
C
68 utmpidlearr
69 RUSERSPROC_ALLNAMES(void) = 3;
70 } = 1;
95f51977 71
ad787160
C
72 /*
73 * Old version does not include idle information
74 */
75 version RUSERSVERS_ORIG {
76 int
77 RUSERSPROC_NUM(void) = 1;
95f51977 78
ad787160
C
79 utmparr
80 RUSERSPROC_NAMES(void) = 2;
95f51977 81
ad787160
C
82 utmparr
83 RUSERSPROC_ALLNAMES(void) = 3;
84 } = 2;
85} = 100002;
86