xref: /freebsd/crypto/heimdal/lib/krb5/krb5-protos.h (revision 77a0943ded95b9e6438f7db70c4a28e4d93946d4)
1 /* This is a generated file */
2 #ifndef __krb5_protos_h__
3 #define __krb5_protos_h__
4 
5 #ifdef __STDC__
6 #include <stdarg.h>
7 #ifndef __P
8 #define __P(x) x
9 #endif
10 #else
11 #ifndef __P
12 #define __P(x) ()
13 #endif
14 #endif
15 
16 #if !defined(__GNUC__) && !defined(__attribute__)
17 #define __attribute__(x)
18 #endif
19 
20 krb5_error_code
21 krb524_convert_creds_kdc __P((
22 	krb5_context context,
23 	krb5_ccache ccache,
24 	krb5_creds *in_cred,
25 	struct credentials *v4creds));
26 
27 krb5_error_code
28 krb5_425_conv_principal __P((
29 	krb5_context context,
30 	const char *name,
31 	const char *instance,
32 	const char *realm,
33 	krb5_principal *princ));
34 
35 krb5_error_code
36 krb5_425_conv_principal_ext __P((
37 	krb5_context context,
38 	const char *name,
39 	const char *instance,
40 	const char *realm,
41 	krb5_boolean (*func)(krb5_context, krb5_principal),
42 	krb5_boolean resolve,
43 	krb5_principal *princ));
44 
45 krb5_error_code
46 krb5_524_conv_principal __P((
47 	krb5_context context,
48 	const krb5_principal principal,
49 	char *name,
50 	char *instance,
51 	char *realm));
52 
53 krb5_error_code
54 krb5_abort __P((
55 	krb5_context context,
56 	krb5_error_code code,
57 	const char *fmt,
58 	...))
59     __attribute__ ((noreturn, format (printf, 3, 4)));
60 
61 krb5_error_code
62 krb5_abortx __P((
63 	krb5_context context,
64 	const char *fmt,
65 	...))
66     __attribute__ ((noreturn, format (printf, 2, 3)));
67 
68 krb5_error_code
69 krb5_add_et_list __P((
70 	krb5_context context,
71 	void (*func)(struct et_list **)));
72 
73 krb5_error_code
74 krb5_add_extra_addresses __P((
75 	krb5_context context,
76 	krb5_addresses *addresses));
77 
78 krb5_error_code
79 krb5_addlog_dest __P((
80 	krb5_context context,
81 	krb5_log_facility *f,
82 	const char *p));
83 
84 krb5_error_code
85 krb5_addlog_func __P((
86 	krb5_context context,
87 	krb5_log_facility *fac,
88 	int min,
89 	int max,
90 	krb5_log_log_func_t log,
91 	krb5_log_close_func_t close,
92 	void *data));
93 
94 krb5_error_code
95 krb5_addr2sockaddr __P((
96 	const krb5_address *addr,
97 	struct sockaddr *sa,
98 	int *sa_size,
99 	int port));
100 
101 krb5_boolean
102 krb5_address_compare __P((
103 	krb5_context context,
104 	const krb5_address *addr1,
105 	const krb5_address *addr2));
106 
107 int
108 krb5_address_order __P((
109 	krb5_context context,
110 	const krb5_address *addr1,
111 	const krb5_address *addr2));
112 
113 krb5_boolean
114 krb5_address_search __P((
115 	krb5_context context,
116 	const krb5_address *addr,
117 	const krb5_addresses *addrlist));
118 
119 krb5_error_code
120 krb5_aname_to_localname __P((
121 	krb5_context context,
122 	krb5_const_principal aname,
123 	size_t lnsize,
124 	char *lname));
125 
126 krb5_error_code
127 krb5_anyaddr __P((
128 	int af,
129 	struct sockaddr *sa,
130 	int *sa_size,
131 	int port));
132 
133 krb5_error_code
134 krb5_append_addresses __P((
135 	krb5_context context,
136 	krb5_addresses *dest,
137 	const krb5_addresses *source));
138 
139 krb5_error_code
140 krb5_auth_con_free __P((
141 	krb5_context context,
142 	krb5_auth_context auth_context));
143 
144 krb5_error_code
145 krb5_auth_con_getaddrs __P((
146 	krb5_context context,
147 	krb5_auth_context auth_context,
148 	krb5_address **local_addr,
149 	krb5_address **remote_addr));
150 
151 krb5_error_code
152 krb5_auth_con_getflags __P((
153 	krb5_context context,
154 	krb5_auth_context auth_context,
155 	int32_t *flags));
156 
157 krb5_error_code
158 krb5_auth_con_getkey __P((
159 	krb5_context context,
160 	krb5_auth_context auth_context,
161 	krb5_keyblock **keyblock));
162 
163 krb5_error_code
164 krb5_auth_con_getlocalsubkey __P((
165 	krb5_context context,
166 	krb5_auth_context auth_context,
167 	krb5_keyblock **keyblock));
168 
169 krb5_error_code
170 krb5_auth_con_getremotesubkey __P((
171 	krb5_context context,
172 	krb5_auth_context auth_context,
173 	krb5_keyblock **keyblock));
174 
175 krb5_error_code
176 krb5_auth_con_init __P((
177 	krb5_context context,
178 	krb5_auth_context *auth_context));
179 
180 krb5_error_code
181 krb5_auth_con_setaddrs __P((
182 	krb5_context context,
183 	krb5_auth_context auth_context,
184 	krb5_address *local_addr,
185 	krb5_address *remote_addr));
186 
187 krb5_error_code
188 krb5_auth_con_setaddrs_from_fd __P((
189 	krb5_context context,
190 	krb5_auth_context auth_context,
191 	void *p_fd));
192 
193 krb5_error_code
194 krb5_auth_con_setflags __P((
195 	krb5_context context,
196 	krb5_auth_context auth_context,
197 	int32_t flags));
198 
199 krb5_error_code
200 krb5_auth_con_setkey __P((
201 	krb5_context context,
202 	krb5_auth_context auth_context,
203 	krb5_keyblock *keyblock));
204 
205 krb5_error_code
206 krb5_auth_con_setlocalsubkey __P((
207 	krb5_context context,
208 	krb5_auth_context auth_context,
209 	krb5_keyblock *keyblock));
210 
211 krb5_error_code
212 krb5_auth_con_setremotesubkey __P((
213 	krb5_context context,
214 	krb5_auth_context auth_context,
215 	krb5_keyblock *keyblock));
216 
217 krb5_error_code
218 krb5_auth_con_setuserkey __P((
219 	krb5_context context,
220 	krb5_auth_context auth_context,
221 	krb5_keyblock *keyblock));
222 
223 krb5_error_code
224 krb5_auth_getauthenticator __P((
225 	krb5_context context,
226 	krb5_auth_context auth_context,
227 	krb5_authenticator *authenticator));
228 
229 krb5_error_code
230 krb5_auth_getcksumtype __P((
231 	krb5_context context,
232 	krb5_auth_context auth_context,
233 	krb5_cksumtype *cksumtype));
234 
235 krb5_error_code
236 krb5_auth_getkeytype __P((
237 	krb5_context context,
238 	krb5_auth_context auth_context,
239 	krb5_keytype *keytype));
240 
241 krb5_error_code
242 krb5_auth_getlocalseqnumber __P((
243 	krb5_context context,
244 	krb5_auth_context auth_context,
245 	int32_t *seqnumber));
246 
247 krb5_error_code
248 krb5_auth_getremoteseqnumber __P((
249 	krb5_context context,
250 	krb5_auth_context auth_context,
251 	int32_t *seqnumber));
252 
253 krb5_error_code
254 krb5_auth_setcksumtype __P((
255 	krb5_context context,
256 	krb5_auth_context auth_context,
257 	krb5_cksumtype cksumtype));
258 
259 krb5_error_code
260 krb5_auth_setkeytype __P((
261 	krb5_context context,
262 	krb5_auth_context auth_context,
263 	krb5_keytype keytype));
264 
265 krb5_error_code
266 krb5_auth_setlocalseqnumber __P((
267 	krb5_context context,
268 	krb5_auth_context auth_context,
269 	int32_t seqnumber));
270 
271 krb5_error_code
272 krb5_auth_setremoteseqnumber __P((
273 	krb5_context context,
274 	krb5_auth_context auth_context,
275 	int32_t seqnumber));
276 
277 krb5_error_code
278 krb5_build_ap_req __P((
279 	krb5_context context,
280 	krb5_enctype enctype,
281 	krb5_creds *cred,
282 	krb5_flags ap_options,
283 	krb5_data authenticator,
284 	krb5_data *retdata));
285 
286 krb5_error_code
287 krb5_build_authenticator __P((
288 	krb5_context context,
289 	krb5_auth_context auth_context,
290 	krb5_enctype enctype,
291 	krb5_creds *cred,
292 	Checksum *cksum,
293 	Authenticator **auth_result,
294 	krb5_data *result));
295 
296 krb5_error_code
297 krb5_build_principal __P((
298 	krb5_context context,
299 	krb5_principal *principal,
300 	int rlen,
301 	krb5_const_realm realm,
302 	...));
303 
304 krb5_error_code
305 krb5_build_principal_ext __P((
306 	krb5_context context,
307 	krb5_principal *principal,
308 	int rlen,
309 	krb5_const_realm realm,
310 	...));
311 
312 krb5_error_code
313 krb5_build_principal_va __P((
314 	krb5_context context,
315 	krb5_principal *principal,
316 	int rlen,
317 	krb5_const_realm realm,
318 	va_list ap));
319 
320 krb5_error_code
321 krb5_build_principal_va_ext __P((
322 	krb5_context context,
323 	krb5_principal *principal,
324 	int rlen,
325 	krb5_const_realm realm,
326 	va_list ap));
327 
328 krb5_error_code
329 krb5_cc_close __P((
330 	krb5_context context,
331 	krb5_ccache id));
332 
333 krb5_error_code
334 krb5_cc_copy_cache __P((
335 	krb5_context context,
336 	const krb5_ccache from,
337 	krb5_ccache to));
338 
339 krb5_error_code
340 krb5_cc_default __P((
341 	krb5_context context,
342 	krb5_ccache *id));
343 
344 const char*
345 krb5_cc_default_name __P((krb5_context context));
346 
347 krb5_error_code
348 krb5_cc_destroy __P((
349 	krb5_context context,
350 	krb5_ccache id));
351 
352 krb5_error_code
353 krb5_cc_end_seq_get __P((
354 	krb5_context context,
355 	const krb5_ccache id,
356 	krb5_cc_cursor *cursor));
357 
358 krb5_error_code
359 krb5_cc_gen_new __P((
360 	krb5_context context,
361 	const krb5_cc_ops *ops,
362 	krb5_ccache *id));
363 
364 const char*
365 krb5_cc_get_name __P((
366 	krb5_context context,
367 	krb5_ccache id));
368 
369 krb5_error_code
370 krb5_cc_get_principal __P((
371 	krb5_context context,
372 	krb5_ccache id,
373 	krb5_principal *principal));
374 
375 const char*
376 krb5_cc_get_type __P((
377 	krb5_context context,
378 	krb5_ccache id));
379 
380 krb5_error_code
381 krb5_cc_get_version __P((
382 	krb5_context context,
383 	const krb5_ccache id));
384 
385 krb5_error_code
386 krb5_cc_initialize __P((
387 	krb5_context context,
388 	krb5_ccache id,
389 	krb5_principal primary_principal));
390 
391 krb5_error_code
392 krb5_cc_next_cred __P((
393 	krb5_context context,
394 	const krb5_ccache id,
395 	krb5_creds *creds,
396 	krb5_cc_cursor *cursor));
397 
398 krb5_error_code
399 krb5_cc_register __P((
400 	krb5_context context,
401 	const krb5_cc_ops *ops,
402 	krb5_boolean override));
403 
404 krb5_error_code
405 krb5_cc_remove_cred __P((
406 	krb5_context context,
407 	krb5_ccache id,
408 	krb5_flags which,
409 	krb5_creds *cred));
410 
411 krb5_error_code
412 krb5_cc_resolve __P((
413 	krb5_context context,
414 	const char *name,
415 	krb5_ccache *id));
416 
417 krb5_error_code
418 krb5_cc_retrieve_cred __P((
419 	krb5_context context,
420 	krb5_ccache id,
421 	krb5_flags whichfields,
422 	const krb5_creds *mcreds,
423 	krb5_creds *creds));
424 
425 krb5_error_code
426 krb5_cc_set_flags __P((
427 	krb5_context context,
428 	krb5_ccache id,
429 	krb5_flags flags));
430 
431 krb5_error_code
432 krb5_cc_start_seq_get __P((
433 	krb5_context context,
434 	const krb5_ccache id,
435 	krb5_cc_cursor *cursor));
436 
437 krb5_error_code
438 krb5_cc_store_cred __P((
439 	krb5_context context,
440 	krb5_ccache id,
441 	krb5_creds *creds));
442 
443 krb5_error_code
444 krb5_change_password __P((
445 	krb5_context context,
446 	krb5_creds *creds,
447 	char *newpw,
448 	int *result_code,
449 	krb5_data *result_code_string,
450 	krb5_data *result_string));
451 
452 krb5_error_code
453 krb5_check_transited_realms __P((
454 	krb5_context context,
455 	const char *const *realms,
456 	int num_realms,
457 	int *bad_realm));
458 
459 krb5_boolean
460 krb5_checksum_is_collision_proof __P((
461 	krb5_context context,
462 	krb5_cksumtype type));
463 
464 krb5_boolean
465 krb5_checksum_is_keyed __P((
466 	krb5_context context,
467 	krb5_cksumtype type));
468 
469 krb5_error_code
470 krb5_checksumsize __P((
471 	krb5_context context,
472 	krb5_cksumtype type,
473 	size_t *size));
474 
475 krb5_error_code
476 krb5_closelog __P((
477 	krb5_context context,
478 	krb5_log_facility *fac));
479 
480 krb5_boolean
481 krb5_compare_creds __P((
482 	krb5_context context,
483 	krb5_flags whichfields,
484 	const krb5_creds *mcreds,
485 	const krb5_creds *creds));
486 
487 krb5_error_code
488 krb5_config_file_free __P((
489 	krb5_context context,
490 	krb5_config_section *s));
491 
492 void
493 krb5_config_free_strings __P((char **strings));
494 
495 const void *
496 krb5_config_get __P((
497 	krb5_context context,
498 	krb5_config_section *c,
499 	int type,
500 	...));
501 
502 krb5_boolean
503 krb5_config_get_bool __P((
504 	krb5_context context,
505 	krb5_config_section *c,
506 	...));
507 
508 krb5_boolean
509 krb5_config_get_bool_default __P((
510 	krb5_context context,
511 	krb5_config_section *c,
512 	krb5_boolean def_value,
513 	...));
514 
515 int
516 krb5_config_get_int __P((
517 	krb5_context context,
518 	krb5_config_section *c,
519 	...));
520 
521 int
522 krb5_config_get_int_default __P((
523 	krb5_context context,
524 	krb5_config_section *c,
525 	int def_value,
526 	...));
527 
528 const krb5_config_binding *
529 krb5_config_get_list __P((
530 	krb5_context context,
531 	krb5_config_section *c,
532 	...));
533 
534 const void *
535 krb5_config_get_next __P((
536 	krb5_context context,
537 	krb5_config_section *c,
538 	krb5_config_binding **pointer,
539 	int type,
540 	...));
541 
542 const char *
543 krb5_config_get_string __P((
544 	krb5_context context,
545 	krb5_config_section *c,
546 	...));
547 
548 char**
549 krb5_config_get_strings __P((
550 	krb5_context context,
551 	krb5_config_section *c,
552 	...));
553 
554 int
555 krb5_config_get_time __P((
556 	krb5_context context,
557 	krb5_config_section *c,
558 	...));
559 
560 int
561 krb5_config_get_time_default __P((
562 	krb5_context context,
563 	krb5_config_section *c,
564 	int def_value,
565 	...));
566 
567 krb5_error_code
568 krb5_config_parse_file __P((
569 	const char *fname,
570 	krb5_config_section **res));
571 
572 krb5_error_code
573 krb5_config_parse_file_debug __P((
574 	const char *fname,
575 	krb5_config_section **res,
576 	unsigned *lineno,
577 	char **error_message));
578 
579 const void *
580 krb5_config_vget __P((
581 	krb5_context context,
582 	krb5_config_section *c,
583 	int type,
584 	va_list args));
585 
586 krb5_boolean
587 krb5_config_vget_bool __P((
588 	krb5_context context,
589 	krb5_config_section *c,
590 	va_list args));
591 
592 krb5_boolean
593 krb5_config_vget_bool_default __P((
594 	krb5_context context,
595 	krb5_config_section *c,
596 	krb5_boolean def_value,
597 	va_list args));
598 
599 int
600 krb5_config_vget_int __P((
601 	krb5_context context,
602 	krb5_config_section *c,
603 	va_list args));
604 
605 int
606 krb5_config_vget_int_default __P((
607 	krb5_context context,
608 	krb5_config_section *c,
609 	int def_value,
610 	va_list args));
611 
612 const krb5_config_binding *
613 krb5_config_vget_list __P((
614 	krb5_context context,
615 	krb5_config_section *c,
616 	va_list args));
617 
618 const void *
619 krb5_config_vget_next __P((
620 	krb5_context context,
621 	krb5_config_section *c,
622 	krb5_config_binding **pointer,
623 	int type,
624 	va_list args));
625 
626 const char *
627 krb5_config_vget_string __P((
628 	krb5_context context,
629 	krb5_config_section *c,
630 	va_list args));
631 
632 char **
633 krb5_config_vget_strings __P((
634 	krb5_context context,
635 	krb5_config_section *c,
636 	va_list args));
637 
638 int
639 krb5_config_vget_time __P((
640 	krb5_context context,
641 	krb5_config_section *c,
642 	va_list args));
643 
644 int
645 krb5_config_vget_time_default __P((
646 	krb5_context context,
647 	krb5_config_section *c,
648 	int def_value,
649 	va_list args));
650 
651 krb5_error_code
652 krb5_copy_address __P((
653 	krb5_context context,
654 	const krb5_address *inaddr,
655 	krb5_address *outaddr));
656 
657 krb5_error_code
658 krb5_copy_addresses __P((
659 	krb5_context context,
660 	const krb5_addresses *inaddr,
661 	krb5_addresses *outaddr));
662 
663 krb5_error_code
664 krb5_copy_creds __P((
665 	krb5_context context,
666 	const krb5_creds *incred,
667 	krb5_creds **outcred));
668 
669 krb5_error_code
670 krb5_copy_creds_contents __P((
671 	krb5_context context,
672 	const krb5_creds *incred,
673 	krb5_creds *c));
674 
675 krb5_error_code
676 krb5_copy_data __P((
677 	krb5_context context,
678 	const krb5_data *indata,
679 	krb5_data **outdata));
680 
681 krb5_error_code
682 krb5_copy_host_realm __P((
683 	krb5_context context,
684 	const krb5_realm *from,
685 	krb5_realm **to));
686 
687 krb5_error_code
688 krb5_copy_keyblock __P((
689 	krb5_context context,
690 	const krb5_keyblock *inblock,
691 	krb5_keyblock **to));
692 
693 krb5_error_code
694 krb5_copy_keyblock_contents __P((
695 	krb5_context context,
696 	const krb5_keyblock *inblock,
697 	krb5_keyblock *to));
698 
699 krb5_error_code
700 krb5_copy_principal __P((
701 	krb5_context context,
702 	krb5_const_principal inprinc,
703 	krb5_principal *outprinc));
704 
705 krb5_error_code
706 krb5_copy_ticket __P((
707 	krb5_context context,
708 	const krb5_ticket *from,
709 	krb5_ticket **to));
710 
711 krb5_error_code
712 krb5_create_checksum __P((
713 	krb5_context context,
714 	krb5_crypto crypto,
715 	unsigned usage_or_type,
716 	void *data,
717 	size_t len,
718 	Checksum *result));
719 
720 krb5_error_code
721 krb5_crypto_destroy __P((
722 	krb5_context context,
723 	krb5_crypto crypto));
724 
725 krb5_error_code
726 krb5_crypto_init __P((
727 	krb5_context context,
728 	krb5_keyblock *key,
729 	krb5_enctype etype,
730 	krb5_crypto *crypto));
731 
732 krb5_error_code
733 krb5_data_alloc __P((
734 	krb5_data *p,
735 	int len));
736 
737 krb5_error_code
738 krb5_data_copy __P((
739 	krb5_data *p,
740 	const void *data,
741 	size_t len));
742 
743 void
744 krb5_data_free __P((krb5_data *p));
745 
746 krb5_error_code
747 krb5_data_realloc __P((
748 	krb5_data *p,
749 	int len));
750 
751 void
752 krb5_data_zero __P((krb5_data *p));
753 
754 krb5_error_code
755 krb5_decode_Authenticator __P((
756 	krb5_context context,
757 	const void *data,
758 	size_t length,
759 	Authenticator *t,
760 	size_t *len));
761 
762 krb5_error_code
763 krb5_decode_ETYPE_INFO __P((
764 	krb5_context context,
765 	const void *data,
766 	size_t length,
767 	ETYPE_INFO *t,
768 	size_t *len));
769 
770 krb5_error_code
771 krb5_decode_EncAPRepPart __P((
772 	krb5_context context,
773 	const void *data,
774 	size_t length,
775 	EncAPRepPart *t,
776 	size_t *len));
777 
778 krb5_error_code
779 krb5_decode_EncASRepPart __P((
780 	krb5_context context,
781 	const void *data,
782 	size_t length,
783 	EncASRepPart *t,
784 	size_t *len));
785 
786 krb5_error_code
787 krb5_decode_EncKrbCredPart __P((
788 	krb5_context context,
789 	const void *data,
790 	size_t length,
791 	EncKrbCredPart *t,
792 	size_t *len));
793 
794 krb5_error_code
795 krb5_decode_EncTGSRepPart __P((
796 	krb5_context context,
797 	const void *data,
798 	size_t length,
799 	EncTGSRepPart *t,
800 	size_t *len));
801 
802 krb5_error_code
803 krb5_decode_EncTicketPart __P((
804 	krb5_context context,
805 	const void *data,
806 	size_t length,
807 	EncTicketPart *t,
808 	size_t *len));
809 
810 krb5_error_code
811 krb5_decode_ap_req __P((
812 	krb5_context context,
813 	const krb5_data *inbuf,
814 	krb5_ap_req *ap_req));
815 
816 krb5_error_code
817 krb5_decrypt __P((
818 	krb5_context context,
819 	krb5_crypto crypto,
820 	unsigned usage,
821 	void *data,
822 	size_t len,
823 	krb5_data *result));
824 
825 krb5_error_code
826 krb5_decrypt_EncryptedData __P((
827 	krb5_context context,
828 	krb5_crypto crypto,
829 	unsigned usage,
830 	EncryptedData *e,
831 	krb5_data *result));
832 
833 krb5_error_code
834 krb5_decrypt_ticket __P((
835 	krb5_context context,
836 	Ticket *ticket,
837 	krb5_keyblock *key,
838 	EncTicketPart *out,
839 	krb5_flags flags));
840 
841 krb5_error_code
842 krb5_domain_x500_decode __P((
843 	krb5_data tr,
844 	char ***realms,
845 	int *num_realms,
846 	const char *client_realm,
847 	const char *server_realm));
848 
849 krb5_error_code
850 krb5_domain_x500_encode __P((
851 	char **realms,
852 	int num_realms,
853 	krb5_data *encoding));
854 
855 krb5_error_code
856 krb5_encode_Authenticator __P((
857 	krb5_context context,
858 	void *data,
859 	size_t length,
860 	Authenticator *t,
861 	size_t *len));
862 
863 krb5_error_code
864 krb5_encode_ETYPE_INFO __P((
865 	krb5_context context,
866 	void *data,
867 	size_t length,
868 	ETYPE_INFO *t,
869 	size_t *len));
870 
871 krb5_error_code
872 krb5_encode_EncAPRepPart __P((
873 	krb5_context context,
874 	void *data,
875 	size_t length,
876 	EncAPRepPart *t,
877 	size_t *len));
878 
879 krb5_error_code
880 krb5_encode_EncASRepPart __P((
881 	krb5_context context,
882 	void *data,
883 	size_t length,
884 	EncASRepPart *t,
885 	size_t *len));
886 
887 krb5_error_code
888 krb5_encode_EncKrbCredPart __P((
889 	krb5_context context,
890 	void *data,
891 	size_t length,
892 	EncKrbCredPart *t,
893 	size_t *len));
894 
895 krb5_error_code
896 krb5_encode_EncTGSRepPart __P((
897 	krb5_context context,
898 	void *data,
899 	size_t length,
900 	EncTGSRepPart *t,
901 	size_t *len));
902 
903 krb5_error_code
904 krb5_encode_EncTicketPart __P((
905 	krb5_context context,
906 	void *data,
907 	size_t length,
908 	EncTicketPart *t,
909 	size_t *len));
910 
911 krb5_error_code
912 krb5_encrypt __P((
913 	krb5_context context,
914 	krb5_crypto crypto,
915 	unsigned usage,
916 	void *data,
917 	size_t len,
918 	krb5_data *result));
919 
920 krb5_error_code
921 krb5_encrypt_EncryptedData __P((
922 	krb5_context context,
923 	krb5_crypto crypto,
924 	unsigned usage,
925 	void *data,
926 	size_t len,
927 	int kvno,
928 	EncryptedData *result));
929 
930 krb5_error_code
931 krb5_enctype_to_keytype __P((
932 	krb5_context context,
933 	krb5_enctype etype,
934 	krb5_keytype *keytype));
935 
936 krb5_error_code
937 krb5_enctype_to_string __P((
938 	krb5_context context,
939 	krb5_enctype etype,
940 	char **string));
941 
942 krb5_error_code
943 krb5_enctype_valid __P((
944 	krb5_context context,
945 	krb5_enctype etype));
946 
947 krb5_boolean
948 krb5_enctypes_compatible_keys __P((
949 	krb5_context context,
950 	krb5_enctype etype1,
951 	krb5_enctype etype2));
952 
953 krb5_error_code
954 krb5_err __P((
955 	krb5_context context,
956 	int eval,
957 	krb5_error_code code,
958 	const char *fmt,
959 	...))
960     __attribute__ ((noreturn, format (printf, 4, 5)));
961 
962 krb5_error_code
963 krb5_errx __P((
964 	krb5_context context,
965 	int eval,
966 	const char *fmt,
967 	...))
968     __attribute__ ((noreturn, format (printf, 3, 4)));
969 
970 krb5_error_code
971 krb5_expand_hostname __P((
972 	krb5_context context,
973 	const char *orig_hostname,
974 	char **new_hostname));
975 
976 krb5_error_code
977 krb5_expand_hostname_realms __P((
978 	krb5_context context,
979 	const char *orig_hostname,
980 	char **new_hostname,
981 	char ***realms));
982 
983 PA_DATA *
984 krb5_find_padata __P((
985 	PA_DATA *val,
986 	unsigned len,
987 	int type,
988 	int *index));
989 
990 krb5_error_code
991 krb5_free_address __P((
992 	krb5_context context,
993 	krb5_address *address));
994 
995 krb5_error_code
996 krb5_free_addresses __P((
997 	krb5_context context,
998 	krb5_addresses *addresses));
999 
1000 void
1001 krb5_free_ap_rep_enc_part __P((
1002 	krb5_context context,
1003 	krb5_ap_rep_enc_part *val));
1004 
1005 void
1006 krb5_free_authenticator __P((
1007 	krb5_context context,
1008 	krb5_authenticator *authenticator));
1009 
1010 void
1011 krb5_free_context __P((krb5_context context));
1012 
1013 krb5_error_code
1014 krb5_free_cred_contents __P((
1015 	krb5_context context,
1016 	krb5_creds *c));
1017 
1018 krb5_error_code
1019 krb5_free_creds __P((
1020 	krb5_context context,
1021 	krb5_creds *c));
1022 
1023 krb5_error_code
1024 krb5_free_creds_contents __P((
1025 	krb5_context context,
1026 	krb5_creds *c));
1027 
1028 void
1029 krb5_free_data __P((
1030 	krb5_context context,
1031 	krb5_data *p));
1032 
1033 void
1034 krb5_free_error __P((
1035 	krb5_context context,
1036 	krb5_error *error));
1037 
1038 void
1039 krb5_free_error_contents __P((
1040 	krb5_context context,
1041 	krb5_error *error));
1042 
1043 krb5_error_code
1044 krb5_free_host_realm __P((
1045 	krb5_context context,
1046 	krb5_realm *realmlist));
1047 
1048 krb5_error_code
1049 krb5_free_kdc_rep __P((
1050 	krb5_context context,
1051 	krb5_kdc_rep *rep));
1052 
1053 void
1054 krb5_free_keyblock __P((
1055 	krb5_context context,
1056 	krb5_keyblock *keyblock));
1057 
1058 void
1059 krb5_free_keyblock_contents __P((
1060 	krb5_context context,
1061 	krb5_keyblock *keyblock));
1062 
1063 krb5_error_code
1064 krb5_free_krbhst __P((
1065 	krb5_context context,
1066 	char **hostlist));
1067 
1068 void
1069 krb5_free_principal __P((
1070 	krb5_context context,
1071 	krb5_principal p));
1072 
1073 krb5_error_code
1074 krb5_free_salt __P((
1075 	krb5_context context,
1076 	krb5_salt salt));
1077 
1078 krb5_error_code
1079 krb5_free_ticket __P((
1080 	krb5_context context,
1081 	krb5_ticket *ticket));
1082 
1083 krb5_error_code
1084 krb5_fwd_tgt_creds __P((
1085 	krb5_context context,
1086 	krb5_auth_context auth_context,
1087 	const char *hostname,
1088 	krb5_principal client,
1089 	krb5_principal server,
1090 	krb5_ccache ccache,
1091 	int forwardable,
1092 	krb5_data *out_data));
1093 
1094 void
1095 krb5_generate_random_block __P((
1096 	void *buf,
1097 	size_t len));
1098 
1099 krb5_error_code
1100 krb5_generate_random_keyblock __P((
1101 	krb5_context context,
1102 	krb5_enctype type,
1103 	krb5_keyblock *key));
1104 
1105 krb5_error_code
1106 krb5_generate_seq_number __P((
1107 	krb5_context context,
1108 	const krb5_keyblock *key,
1109 	int32_t *seqno));
1110 
1111 krb5_error_code
1112 krb5_generate_subkey __P((
1113 	krb5_context context,
1114 	const krb5_keyblock *key,
1115 	krb5_keyblock **subkey));
1116 
1117 krb5_error_code
1118 krb5_get_all_client_addrs __P((
1119 	krb5_context context,
1120 	krb5_addresses *res));
1121 
1122 krb5_error_code
1123 krb5_get_all_server_addrs __P((
1124 	krb5_context context,
1125 	krb5_addresses *res));
1126 
1127 krb5_error_code
1128 krb5_get_cred_from_kdc __P((
1129 	krb5_context context,
1130 	krb5_ccache ccache,
1131 	krb5_creds *in_creds,
1132 	krb5_creds **out_creds,
1133 	krb5_creds ***ret_tgts));
1134 
1135 krb5_error_code
1136 krb5_get_credentials __P((
1137 	krb5_context context,
1138 	krb5_flags options,
1139 	krb5_ccache ccache,
1140 	krb5_creds *in_creds,
1141 	krb5_creds **out_creds));
1142 
1143 krb5_error_code
1144 krb5_get_credentials_with_flags __P((
1145 	krb5_context context,
1146 	krb5_flags options,
1147 	krb5_kdc_flags flags,
1148 	krb5_ccache ccache,
1149 	krb5_creds *in_creds,
1150 	krb5_creds **out_creds));
1151 
1152 krb5_error_code
1153 krb5_get_default_in_tkt_etypes __P((
1154 	krb5_context context,
1155 	krb5_enctype **etypes));
1156 
1157 krb5_error_code
1158 krb5_get_default_principal __P((
1159 	krb5_context context,
1160 	krb5_principal *princ));
1161 
1162 krb5_error_code
1163 krb5_get_default_realm __P((
1164 	krb5_context context,
1165 	krb5_realm *realm));
1166 
1167 krb5_error_code
1168 krb5_get_default_realms __P((
1169 	krb5_context context,
1170 	krb5_realm **realms));
1171 
1172 const char *
1173 krb5_get_err_text __P((
1174 	krb5_context context,
1175 	krb5_error_code code));
1176 
1177 krb5_error_code
1178 krb5_get_extra_addresses __P((
1179 	krb5_context context,
1180 	krb5_addresses *addresses));
1181 
1182 krb5_error_code
1183 krb5_get_fcache_version __P((
1184 	krb5_context context,
1185 	int *version));
1186 
1187 krb5_error_code
1188 krb5_get_forwarded_creds __P((
1189 	krb5_context context,
1190 	krb5_auth_context auth_context,
1191 	krb5_ccache ccache,
1192 	krb5_flags flags,
1193 	const char *hostname,
1194 	krb5_creds *in_creds,
1195 	krb5_data *out_data));
1196 
1197 krb5_error_code
1198 krb5_get_host_realm __P((
1199 	krb5_context context,
1200 	const char *host,
1201 	krb5_realm **realms));
1202 
1203 krb5_error_code
1204 krb5_get_host_realm_int __P((
1205 	krb5_context context,
1206 	const char *host,
1207 	krb5_realm **realms));
1208 
1209 krb5_error_code
1210 krb5_get_in_cred __P((
1211 	krb5_context context,
1212 	krb5_flags options,
1213 	const krb5_addresses *addrs,
1214 	const krb5_enctype *etypes,
1215 	const krb5_preauthtype *ptypes,
1216 	const krb5_preauthdata *preauth,
1217 	krb5_key_proc key_proc,
1218 	krb5_const_pointer keyseed,
1219 	krb5_decrypt_proc decrypt_proc,
1220 	krb5_const_pointer decryptarg,
1221 	krb5_creds *creds,
1222 	krb5_kdc_rep *ret_as_reply));
1223 
1224 krb5_error_code
1225 krb5_get_in_tkt __P((
1226 	krb5_context context,
1227 	krb5_flags options,
1228 	const krb5_addresses *addrs,
1229 	const krb5_enctype *etypes,
1230 	const krb5_preauthtype *ptypes,
1231 	krb5_key_proc key_proc,
1232 	krb5_const_pointer keyseed,
1233 	krb5_decrypt_proc decrypt_proc,
1234 	krb5_const_pointer decryptarg,
1235 	krb5_creds *creds,
1236 	krb5_ccache ccache,
1237 	krb5_kdc_rep *ret_as_reply));
1238 
1239 krb5_error_code
1240 krb5_get_in_tkt_with_keytab __P((
1241 	krb5_context context,
1242 	krb5_flags options,
1243 	krb5_addresses *addrs,
1244 	const krb5_enctype *etypes,
1245 	const krb5_preauthtype *pre_auth_types,
1246 	krb5_keytab keytab,
1247 	krb5_ccache ccache,
1248 	krb5_creds *creds,
1249 	krb5_kdc_rep *ret_as_reply));
1250 
1251 krb5_error_code
1252 krb5_get_in_tkt_with_password __P((
1253 	krb5_context context,
1254 	krb5_flags options,
1255 	krb5_addresses *addrs,
1256 	const krb5_enctype *etypes,
1257 	const krb5_preauthtype *pre_auth_types,
1258 	const char *password,
1259 	krb5_ccache ccache,
1260 	krb5_creds *creds,
1261 	krb5_kdc_rep *ret_as_reply));
1262 
1263 krb5_error_code
1264 krb5_get_in_tkt_with_skey __P((
1265 	krb5_context context,
1266 	krb5_flags options,
1267 	krb5_addresses *addrs,
1268 	const krb5_enctype *etypes,
1269 	const krb5_preauthtype *pre_auth_types,
1270 	const krb5_keyblock *key,
1271 	krb5_ccache ccache,
1272 	krb5_creds *creds,
1273 	krb5_kdc_rep *ret_as_reply));
1274 
1275 krb5_error_code
1276 krb5_get_init_creds_keytab __P((
1277 	krb5_context context,
1278 	krb5_creds *creds,
1279 	krb5_principal client,
1280 	krb5_keytab keytab,
1281 	krb5_deltat start_time,
1282 	const char *in_tkt_service,
1283 	krb5_get_init_creds_opt *options));
1284 
1285 void
1286 krb5_get_init_creds_opt_init __P((krb5_get_init_creds_opt *opt));
1287 
1288 void
1289 krb5_get_init_creds_opt_set_address_list __P((
1290 	krb5_get_init_creds_opt *opt,
1291 	krb5_addresses *addresses));
1292 
1293 void
1294 krb5_get_init_creds_opt_set_etype_list __P((
1295 	krb5_get_init_creds_opt *opt,
1296 	krb5_enctype *etype_list,
1297 	int etype_list_length));
1298 
1299 void
1300 krb5_get_init_creds_opt_set_forwardable __P((
1301 	krb5_get_init_creds_opt *opt,
1302 	int forwardable));
1303 
1304 void
1305 krb5_get_init_creds_opt_set_preauth_list __P((
1306 	krb5_get_init_creds_opt *opt,
1307 	krb5_preauthtype *preauth_list,
1308 	int preauth_list_length));
1309 
1310 void
1311 krb5_get_init_creds_opt_set_proxiable __P((
1312 	krb5_get_init_creds_opt *opt,
1313 	int proxiable));
1314 
1315 void
1316 krb5_get_init_creds_opt_set_renew_life __P((
1317 	krb5_get_init_creds_opt *opt,
1318 	krb5_deltat renew_life));
1319 
1320 void
1321 krb5_get_init_creds_opt_set_salt __P((
1322 	krb5_get_init_creds_opt *opt,
1323 	krb5_data *salt));
1324 
1325 void
1326 krb5_get_init_creds_opt_set_tkt_life __P((
1327 	krb5_get_init_creds_opt *opt,
1328 	krb5_deltat tkt_life));
1329 
1330 krb5_error_code
1331 krb5_get_init_creds_password __P((
1332 	krb5_context context,
1333 	krb5_creds *creds,
1334 	krb5_principal client,
1335 	const char *password,
1336 	krb5_prompter_fct prompter,
1337 	void *data,
1338 	krb5_deltat start_time,
1339 	const char *in_tkt_service,
1340 	krb5_get_init_creds_opt *options));
1341 
1342 krb5_error_code
1343 krb5_get_kdc_cred __P((
1344 	krb5_context context,
1345 	krb5_ccache id,
1346 	krb5_kdc_flags flags,
1347 	krb5_addresses *addresses,
1348 	Ticket *second_ticket,
1349 	krb5_creds *in_creds,
1350 	krb5_creds **out_creds ));
1351 
1352 krb5_error_code
1353 krb5_get_krb_admin_hst __P((
1354 	krb5_context context,
1355 	const krb5_realm *realm,
1356 	char ***hostlist));
1357 
1358 krb5_error_code
1359 krb5_get_krb_changepw_hst __P((
1360 	krb5_context context,
1361 	const krb5_realm *realm,
1362 	char ***hostlist));
1363 
1364 krb5_error_code
1365 krb5_get_krbhst __P((
1366 	krb5_context context,
1367 	const krb5_realm *realm,
1368 	char ***hostlist));
1369 
1370 krb5_error_code
1371 krb5_get_pw_salt __P((
1372 	krb5_context context,
1373 	krb5_const_principal principal,
1374 	krb5_salt *salt));
1375 
1376 krb5_boolean
1377 krb5_get_use_admin_kdc __P((krb5_context context));
1378 
1379 size_t
1380 krb5_get_wrapped_length __P((
1381 	krb5_context context,
1382 	krb5_crypto crypto,
1383 	size_t data_len));
1384 
1385 int
1386 krb5_getportbyname __P((
1387 	krb5_context context,
1388 	const char *service,
1389 	const char *proto,
1390 	int default_port));
1391 
1392 krb5_error_code
1393 krb5_h_addr2addr __P((
1394 	int af,
1395 	const char *haddr,
1396 	krb5_address *addr));
1397 
1398 krb5_error_code
1399 krb5_h_addr2sockaddr __P((
1400 	int af,
1401 	const char *addr,
1402 	struct sockaddr *sa,
1403 	int *sa_size,
1404 	int port));
1405 
1406 krb5_error_code
1407 krb5_init_context __P((krb5_context *context));
1408 
1409 void
1410 krb5_init_ets __P((krb5_context context));
1411 
1412 krb5_error_code
1413 krb5_init_etype __P((
1414 	krb5_context context,
1415 	unsigned *len,
1416 	int **val,
1417 	const krb5_enctype *etypes));
1418 
1419 krb5_error_code
1420 krb5_initlog __P((
1421 	krb5_context context,
1422 	const char *program,
1423 	krb5_log_facility **fac));
1424 
1425 krb5_error_code
1426 krb5_keyblock_key_proc __P((
1427 	krb5_context context,
1428 	krb5_keytype type,
1429 	krb5_data *salt,
1430 	krb5_const_pointer keyseed,
1431 	krb5_keyblock **key));
1432 
1433 krb5_error_code
1434 krb5_keytab_key_proc __P((
1435 	krb5_context context,
1436 	krb5_enctype enctype,
1437 	krb5_salt salt,
1438 	krb5_const_pointer keyseed,
1439 	krb5_keyblock **key));
1440 
1441 krb5_error_code
1442 krb5_keytype_to_enctypes __P((
1443 	krb5_context context,
1444 	krb5_keytype keytype,
1445 	unsigned *len,
1446 	int **val));
1447 
1448 krb5_error_code
1449 krb5_keytype_to_enctypes_default __P((
1450 	krb5_context context,
1451 	krb5_keytype keytype,
1452 	unsigned *len,
1453 	int **val));
1454 
1455 krb5_error_code
1456 krb5_keytype_to_string __P((
1457 	krb5_context context,
1458 	krb5_keytype keytype,
1459 	char **string));
1460 
1461 krb5_error_code
1462 krb5_kt_add_entry __P((
1463 	krb5_context context,
1464 	krb5_keytab id,
1465 	krb5_keytab_entry *entry));
1466 
1467 krb5_error_code
1468 krb5_kt_close __P((
1469 	krb5_context context,
1470 	krb5_keytab id));
1471 
1472 krb5_boolean
1473 krb5_kt_compare __P((
1474 	krb5_context context,
1475 	krb5_keytab_entry *entry,
1476 	krb5_const_principal principal,
1477 	krb5_kvno vno,
1478 	krb5_enctype enctype));
1479 
1480 krb5_error_code
1481 krb5_kt_copy_entry_contents __P((
1482 	krb5_context context,
1483 	const krb5_keytab_entry *in,
1484 	krb5_keytab_entry *out));
1485 
1486 krb5_error_code
1487 krb5_kt_default __P((
1488 	krb5_context context,
1489 	krb5_keytab *id));
1490 
1491 krb5_error_code
1492 krb5_kt_default_name __P((
1493 	krb5_context context,
1494 	char *name,
1495 	size_t namesize));
1496 
1497 krb5_error_code
1498 krb5_kt_end_seq_get __P((
1499 	krb5_context context,
1500 	krb5_keytab id,
1501 	krb5_kt_cursor *cursor));
1502 
1503 krb5_error_code
1504 krb5_kt_free_entry __P((
1505 	krb5_context context,
1506 	krb5_keytab_entry *entry));
1507 
1508 krb5_error_code
1509 krb5_kt_get_entry __P((
1510 	krb5_context context,
1511 	krb5_keytab id,
1512 	krb5_const_principal principal,
1513 	krb5_kvno kvno,
1514 	krb5_enctype enctype,
1515 	krb5_keytab_entry *entry));
1516 
1517 krb5_error_code
1518 krb5_kt_get_name __P((
1519 	krb5_context context,
1520 	krb5_keytab keytab,
1521 	char *name,
1522 	size_t namesize));
1523 
1524 krb5_error_code
1525 krb5_kt_next_entry __P((
1526 	krb5_context context,
1527 	krb5_keytab id,
1528 	krb5_keytab_entry *entry,
1529 	krb5_kt_cursor *cursor));
1530 
1531 krb5_error_code
1532 krb5_kt_read_service_key __P((
1533 	krb5_context context,
1534 	krb5_pointer keyprocarg,
1535 	krb5_principal principal,
1536 	krb5_kvno vno,
1537 	krb5_enctype enctype,
1538 	krb5_keyblock **key));
1539 
1540 krb5_error_code
1541 krb5_kt_register __P((
1542 	krb5_context context,
1543 	const krb5_kt_ops *ops));
1544 
1545 krb5_error_code
1546 krb5_kt_remove_entry __P((
1547 	krb5_context context,
1548 	krb5_keytab id,
1549 	krb5_keytab_entry *entry));
1550 
1551 krb5_error_code
1552 krb5_kt_resolve __P((
1553 	krb5_context context,
1554 	const char *name,
1555 	krb5_keytab *id));
1556 
1557 krb5_error_code
1558 krb5_kt_start_seq_get __P((
1559 	krb5_context context,
1560 	krb5_keytab id,
1561 	krb5_kt_cursor *cursor));
1562 
1563 krb5_boolean
1564 krb5_kuserok __P((
1565 	krb5_context context,
1566 	krb5_principal principal,
1567 	const char *luser));
1568 
1569 krb5_error_code
1570 krb5_log __P((
1571 	krb5_context context,
1572 	krb5_log_facility *fac,
1573 	int level,
1574 	const char *fmt,
1575 	...))
1576     __attribute__((format (printf, 4, 5)));
1577 
1578 krb5_error_code
1579 krb5_log_msg __P((
1580 	krb5_context context,
1581 	krb5_log_facility *fac,
1582 	int level,
1583 	char **reply,
1584 	const char *fmt,
1585 	...))
1586     __attribute__((format (printf, 5, 6)));
1587 
1588 krb5_error_code
1589 krb5_make_addrport __P((
1590 	krb5_address **res,
1591 	const krb5_address *addr,
1592 	int16_t port));
1593 
1594 krb5_error_code
1595 krb5_make_principal __P((
1596 	krb5_context context,
1597 	krb5_principal *principal,
1598 	krb5_const_realm realm,
1599 	...));
1600 
1601 size_t
1602 krb5_max_sockaddr_size __P((void));
1603 
1604 krb5_error_code
1605 krb5_mk_error __P((
1606 	krb5_context context,
1607 	krb5_error_code error_code,
1608 	const char *e_text,
1609 	const krb5_data *e_data,
1610 	const krb5_principal client,
1611 	const krb5_principal server,
1612 	time_t ctime,
1613 	krb5_data *reply));
1614 
1615 krb5_error_code
1616 krb5_mk_priv __P((
1617 	krb5_context context,
1618 	krb5_auth_context auth_context,
1619 	const krb5_data *userdata,
1620 	krb5_data *outbuf,
1621 	void *outdata));
1622 
1623 krb5_error_code
1624 krb5_mk_rep __P((
1625 	krb5_context context,
1626 	krb5_auth_context *auth_context,
1627 	krb5_data *outbuf));
1628 
1629 krb5_error_code
1630 krb5_mk_req __P((
1631 	krb5_context context,
1632 	krb5_auth_context *auth_context,
1633 	const krb5_flags ap_req_options,
1634 	const char *service,
1635 	const char *hostname,
1636 	krb5_data *in_data,
1637 	krb5_ccache ccache,
1638 	krb5_data *outbuf));
1639 
1640 krb5_error_code
1641 krb5_mk_req_extended __P((
1642 	krb5_context context,
1643 	krb5_auth_context *auth_context,
1644 	const krb5_flags ap_req_options,
1645 	krb5_data *in_data,
1646 	krb5_creds *in_creds,
1647 	krb5_data *outbuf));
1648 
1649 krb5_error_code
1650 krb5_mk_req_internal __P((
1651 	krb5_context context,
1652 	krb5_auth_context *auth_context,
1653 	const krb5_flags ap_req_options,
1654 	krb5_data *in_data,
1655 	krb5_creds *in_creds,
1656 	krb5_data *outbuf,
1657 	krb5_key_usage usage));
1658 
1659 krb5_error_code
1660 krb5_mk_safe __P((
1661 	krb5_context context,
1662 	krb5_auth_context auth_context,
1663 	const krb5_data *userdata,
1664 	krb5_data *outbuf,
1665 	void *outdata));
1666 
1667 ssize_t
1668 krb5_net_read __P((
1669 	krb5_context context,
1670 	void *p_fd,
1671 	void *buf,
1672 	size_t len));
1673 
1674 ssize_t
1675 krb5_net_write __P((
1676 	krb5_context context,
1677 	void *p_fd,
1678 	const void *buf,
1679 	size_t len));
1680 
1681 krb5_error_code
1682 krb5_openlog __P((
1683 	krb5_context context,
1684 	const char *program,
1685 	krb5_log_facility **fac));
1686 
1687 krb5_error_code
1688 krb5_parse_address __P((
1689 	krb5_context context,
1690 	const char *string,
1691 	krb5_addresses *addresses));
1692 
1693 krb5_error_code
1694 krb5_parse_name __P((
1695 	krb5_context context,
1696 	const char *name,
1697 	krb5_principal *principal));
1698 
1699 krb5_error_code
1700 krb5_password_key_proc __P((
1701 	krb5_context context,
1702 	krb5_enctype type,
1703 	krb5_salt salt,
1704 	krb5_const_pointer keyseed,
1705 	krb5_keyblock **key));
1706 
1707 krb5_realm*
1708 krb5_princ_realm __P((
1709 	krb5_context context,
1710 	krb5_principal principal));
1711 
1712 void
1713 krb5_princ_set_realm __P((
1714 	krb5_context context,
1715 	krb5_principal principal,
1716 	krb5_realm *realm));
1717 
1718 krb5_error_code
1719 krb5_principal2principalname __P((
1720 	PrincipalName *p,
1721 	const krb5_principal from));
1722 
1723 krb5_boolean
1724 krb5_principal_compare __P((
1725 	krb5_context context,
1726 	krb5_const_principal princ1,
1727 	krb5_const_principal princ2));
1728 
1729 krb5_boolean
1730 krb5_principal_compare_any_realm __P((
1731 	krb5_context context,
1732 	krb5_const_principal princ1,
1733 	krb5_const_principal princ2));
1734 
1735 krb5_error_code
1736 krb5_print_address __P((
1737 	const krb5_address *addr,
1738 	char *str,
1739 	size_t len,
1740 	size_t *ret_len));
1741 
1742 int
1743 krb5_program_setup __P((
1744 	krb5_context *context,
1745 	int argc,
1746 	char **argv,
1747 	struct getargs *args,
1748 	int num_args,
1749 	void (*usage)(int, struct getargs*, int)));
1750 
1751 int
1752 krb5_prompter_posix __P((
1753 	krb5_context context,
1754 	void *data,
1755 	const char *banner,
1756 	int num_prompts,
1757 	krb5_prompt prompts[]));
1758 
1759 krb5_error_code
1760 krb5_rd_cred __P((
1761 	krb5_context context,
1762 	krb5_auth_context auth_context,
1763 	krb5_ccache ccache,
1764 	krb5_data *in_data));
1765 
1766 krb5_error_code
1767 krb5_rd_error __P((
1768 	krb5_context context,
1769 	krb5_data *msg,
1770 	KRB_ERROR *result));
1771 
1772 krb5_error_code
1773 krb5_rd_priv __P((
1774 	krb5_context context,
1775 	krb5_auth_context auth_context,
1776 	const krb5_data *inbuf,
1777 	krb5_data *outbuf,
1778 	void *outdata));
1779 
1780 krb5_error_code
1781 krb5_rd_rep __P((
1782 	krb5_context context,
1783 	krb5_auth_context auth_context,
1784 	const krb5_data *inbuf,
1785 	krb5_ap_rep_enc_part **repl));
1786 
1787 krb5_error_code
1788 krb5_rd_req __P((
1789 	krb5_context context,
1790 	krb5_auth_context *auth_context,
1791 	const krb5_data *inbuf,
1792 	krb5_const_principal server,
1793 	krb5_keytab keytab,
1794 	krb5_flags *ap_req_options,
1795 	krb5_ticket **ticket));
1796 
1797 krb5_error_code
1798 krb5_rd_req_with_keyblock __P((
1799 	krb5_context context,
1800 	krb5_auth_context *auth_context,
1801 	const krb5_data *inbuf,
1802 	krb5_const_principal server,
1803 	krb5_keyblock *keyblock,
1804 	krb5_flags *ap_req_options,
1805 	krb5_ticket **ticket));
1806 
1807 krb5_error_code
1808 krb5_rd_safe __P((
1809 	krb5_context context,
1810 	krb5_auth_context auth_context,
1811 	const krb5_data *inbuf,
1812 	krb5_data *outbuf,
1813 	void *outdata));
1814 
1815 krb5_error_code
1816 krb5_read_message __P((
1817 	krb5_context context,
1818 	krb5_pointer p_fd,
1819 	krb5_data *data));
1820 
1821 krb5_boolean
1822 krb5_realm_compare __P((
1823 	krb5_context context,
1824 	krb5_const_principal princ1,
1825 	krb5_const_principal princ2));
1826 
1827 krb5_error_code
1828 krb5_recvauth __P((
1829 	krb5_context context,
1830 	krb5_auth_context *auth_context,
1831 	krb5_pointer p_fd,
1832 	char *appl_version,
1833 	krb5_principal server,
1834 	int32_t flags,
1835 	krb5_keytab keytab,
1836 	krb5_ticket **ticket));
1837 
1838 krb5_error_code
1839 krb5_recvauth_match_version __P((
1840 	krb5_context context,
1841 	krb5_auth_context *auth_context,
1842 	krb5_pointer p_fd,
1843 	krb5_boolean (*match_appl_version)(void *, const char*),
1844 	void *match_data,
1845 	krb5_principal server,
1846 	int32_t flags,
1847 	krb5_keytab keytab,
1848 	krb5_ticket **ticket));
1849 
1850 krb5_error_code
1851 krb5_ret_address __P((
1852 	krb5_storage *sp,
1853 	krb5_address *adr));
1854 
1855 krb5_error_code
1856 krb5_ret_addrs __P((
1857 	krb5_storage *sp,
1858 	krb5_addresses *adr));
1859 
1860 krb5_error_code
1861 krb5_ret_authdata __P((
1862 	krb5_storage *sp,
1863 	krb5_authdata *auth));
1864 
1865 krb5_error_code
1866 krb5_ret_creds __P((
1867 	krb5_storage *sp,
1868 	krb5_creds *creds));
1869 
1870 krb5_error_code
1871 krb5_ret_data __P((
1872 	krb5_storage *sp,
1873 	krb5_data *data));
1874 
1875 krb5_error_code
1876 krb5_ret_int16 __P((
1877 	krb5_storage *sp,
1878 	int16_t *value));
1879 
1880 krb5_error_code
1881 krb5_ret_int32 __P((
1882 	krb5_storage *sp,
1883 	int32_t *value));
1884 
1885 krb5_error_code
1886 krb5_ret_int8 __P((
1887 	krb5_storage *sp,
1888 	int8_t *value));
1889 
1890 krb5_error_code
1891 krb5_ret_keyblock __P((
1892 	krb5_storage *sp,
1893 	krb5_keyblock *p));
1894 
1895 krb5_error_code
1896 krb5_ret_principal __P((
1897 	krb5_storage *sp,
1898 	krb5_principal *princ));
1899 
1900 krb5_error_code
1901 krb5_ret_string __P((
1902 	krb5_storage *sp,
1903 	char **string));
1904 
1905 krb5_error_code
1906 krb5_ret_stringz __P((
1907 	krb5_storage *sp,
1908 	char **string));
1909 
1910 krb5_error_code
1911 krb5_ret_times __P((
1912 	krb5_storage *sp,
1913 	krb5_times *times));
1914 
1915 krb5_error_code
1916 krb5_salttype_to_string __P((
1917 	krb5_context context,
1918 	krb5_enctype etype,
1919 	krb5_salttype stype,
1920 	char **string));
1921 
1922 krb5_error_code
1923 krb5_sendauth __P((
1924 	krb5_context context,
1925 	krb5_auth_context *auth_context,
1926 	krb5_pointer p_fd,
1927 	const char *appl_version,
1928 	krb5_principal client,
1929 	krb5_principal server,
1930 	krb5_flags ap_req_options,
1931 	krb5_data *in_data,
1932 	krb5_creds *in_creds,
1933 	krb5_ccache ccache,
1934 	krb5_error **ret_error,
1935 	krb5_ap_rep_enc_part **rep_result,
1936 	krb5_creds **out_creds));
1937 
1938 krb5_error_code
1939 krb5_sendto_kdc __P((
1940 	krb5_context context,
1941 	const krb5_data *send,
1942 	const krb5_realm *realm,
1943 	krb5_data *receive));
1944 
1945 krb5_error_code
1946 krb5_set_default_in_tkt_etypes __P((
1947 	krb5_context context,
1948 	const krb5_enctype *etypes));
1949 
1950 krb5_error_code
1951 krb5_set_default_realm __P((
1952 	krb5_context context,
1953 	char *realm));
1954 
1955 krb5_error_code
1956 krb5_set_extra_addresses __P((
1957 	krb5_context context,
1958 	const krb5_addresses *addresses));
1959 
1960 krb5_error_code
1961 krb5_set_fcache_version __P((
1962 	krb5_context context,
1963 	int version));
1964 
1965 void
1966 krb5_set_use_admin_kdc __P((
1967 	krb5_context context,
1968 	krb5_boolean flag));
1969 
1970 krb5_error_code
1971 krb5_set_warn_dest __P((
1972 	krb5_context context,
1973 	krb5_log_facility *fac));
1974 
1975 krb5_error_code
1976 krb5_sname_to_principal __P((
1977 	krb5_context context,
1978 	const char *hostname,
1979 	const char *sname,
1980 	int32_t type,
1981 	krb5_principal *ret_princ));
1982 
1983 krb5_error_code
1984 krb5_sock_to_principal __P((
1985 	krb5_context context,
1986 	int sock,
1987 	const char *sname,
1988 	int32_t type,
1989 	krb5_principal *ret_princ));
1990 
1991 krb5_error_code
1992 krb5_sockaddr2address __P((
1993 	const struct sockaddr *sa,
1994 	krb5_address *addr));
1995 
1996 krb5_error_code
1997 krb5_sockaddr2port __P((
1998 	const struct sockaddr *sa,
1999 	int16_t *port));
2000 
2001 krb5_boolean
2002 krb5_sockaddr_uninteresting __P((const struct sockaddr *sa));
2003 
2004 void
2005 krb5_std_usage __P((
2006 	int code,
2007 	struct getargs *args,
2008 	int num_args));
2009 
2010 void
2011 krb5_storage_clear_flags __P((
2012 	krb5_storage *sp,
2013 	krb5_flags flags));
2014 
2015 krb5_storage *
2016 krb5_storage_emem __P((void));
2017 
2018 krb5_error_code
2019 krb5_storage_free __P((krb5_storage *sp));
2020 
2021 krb5_storage *
2022 krb5_storage_from_data __P((krb5_data *data));
2023 
2024 krb5_storage *
2025 krb5_storage_from_fd __P((int fd));
2026 
2027 krb5_storage *
2028 krb5_storage_from_mem __P((
2029 	void *buf,
2030 	size_t len));
2031 
2032 krb5_boolean
2033 krb5_storage_is_flags __P((
2034 	krb5_storage *sp,
2035 	krb5_flags flags));
2036 
2037 void
2038 krb5_storage_set_flags __P((
2039 	krb5_storage *sp,
2040 	krb5_flags flags));
2041 
2042 krb5_error_code
2043 krb5_storage_to_data __P((
2044 	krb5_storage *sp,
2045 	krb5_data *data));
2046 
2047 krb5_error_code
2048 krb5_store_address __P((
2049 	krb5_storage *sp,
2050 	krb5_address p));
2051 
2052 krb5_error_code
2053 krb5_store_addrs __P((
2054 	krb5_storage *sp,
2055 	krb5_addresses p));
2056 
2057 krb5_error_code
2058 krb5_store_authdata __P((
2059 	krb5_storage *sp,
2060 	krb5_authdata auth));
2061 
2062 krb5_error_code
2063 krb5_store_creds __P((
2064 	krb5_storage *sp,
2065 	krb5_creds *creds));
2066 
2067 krb5_error_code
2068 krb5_store_data __P((
2069 	krb5_storage *sp,
2070 	krb5_data data));
2071 
2072 krb5_error_code
2073 krb5_store_int16 __P((
2074 	krb5_storage *sp,
2075 	int16_t value));
2076 
2077 krb5_error_code
2078 krb5_store_int32 __P((
2079 	krb5_storage *sp,
2080 	int32_t value));
2081 
2082 krb5_error_code
2083 krb5_store_int8 __P((
2084 	krb5_storage *sp,
2085 	int8_t value));
2086 
2087 krb5_error_code
2088 krb5_store_keyblock __P((
2089 	krb5_storage *sp,
2090 	krb5_keyblock p));
2091 
2092 krb5_error_code
2093 krb5_store_principal __P((
2094 	krb5_storage *sp,
2095 	krb5_principal p));
2096 
2097 krb5_error_code
2098 krb5_store_string __P((
2099 	krb5_storage *sp,
2100 	const char *s));
2101 
2102 krb5_error_code
2103 krb5_store_stringz __P((
2104 	krb5_storage *sp,
2105 	char *s));
2106 
2107 krb5_error_code
2108 krb5_store_times __P((
2109 	krb5_storage *sp,
2110 	krb5_times times));
2111 
2112 krb5_error_code
2113 krb5_string_to_enctype __P((
2114 	krb5_context context,
2115 	const char *string,
2116 	krb5_enctype *etype));
2117 
2118 krb5_error_code
2119 krb5_string_to_key __P((
2120 	krb5_context context,
2121 	krb5_enctype enctype,
2122 	const char *password,
2123 	krb5_principal principal,
2124 	krb5_keyblock *key));
2125 
2126 krb5_error_code
2127 krb5_string_to_key_data __P((
2128 	krb5_context context,
2129 	krb5_enctype enctype,
2130 	krb5_data password,
2131 	krb5_principal principal,
2132 	krb5_keyblock *key));
2133 
2134 krb5_error_code
2135 krb5_string_to_key_data_salt __P((
2136 	krb5_context context,
2137 	krb5_enctype enctype,
2138 	krb5_data password,
2139 	krb5_salt salt,
2140 	krb5_keyblock *key));
2141 
2142 krb5_error_code
2143 krb5_string_to_key_derived __P((
2144 	krb5_context context,
2145 	const void *str,
2146 	size_t len,
2147 	krb5_enctype etype,
2148 	krb5_keyblock *key));
2149 
2150 krb5_error_code
2151 krb5_string_to_key_salt __P((
2152 	krb5_context context,
2153 	krb5_enctype enctype,
2154 	const char *password,
2155 	krb5_salt salt,
2156 	krb5_keyblock *key));
2157 
2158 krb5_error_code
2159 krb5_string_to_keytype __P((
2160 	krb5_context context,
2161 	const char *string,
2162 	krb5_keytype *keytype));
2163 
2164 krb5_error_code
2165 krb5_string_to_salttype __P((
2166 	krb5_context context,
2167 	krb5_enctype etype,
2168 	const char *string,
2169 	krb5_salttype *salttype));
2170 
2171 krb5_error_code
2172 krb5_timeofday __P((
2173 	krb5_context context,
2174 	krb5_timestamp *timeret));
2175 
2176 krb5_error_code
2177 krb5_unparse_name __P((
2178 	krb5_context context,
2179 	krb5_const_principal principal,
2180 	char **name));
2181 
2182 krb5_error_code
2183 krb5_unparse_name_fixed __P((
2184 	krb5_context context,
2185 	krb5_const_principal principal,
2186 	char *name,
2187 	size_t len));
2188 
2189 krb5_error_code
2190 krb5_unparse_name_fixed_short __P((
2191 	krb5_context context,
2192 	krb5_const_principal principal,
2193 	char *name,
2194 	size_t len));
2195 
2196 krb5_error_code
2197 krb5_unparse_name_short __P((
2198 	krb5_context context,
2199 	krb5_const_principal principal,
2200 	char **name));
2201 
2202 krb5_error_code
2203 krb5_us_timeofday __P((
2204 	krb5_context context,
2205 	int32_t *sec,
2206 	int32_t *usec));
2207 
2208 krb5_error_code
2209 krb5_vabort __P((
2210 	krb5_context context,
2211 	krb5_error_code code,
2212 	const char *fmt,
2213 	va_list ap))
2214     __attribute__ ((noreturn, format (printf, 3, 0)));
2215 
2216 krb5_error_code
2217 krb5_vabortx __P((
2218 	krb5_context context,
2219 	const char *fmt,
2220 	va_list ap))
2221     __attribute__ ((noreturn, format (printf, 2, 0)));
2222 
2223 krb5_error_code
2224 krb5_verify_ap_req __P((
2225 	krb5_context context,
2226 	krb5_auth_context *auth_context,
2227 	krb5_ap_req *ap_req,
2228 	krb5_const_principal server,
2229 	krb5_keyblock *keyblock,
2230 	krb5_flags flags,
2231 	krb5_flags *ap_req_options,
2232 	krb5_ticket **ticket));
2233 
2234 krb5_error_code
2235 krb5_verify_authenticator_checksum __P((
2236 	krb5_context context,
2237 	krb5_auth_context ac,
2238 	void *data,
2239 	size_t len));
2240 
2241 krb5_error_code
2242 krb5_verify_checksum __P((
2243 	krb5_context context,
2244 	krb5_crypto crypto,
2245 	krb5_key_usage usage,
2246 	void *data,
2247 	size_t len,
2248 	Checksum *cksum));
2249 
2250 krb5_error_code
2251 krb5_verify_init_creds __P((
2252 	krb5_context context,
2253 	krb5_creds *creds,
2254 	krb5_principal ap_req_server,
2255 	krb5_keytab ap_req_keytab,
2256 	krb5_ccache *ccache,
2257 	krb5_verify_init_creds_opt *options));
2258 
2259 void
2260 krb5_verify_init_creds_opt_init __P((krb5_verify_init_creds_opt *options));
2261 
2262 void
2263 krb5_verify_init_creds_opt_set_ap_req_nofail __P((
2264 	krb5_verify_init_creds_opt *options,
2265 	int ap_req_nofail));
2266 
2267 krb5_error_code
2268 krb5_verify_user __P((
2269 	krb5_context context,
2270 	krb5_principal principal,
2271 	krb5_ccache ccache,
2272 	const char *password,
2273 	krb5_boolean secure,
2274 	const char *service));
2275 
2276 krb5_error_code
2277 krb5_verify_user_lrealm __P((
2278 	krb5_context context,
2279 	krb5_principal principal,
2280 	krb5_ccache ccache,
2281 	const char *password,
2282 	krb5_boolean secure,
2283 	const char *service));
2284 
2285 krb5_error_code
2286 krb5_verr __P((
2287 	krb5_context context,
2288 	int eval,
2289 	krb5_error_code code,
2290 	const char *fmt,
2291 	va_list ap))
2292     __attribute__ ((noreturn, format (printf, 4, 0)));
2293 
2294 krb5_error_code
2295 krb5_verrx __P((
2296 	krb5_context context,
2297 	int eval,
2298 	const char *fmt,
2299 	va_list ap))
2300     __attribute__ ((noreturn, format (printf, 3, 0)));
2301 
2302 krb5_error_code
2303 krb5_vlog __P((
2304 	krb5_context context,
2305 	krb5_log_facility *fac,
2306 	int level,
2307 	const char *fmt,
2308 	va_list ap))
2309     __attribute__((format (printf, 4, 0)));
2310 
2311 krb5_error_code
2312 krb5_vlog_msg __P((
2313 	krb5_context context,
2314 	krb5_log_facility *fac,
2315 	char **reply,
2316 	int level,
2317 	const char *fmt,
2318 	va_list ap))
2319     __attribute__((format (printf, 5, 0)));
2320 
2321 krb5_error_code
2322 krb5_vwarn __P((
2323 	krb5_context context,
2324 	krb5_error_code code,
2325 	const char *fmt,
2326 	va_list ap))
2327     __attribute__ ((format (printf, 3, 0)));
2328 
2329 krb5_error_code
2330 krb5_vwarnx __P((
2331 	krb5_context context,
2332 	const char *fmt,
2333 	va_list ap))
2334     __attribute__ ((format (printf, 2, 0)));
2335 
2336 krb5_error_code
2337 krb5_warn __P((
2338 	krb5_context context,
2339 	krb5_error_code code,
2340 	const char *fmt,
2341 	...))
2342     __attribute__ ((format (printf, 3, 4)));
2343 
2344 krb5_error_code
2345 krb5_warnx __P((
2346 	krb5_context context,
2347 	const char *fmt,
2348 	...))
2349     __attribute__ ((format (printf, 2, 3)));
2350 
2351 krb5_error_code
2352 krb5_write_message __P((
2353 	krb5_context context,
2354 	krb5_pointer p_fd,
2355 	krb5_data *data));
2356 
2357 krb5_error_code
2358 krb5_xfree __P((void *ptr));
2359 
2360 krb5_error_code
2361 principalname2krb5_principal __P((
2362 	krb5_principal *principal,
2363 	const PrincipalName from,
2364 	const Realm realm));
2365 
2366 #endif /* __krb5_protos_h__ */
2367