xref: /illumos-gate/usr/src/cmd/krb5/kadmin/ktutil/ktutil.h (revision 2a8bcb4efb45d99ac41c94a75c396b362c414f7f)
1 /*
2  * WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
3  *
4  *	Openvision retains the copyright to derivative works of
5  *	this source code.  Do *NOT* create a derivative of this
6  *	source code before consulting with your legal department.
7  *	Do *NOT* integrate *ANY* of this source code into another
8  *	product before consulting with your legal department.
9  *
10  *	For further information, read the top-level Openvision
11  *	copyright which is contained in the top-level MIT Kerberos
12  *	copyright.
13  *
14  * WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
15  *
16  */
17 
18 
19 /*
20  * kadmin/ktutil/ktutil.h
21  *
22  * Copyright 1995 by the Massachusetts Institute of Technology.
23  * All Rights Reserved.
24  *
25  * Export of this software from the United States of America may
26  *   require a specific license from the United States Government.
27  *   It is the responsibility of any person or organization contemplating
28  *   export to obtain such a license before exporting.
29  *
30  * WITHIN THAT CONSTRAINT, permission to use, copy, modify, and
31  * distribute this software and its documentation for any purpose and
32  * without fee is hereby granted, provided that the above copyright
33  * notice appear in all copies and that both that copyright notice and
34  * this permission notice appear in supporting documentation, and that
35  * the name of M.I.T. not be used in advertising or publicity pertaining
36  * to distribution of the software without specific, written prior
37  * permission.  Furthermore if you modify this software you must label
38  * your software as modified software and not distribute it in such a
39  * fashion that it might be confused with the original M.I.T. software.
40  * M.I.T. makes no representations about the suitability of
41  * this software for any purpose.  It is provided "as is" without express
42  * or implied warranty.
43  *
44  */
45 
46 typedef struct _krb5_kt_list {
47     struct _krb5_kt_list *next;
48     krb5_keytab_entry *entry;
49 } *krb5_kt_list;
50 
51 krb5_error_code ktutil_free_kt_list (krb5_context, krb5_kt_list);
52 
53 krb5_error_code ktutil_delete (krb5_context, krb5_kt_list *, int);
54 
55 krb5_error_code ktutil_add (krb5_context,
56 			    krb5_kt_list *,
57 			    char *,
58 			    krb5_kvno,
59 			    char *,
60 			    int);
61 
62 krb5_error_code ktutil_read_keytab (krb5_context,
63 				    char *,
64 				    krb5_kt_list *);
65 
66 krb5_error_code ktutil_write_keytab (krb5_context,
67 				     krb5_kt_list,
68 				     char *);
69 
70 #ifdef KRB5_KRB4_COMPAT
71 krb5_error_code ktutil_read_srvtab (krb5_context,
72 				    char *,
73 				    krb5_kt_list *);
74 krb5_error_code ktutil_write_srvtab (krb5_context,
75 				     krb5_kt_list,
76 				     char *);
77 #endif
78 
79 void ktutil_add_entry (int, char *[]);
80 
81 void ktutil_clear_list (int, char *[]);
82 
83 void ktutil_read_v5 (int, char *[]);
84 
85 void ktutil_read_v4 (int, char *[]);
86 
87 void ktutil_write_v5 (int, char *[]);
88 
89 void ktutil_write_v4 (int, char *[]);
90 
91 void ktutil_delete_entry (int, char *[]);
92 
93 void ktutil_list (int, char *[]);
94