xref: /onnv-gate/usr/src/cmd/krb5/kadmin/ktutil/ktutil.h (revision 2881:ea6360e7e1c5)
10Sstevel@tonic-gate #pragma ident	"%Z%%M%	%I%	%E% SMI"
20Sstevel@tonic-gate 
30Sstevel@tonic-gate /*
40Sstevel@tonic-gate  * WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
50Sstevel@tonic-gate  *
60Sstevel@tonic-gate  *	Openvision retains the copyright to derivative works of
70Sstevel@tonic-gate  *	this source code.  Do *NOT* create a derivative of this
80Sstevel@tonic-gate  *	source code before consulting with your legal department.
90Sstevel@tonic-gate  *	Do *NOT* integrate *ANY* of this source code into another
100Sstevel@tonic-gate  *	product before consulting with your legal department.
110Sstevel@tonic-gate  *
120Sstevel@tonic-gate  *	For further information, read the top-level Openvision
130Sstevel@tonic-gate  *	copyright which is contained in the top-level MIT Kerberos
140Sstevel@tonic-gate  *	copyright.
150Sstevel@tonic-gate  *
160Sstevel@tonic-gate  * WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
170Sstevel@tonic-gate  *
180Sstevel@tonic-gate  */
190Sstevel@tonic-gate 
200Sstevel@tonic-gate 
210Sstevel@tonic-gate /*
220Sstevel@tonic-gate  * kadmin/ktutil/ktutil.h
230Sstevel@tonic-gate  *
240Sstevel@tonic-gate  * Copyright 1995 by the Massachusetts Institute of Technology.
250Sstevel@tonic-gate  * All Rights Reserved.
260Sstevel@tonic-gate  *
270Sstevel@tonic-gate  * Export of this software from the United States of America may
280Sstevel@tonic-gate  *   require a specific license from the United States Government.
290Sstevel@tonic-gate  *   It is the responsibility of any person or organization contemplating
300Sstevel@tonic-gate  *   export to obtain such a license before exporting.
31*2881Smp153739  *
320Sstevel@tonic-gate  * WITHIN THAT CONSTRAINT, permission to use, copy, modify, and
330Sstevel@tonic-gate  * distribute this software and its documentation for any purpose and
340Sstevel@tonic-gate  * without fee is hereby granted, provided that the above copyright
350Sstevel@tonic-gate  * notice appear in all copies and that both that copyright notice and
360Sstevel@tonic-gate  * this permission notice appear in supporting documentation, and that
370Sstevel@tonic-gate  * the name of M.I.T. not be used in advertising or publicity pertaining
380Sstevel@tonic-gate  * to distribution of the software without specific, written prior
390Sstevel@tonic-gate  * permission.  Furthermore if you modify this software you must label
400Sstevel@tonic-gate  * your software as modified software and not distribute it in such a
410Sstevel@tonic-gate  * fashion that it might be confused with the original M.I.T. software.
420Sstevel@tonic-gate  * M.I.T. makes no representations about the suitability of
430Sstevel@tonic-gate  * this software for any purpose.  It is provided "as is" without express
440Sstevel@tonic-gate  * or implied warranty.
45*2881Smp153739  *
460Sstevel@tonic-gate  */
470Sstevel@tonic-gate 
480Sstevel@tonic-gate typedef struct _krb5_kt_list {
49*2881Smp153739     struct _krb5_kt_list *next;
50*2881Smp153739     krb5_keytab_entry *entry;
510Sstevel@tonic-gate } *krb5_kt_list;
520Sstevel@tonic-gate 
53*2881Smp153739 krb5_error_code ktutil_free_kt_list (krb5_context, krb5_kt_list);
540Sstevel@tonic-gate 
55*2881Smp153739 krb5_error_code ktutil_delete (krb5_context, krb5_kt_list *, int);
560Sstevel@tonic-gate 
57*2881Smp153739 krb5_error_code ktutil_add (krb5_context,
58*2881Smp153739 			    krb5_kt_list *,
59*2881Smp153739 			    char *,
60*2881Smp153739 			    krb5_kvno,
61*2881Smp153739 			    char *,
62*2881Smp153739 			    int);
630Sstevel@tonic-gate 
64*2881Smp153739 krb5_error_code ktutil_read_keytab (krb5_context,
65*2881Smp153739 				    char *,
66*2881Smp153739 				    krb5_kt_list *);
670Sstevel@tonic-gate 
68*2881Smp153739 krb5_error_code ktutil_write_keytab (krb5_context,
69*2881Smp153739 				     krb5_kt_list,
70*2881Smp153739 				     char *);
710Sstevel@tonic-gate 
720Sstevel@tonic-gate #ifdef KRB5_KRB4_COMPAT
73*2881Smp153739 krb5_error_code ktutil_read_srvtab (krb5_context,
74*2881Smp153739 				    char *,
75*2881Smp153739 				    krb5_kt_list *);
76*2881Smp153739 krb5_error_code ktutil_write_srvtab (krb5_context,
77*2881Smp153739 				     krb5_kt_list,
78*2881Smp153739 				     char *);
79*2881Smp153739 #endif
80*2881Smp153739 
81*2881Smp153739 void ktutil_add_entry (int, char *[]);
82*2881Smp153739 
83*2881Smp153739 void ktutil_clear_list (int, char *[]);
840Sstevel@tonic-gate 
85*2881Smp153739 void ktutil_read_v5 (int, char *[]);
86*2881Smp153739 
87*2881Smp153739 void ktutil_read_v4 (int, char *[]);
88*2881Smp153739 
89*2881Smp153739 void ktutil_write_v5 (int, char *[]);
90*2881Smp153739 
91*2881Smp153739 void ktutil_write_v4 (int, char *[]);
92*2881Smp153739 
93*2881Smp153739 void ktutil_delete_entry (int, char *[]);
94*2881Smp153739 
95*2881Smp153739 void ktutil_list (int, char *[]);
96