xref: /original-bsd/sys/netccitt/x25acct.h (revision bacd16ee)
1 /*
2  * Copyright (c) University of British Columbia, 1984
3  * Copyright (c) 1990, 1993
4  *	The Regents of the University of California.  All rights reserved.
5  *
6  * This code is derived from software contributed to Berkeley by
7  * the Laboratory for Computation Vision and the Computer Science Department
8  * of the University of British Columbia.
9  *
10  * %sccs.include.redist.c%
11  *
12  *	@(#)x25acct.h	8.1 (Berkeley) 06/10/93
13  */
14 
15 /*
16  * Format of X.25 accounting record written
17  * to X25ACCTF whenever a circuit is closed.
18  */
19 
20 #ifdef waterloo
21 #define X25ACCTF	"/usr/adm/logs/x25acct"
22 #else
23 #define X25ACCTF	"/usr/adm/x25acct"
24 #endif
25 
26 struct	x25acct {
27 	time_t	x25acct_stime;		/* start time */
28 #ifdef waterloo
29 	u_long	x25acct_etime;		/* elapsed time (seconds) */
30 #else
31 	u_short	x25acct_etime;		/* elapsed time (seconds) */
32 #endif
33 	short	x25acct_uid;		/* user id */
34 	short	x25acct_net;		/* network id */
35 	u_short	x25acct_psize:4,	/* packet size */
36 		x25acct_addrlen:4,	/* x25acct_addr length */
37 		x25acct_revcharge:1,	/* reverse charging */
38 		x25acct_callin:1,	/* incoming call */
39 		x25acct_unused:6;
40 	char	x25acct_addr[8];	/* remote DTE address (in bcd) */
41 	char	x25acct_udata[4];	/* protocol id */
42 	long	x25acct_txcnt;		/* packets transmitted */
43 	long	x25acct_rxcnt;		/* packets received */
44 };
45