1/* Generated from gssapi.asn1 */
2/* Do not edit */
3
4#ifndef __gssapi_asn1_h__
5#define __gssapi_asn1_h__
6
7#include <stddef.h>
8#include <time.h>
9
10#ifndef __asn1_common_definitions__
11#define __asn1_common_definitions__
12
13#ifndef __HEIM_BASE_DATA__
14#define __HEIM_BASE_DATA__ 1
15struct heim_base_data {
16 size_t length;
17 void *data;
18};
19typedef struct heim_base_data heim_octet_string;
20#endif
21
22typedef struct heim_integer {
23 size_t length;
24 void *data;
25 int negative;
26} heim_integer;
27
28typedef char *heim_general_string;
29
30typedef char *heim_utf8_string;
31
32typedef struct heim_base_data heim_printable_string;
33
34typedef struct heim_base_data heim_ia5_string;
35
36typedef struct heim_bmp_string {
37 size_t length;
38 uint16_t *data;
39} heim_bmp_string;
40
41typedef struct heim_universal_string {
42 size_t length;
43 uint32_t *data;
44} heim_universal_string;
45
46typedef char *heim_visible_string;
47
48typedef struct heim_oid {
49 size_t length;
50 unsigned *components;
51} heim_oid;
52
53typedef struct heim_bit_string {
54 size_t length;
55 void *data;
56} heim_bit_string;
57
58typedef struct heim_base_data heim_any;
59typedef struct heim_base_data heim_any_set;
60
61#define ASN1_MALLOC_ENCODE(T, B, BL, S, L, R) \
62 do { \
63 (BL) = length_##T((S)); \
64 (B) = malloc((BL)); \
65 if((B) == NULL) { \
66 (R) = ENOMEM; \
67 } else { \
68 (R) = encode_##T(((unsigned char*)(B)) + (BL) - 1, (BL), \
69 (S), (L)); \
70 if((R) != 0) { \
71 free((B)); \
72 (B) = NULL; \
73 } \
74 } \
75 } while (0)
76
77#ifdef _WIN32
78#ifndef ASN1_LIB
79#define ASN1EXP __declspec(dllimport)
80#else
81#define ASN1EXP
82#endif
83#define ASN1CALL __stdcall
84#else
85#define ASN1EXP
86#define ASN1CALL
87#endif
88struct units;
89
90#endif
91
92#include <krb5/heim_asn1.h>
93/*
94GSSAPIContextToken ::= [APPLICATION 0] IMPLICIT SEQUENCE {
95 thisMech OBJECT IDENTIFIER,
96 innerContextToken heim_any_set,
97}
98*/
99
100typedef struct GSSAPIContextToken {
101 heim_oid thisMech;
102 heim_any_set innerContextToken;
103} GSSAPIContextToken;
104
105ASN1EXP int ASN1CALL decode_GSSAPIContextToken(const unsigned char *, size_t, GSSAPIContextToken *, size_t *);
106ASN1EXP int ASN1CALL encode_GSSAPIContextToken(unsigned char *, size_t, const GSSAPIContextToken *, size_t *);
107ASN1EXP size_t ASN1CALL length_GSSAPIContextToken(const GSSAPIContextToken *);
108ASN1EXP int ASN1CALL copy_GSSAPIContextToken (const GSSAPIContextToken *, GSSAPIContextToken *);
109ASN1EXP void ASN1CALL free_GSSAPIContextToken (GSSAPIContextToken *);
110
111
112#endif /* __gssapi_asn1_h__ */
113