xref: /freebsd/crypto/heimdal/lib/krb5/codec.c (revision 8fc257994d0ce2396196d7a06d50d20c8015f4b7)
1 /*
2  * Copyright (c) 1998 - 2001 Kungliga Tekniska H�gskolan
3  * (Royal Institute of Technology, Stockholm, Sweden).
4  * All rights reserved.
5  *
6  * Redistribution and use in source and binary forms, with or without
7  * modification, are permitted provided that the following conditions
8  * are met:
9  *
10  * 1. Redistributions of source code must retain the above copyright
11  *    notice, this list of conditions and the following disclaimer.
12  *
13  * 2. Redistributions in binary form must reproduce the above copyright
14  *    notice, this list of conditions and the following disclaimer in the
15  *    documentation and/or other materials provided with the distribution.
16  *
17  * 3. Neither the name of the Institute nor the names of its contributors
18  *    may be used to endorse or promote products derived from this software
19  *    without specific prior written permission.
20  *
21  * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
22  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
23  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
24  * ARE DISCLAIMED.  IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE
25  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
26  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31  * SUCH DAMAGE.
32  */
33 
34 #include "krb5_locl.h"
35 
36 RCSID("$Id: codec.c 13863 2004-05-25 21:46:46Z lha $");
37 
38 krb5_error_code KRB5_LIB_FUNCTION
39 krb5_decode_EncTicketPart (krb5_context context,
40 			   const void *data,
41 			   size_t length,
42 			   EncTicketPart *t,
43 			   size_t *len)
44 {
45     return decode_EncTicketPart(data, length, t, len);
46 }
47 
48 krb5_error_code KRB5_LIB_FUNCTION
49 krb5_encode_EncTicketPart (krb5_context context,
50 			   void *data,
51 			   size_t length,
52 			   EncTicketPart *t,
53 			   size_t *len)
54 {
55     return encode_EncTicketPart(data, length, t, len);
56 }
57 
58 krb5_error_code KRB5_LIB_FUNCTION
59 krb5_decode_EncASRepPart (krb5_context context,
60 			  const void *data,
61 			  size_t length,
62 			  EncASRepPart *t,
63 			  size_t *len)
64 {
65     return decode_EncASRepPart(data, length, t, len);
66 }
67 
68 krb5_error_code KRB5_LIB_FUNCTION
69 krb5_encode_EncASRepPart (krb5_context context,
70 			  void *data,
71 			  size_t length,
72 			  EncASRepPart *t,
73 			  size_t *len)
74 {
75     return encode_EncASRepPart(data, length, t, len);
76 }
77 
78 krb5_error_code KRB5_LIB_FUNCTION
79 krb5_decode_EncTGSRepPart (krb5_context context,
80 			   const void *data,
81 			   size_t length,
82 			   EncTGSRepPart *t,
83 			   size_t *len)
84 {
85     return decode_EncTGSRepPart(data, length, t, len);
86 }
87 
88 krb5_error_code KRB5_LIB_FUNCTION
89 krb5_encode_EncTGSRepPart (krb5_context context,
90 			   void *data,
91 			   size_t length,
92 			   EncTGSRepPart *t,
93 			   size_t *len)
94 {
95     return encode_EncTGSRepPart(data, length, t, len);
96 }
97 
98 krb5_error_code KRB5_LIB_FUNCTION
99 krb5_decode_EncAPRepPart (krb5_context context,
100 			  const void *data,
101 			  size_t length,
102 			  EncAPRepPart *t,
103 			  size_t *len)
104 {
105     return decode_EncAPRepPart(data, length, t, len);
106 }
107 
108 krb5_error_code KRB5_LIB_FUNCTION
109 krb5_encode_EncAPRepPart (krb5_context context,
110 			  void *data,
111 			  size_t length,
112 			  EncAPRepPart *t,
113 			  size_t *len)
114 {
115     return encode_EncAPRepPart(data, length, t, len);
116 }
117 
118 krb5_error_code KRB5_LIB_FUNCTION
119 krb5_decode_Authenticator (krb5_context context,
120 			   const void *data,
121 			   size_t length,
122 			   Authenticator *t,
123 			   size_t *len)
124 {
125     return decode_Authenticator(data, length, t, len);
126 }
127 
128 krb5_error_code KRB5_LIB_FUNCTION
129 krb5_encode_Authenticator (krb5_context context,
130 			   void *data,
131 			   size_t length,
132 			   Authenticator *t,
133 			   size_t *len)
134 {
135     return encode_Authenticator(data, length, t, len);
136 }
137 
138 krb5_error_code KRB5_LIB_FUNCTION
139 krb5_decode_EncKrbCredPart (krb5_context context,
140 			    const void *data,
141 			    size_t length,
142 			    EncKrbCredPart *t,
143 			    size_t *len)
144 {
145     return decode_EncKrbCredPart(data, length, t, len);
146 }
147 
148 krb5_error_code KRB5_LIB_FUNCTION
149 krb5_encode_EncKrbCredPart (krb5_context context,
150 			    void *data,
151 			    size_t length,
152 			    EncKrbCredPart *t,
153 			    size_t *len)
154 {
155     return encode_EncKrbCredPart (data, length, t, len);
156 }
157 
158 krb5_error_code KRB5_LIB_FUNCTION
159 krb5_decode_ETYPE_INFO (krb5_context context,
160 			const void *data,
161 			size_t length,
162 			ETYPE_INFO *t,
163 			size_t *len)
164 {
165     return decode_ETYPE_INFO(data, length, t, len);
166 }
167 
168 krb5_error_code KRB5_LIB_FUNCTION
169 krb5_encode_ETYPE_INFO (krb5_context context,
170 			void *data,
171 			size_t length,
172 			ETYPE_INFO *t,
173 			size_t *len)
174 {
175     return encode_ETYPE_INFO (data, length, t, len);
176 }
177 
178 krb5_error_code KRB5_LIB_FUNCTION
179 krb5_decode_ETYPE_INFO2 (krb5_context context,
180 			const void *data,
181 			size_t length,
182 			ETYPE_INFO2 *t,
183 			size_t *len)
184 {
185     return decode_ETYPE_INFO2(data, length, t, len);
186 }
187 
188 krb5_error_code KRB5_LIB_FUNCTION
189 krb5_encode_ETYPE_INFO2 (krb5_context context,
190 			 void *data,
191 			 size_t length,
192 			 ETYPE_INFO2 *t,
193 			 size_t *len)
194 {
195     return encode_ETYPE_INFO2 (data, length, t, len);
196 }
197