xref: /titanic_41/usr/src/lib/gss_mechs/mech_krb5/krb5/rcache/rc_io.h (revision 505d05c73a6e56769f263d4803b22eddd168ee24)
1 #pragma ident	"%Z%%M%	%I%	%E% SMI"
2 /*
3  * lib/krb5/rcache/rc_io.h
4  *
5  * This file of the Kerberos V5 software is derived from public-domain code
6  * contributed by Daniel J. Bernstein, <brnstnd@acf10.nyu.edu>.
7  *
8  */
9 
10 /*
11  * Declarations for the I/O sub-package of the replay cache
12  */
13 
14 #ifndef KRB5_RC_IO_H
15 #define KRB5_RC_IO_H
16 
17 typedef struct krb5_rc_iostuff
18  {
19   int fd;
20 #ifdef MSDOS_FILESYSTEM
21   long mark;
22 #else
23   off_t mark; /* on newer systems, should be pos_t */
24 #endif
25   char *fn;
26  }
27 krb5_rc_iostuff;
28 
29 /* first argument is always iostuff for result file */
30 
31 krb5_error_code krb5_rc_io_creat
32 	(krb5_context,
33 		   krb5_rc_iostuff *,
34 		   char **);
35 krb5_error_code krb5_rc_io_open
36 	(krb5_context,
37 		   krb5_rc_iostuff *,
38 		   char *);
39 krb5_error_code krb5_rc_io_move
40 	(krb5_context,
41 		   krb5_rc_iostuff *,
42 		   krb5_rc_iostuff *);
43 krb5_error_code krb5_rc_io_write
44 	(krb5_context,
45 		   krb5_rc_iostuff *,
46 		   krb5_pointer,
47 		   unsigned int);
48 krb5_error_code krb5_rc_io_read
49 	(krb5_context,
50 		   krb5_rc_iostuff *,
51 		   krb5_pointer,
52 		   unsigned int);
53 krb5_error_code krb5_rc_io_close
54 	(krb5_context,
55 		   krb5_rc_iostuff *);
56 krb5_error_code krb5_rc_io_destroy
57 	(krb5_context,
58 		   krb5_rc_iostuff *);
59 krb5_error_code krb5_rc_io_mark
60 	(krb5_context,
61 		   krb5_rc_iostuff *);
62 krb5_error_code krb5_rc_io_unmark
63 	(krb5_context,
64 		   krb5_rc_iostuff *);
65 krb5_error_code krb5_rc_io_sync
66 	(krb5_context,
67 		   krb5_rc_iostuff *);
68 long krb5_rc_io_size
69 	(krb5_context,
70 		   krb5_rc_iostuff *);
71 #endif
72