1c33df7edSps /*
2c33df7edSps  * lib/krb5/rcache/rc_none.c
3c33df7edSps  *
4c33df7edSps  * Copyright 2004 by the Massachusetts Institute of Technology.
5c33df7edSps  * All Rights Reserved.
6c33df7edSps  *
7c33df7edSps  * Export of this software from the United States of America may
8159d09a2SMark Phalan  *   require a specific license from the United States Government.
9159d09a2SMark Phalan  *   It is the responsibility of any person or organization contemplating
10159d09a2SMark Phalan  *   export to obtain such a license before exporting.
11*55fea89dSDan Cross  *
12c33df7edSps  * WITHIN THAT CONSTRAINT, permission to use, copy, modify, and
13c33df7edSps  * distribute this software and its documentation for any purpose and
14c33df7edSps  * without fee is hereby granted, provided that the above copyright
15c33df7edSps  * notice appear in all copies and that both that copyright notice and
16c33df7edSps  * this permission notice appear in supporting documentation, and that
17c33df7edSps  * the name of M.I.T. not be used in advertising or publicity pertaining
18c33df7edSps  * to distribution of the software without specific, written prior
19159d09a2SMark Phalan  * permission.  Furthermore if you modify this software you must label
20c33df7edSps  * your software as modified software and not distribute it in such a
21c33df7edSps  * fashion that it might be confused with the original M.I.T. software.
22c33df7edSps  * M.I.T. makes no representations about the suitability of
23c33df7edSps  * this software for any purpose.  It is provided "as is" without express
24c33df7edSps  * or implied warranty.
25*55fea89dSDan Cross  *
26c33df7edSps  *
27c33df7edSps  * replay cache no-op implementation
28c33df7edSps  */
29c33df7edSps 
30c33df7edSps #include "k5-int.h"
3169dc0907Sps #include "rc-int.h"
32c33df7edSps 
33c33df7edSps static krb5_error_code KRB5_CALLCONV
krb5_rc_none_init(krb5_context ctx,krb5_rcache rc,krb5_deltat d)34159d09a2SMark Phalan krb5_rc_none_init(krb5_context ctx, krb5_rcache rc, krb5_deltat d)
35c33df7edSps {
36159d09a2SMark Phalan     return 0;
37c33df7edSps }
38c33df7edSps #define krb5_rc_none_recover_or_init krb5_rc_none_init
39c33df7edSps 
40c33df7edSps static krb5_error_code KRB5_CALLCONV
krb5_rc_none_noargs(krb5_context ctx,krb5_rcache rc)41c33df7edSps krb5_rc_none_noargs(krb5_context ctx, krb5_rcache rc)
42c33df7edSps {
43159d09a2SMark Phalan     return 0;
44c33df7edSps }
45c33df7edSps #define krb5_rc_none_recover	krb5_rc_none_noargs
46c33df7edSps #define krb5_rc_none_destroy	krb5_rc_none_noargs
47c33df7edSps #define krb5_rc_none_close	krb5_rc_none_noargs
48c33df7edSps #define krb5_rc_none_expunge	krb5_rc_none_noargs
49c33df7edSps 
50c33df7edSps static krb5_error_code KRB5_CALLCONV
krb5_rc_none_store(krb5_context ctx,krb5_rcache rc,krb5_donot_replay * r)51c33df7edSps krb5_rc_none_store(krb5_context ctx, krb5_rcache rc, krb5_donot_replay *r)
52c33df7edSps {
53159d09a2SMark Phalan     return 0;
54c33df7edSps }
55c33df7edSps 
56c33df7edSps static krb5_error_code KRB5_CALLCONV
krb5_rc_none_get_span(krb5_context ctx,krb5_rcache rc,krb5_deltat * d)57c33df7edSps krb5_rc_none_get_span(krb5_context ctx, krb5_rcache rc, krb5_deltat *d)
58c33df7edSps {
59159d09a2SMark Phalan     return 0;
60c33df7edSps }
61c33df7edSps 
62c33df7edSps static char * KRB5_CALLCONV
krb5_rc_none_get_name(krb5_context ctx,krb5_rcache rc)63c33df7edSps krb5_rc_none_get_name(krb5_context ctx, krb5_rcache rc)
64c33df7edSps {
65159d09a2SMark Phalan     return "";
66c33df7edSps }
67c33df7edSps 
68c33df7edSps static krb5_error_code KRB5_CALLCONV
krb5_rc_none_resolve(krb5_context ctx,krb5_rcache rc,char * name)69c33df7edSps krb5_rc_none_resolve(krb5_context ctx, krb5_rcache rc, char *name)
70c33df7edSps {
71159d09a2SMark Phalan     rc->data = "NONE";
72159d09a2SMark Phalan     return 0;
73c33df7edSps }
74c33df7edSps 
75c33df7edSps const krb5_rc_ops krb5_rc_none_ops = {
76159d09a2SMark Phalan     0,
77159d09a2SMark Phalan     "NONE",
78159d09a2SMark Phalan     krb5_rc_none_init,
79159d09a2SMark Phalan     krb5_rc_none_recover,
80159d09a2SMark Phalan     krb5_rc_none_recover_or_init,
81159d09a2SMark Phalan     krb5_rc_none_destroy,
82159d09a2SMark Phalan     krb5_rc_none_close,
83159d09a2SMark Phalan     krb5_rc_none_store,
84159d09a2SMark Phalan     krb5_rc_none_expunge,
85159d09a2SMark Phalan     krb5_rc_none_get_span,
86159d09a2SMark Phalan     krb5_rc_none_get_name,
87159d09a2SMark Phalan     krb5_rc_none_resolve
88c33df7edSps };
89