Vanetza
 
Loading...
Searching...
No Matches
InnerAtResponse.c
1/*
2 * Generated by asn1c-0.9.29 (http://lionet.info/asn1c)
3 * From ASN.1 module "EtsiTs102941TypesAuthorization"
4 * found in "asn1/TS102941v131-TypesAuthorization.asn"
5 * `asn1c -fcompound-names -fincludes-quoted -no-gen-example -R`
6 */
7
8#include "InnerAtResponse.h"
9
10static int
11memb_requestHash_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
12 asn_app_constraint_failed_f *ctfailcb, void *app_key) {
13 const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr;
14 size_t size;
15
16 if(!sptr) {
17 ASN__CTFAIL(app_key, td, sptr,
18 "%s: value not given (%s:%d)",
19 td->name, __FILE__, __LINE__);
20 return -1;
21 }
22
23 size = st->size;
24
25 if((size == 16UL)) {
26 /* Constraint check succeeded */
27 return 0;
28 } else {
29 ASN__CTFAIL(app_key, td, sptr,
30 "%s: constraint failed (%s:%d)",
31 td->name, __FILE__, __LINE__);
32 return -1;
33 }
34}
35
36#if !defined(ASN_DISABLE_OER_SUPPORT)
37static asn_oer_constraints_t asn_OER_memb_requestHash_constr_2 CC_NOTUSED = {
38 { 0, 0 },
39 16 /* (SIZE(16..16)) */};
40#endif /* !defined(ASN_DISABLE_OER_SUPPORT) */
41#if !defined(ASN_DISABLE_UPER_SUPPORT) || !defined(ASN_DISABLE_APER_SUPPORT)
42static asn_per_constraints_t asn_PER_memb_requestHash_constr_2 CC_NOTUSED = {
43 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
44 { APC_CONSTRAINED, 0, 0, 16, 16 } /* (SIZE(16..16)) */,
45 0, 0 /* No PER value map */
46};
47#endif /* !defined(ASN_DISABLE_UPER_SUPPORT) || !defined(ASN_DISABLE_APER_SUPPORT) */
48#if !defined(ASN_DISABLE_OER_SUPPORT)
49static asn_oer_constraints_t asn_OER_type_InnerAtResponse_constr_1 CC_NOTUSED = {
50 { 0, 0 },
51 -1};
52#endif /* !defined(ASN_DISABLE_OER_SUPPORT) */
53#if !defined(ASN_DISABLE_UPER_SUPPORT) || !defined(ASN_DISABLE_APER_SUPPORT)
54asn_per_constraints_t asn_PER_type_InnerAtResponse_constr_1 CC_NOTUSED = {
55 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
56 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
57 0, 0 /* No PER value map */
58};
59#endif /* !defined(ASN_DISABLE_UPER_SUPPORT) || !defined(ASN_DISABLE_APER_SUPPORT) */
60asn_TYPE_member_t asn_MBR_InnerAtResponse_1[] = {
61 { ATF_NOFLAGS, 0, offsetof(struct InnerAtResponse, requestHash),
62 (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
63 -1, /* IMPLICIT tag at current level */
64 &asn_DEF_OCTET_STRING,
65 0,
66 {
67#if !defined(ASN_DISABLE_OER_SUPPORT)
68 &asn_OER_memb_requestHash_constr_2,
69#endif /* !defined(ASN_DISABLE_OER_SUPPORT) */
70#if !defined(ASN_DISABLE_UPER_SUPPORT) || !defined(ASN_DISABLE_APER_SUPPORT)
71 &asn_PER_memb_requestHash_constr_2,
72#endif /* !defined(ASN_DISABLE_UPER_SUPPORT) || !defined(ASN_DISABLE_APER_SUPPORT) */
73 memb_requestHash_constraint_1
74 },
75 0, 0, /* No default value */
76 "requestHash"
77 },
78 { ATF_NOFLAGS, 0, offsetof(struct InnerAtResponse, responseCode),
79 (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
80 -1, /* IMPLICIT tag at current level */
81 &asn_DEF_AuthorizationResponseCode,
82 0,
83 {
84#if !defined(ASN_DISABLE_OER_SUPPORT)
85 0,
86#endif /* !defined(ASN_DISABLE_OER_SUPPORT) */
87#if !defined(ASN_DISABLE_UPER_SUPPORT) || !defined(ASN_DISABLE_APER_SUPPORT)
88 0,
89#endif /* !defined(ASN_DISABLE_UPER_SUPPORT) || !defined(ASN_DISABLE_APER_SUPPORT) */
90 0
91 },
92 0, 0, /* No default value */
93 "responseCode"
94 },
95 { ATF_POINTER, 1, offsetof(struct InnerAtResponse, certificate),
96 (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
97 -1, /* IMPLICIT tag at current level */
98 &asn_DEF_EtsiTs103097Certificate,
99 0,
100 {
101#if !defined(ASN_DISABLE_OER_SUPPORT)
102 0,
103#endif /* !defined(ASN_DISABLE_OER_SUPPORT) */
104#if !defined(ASN_DISABLE_UPER_SUPPORT) || !defined(ASN_DISABLE_APER_SUPPORT)
105 0,
106#endif /* !defined(ASN_DISABLE_UPER_SUPPORT) || !defined(ASN_DISABLE_APER_SUPPORT) */
107 0
108 },
109 0, 0, /* No default value */
110 "certificate"
111 },
112};
113static const int asn_MAP_InnerAtResponse_oms_1[] = { 2 };
114static const ber_tlv_tag_t asn_DEF_InnerAtResponse_tags_1[] = {
115 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
116};
117static const asn_TYPE_tag2member_t asn_MAP_InnerAtResponse_tag2el_1[] = {
118 { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* requestHash */
119 { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* responseCode */
120 { (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0 } /* certificate */
121};
122asn_SEQUENCE_specifics_t asn_SPC_InnerAtResponse_specs_1 = {
123 sizeof(struct InnerAtResponse),
124 offsetof(struct InnerAtResponse, _asn_ctx),
125 asn_MAP_InnerAtResponse_tag2el_1,
126 3, /* Count of tags in the map */
127 asn_MAP_InnerAtResponse_oms_1, /* Optional members */
128 1, 0, /* Root/Additions */
129 3, /* First extension addition */
130};
131asn_TYPE_descriptor_t asn_DEF_InnerAtResponse = {
132 "InnerAtResponse",
133 "InnerAtResponse",
134 &asn_OP_SEQUENCE,
135 asn_DEF_InnerAtResponse_tags_1,
136 sizeof(asn_DEF_InnerAtResponse_tags_1)
137 /sizeof(asn_DEF_InnerAtResponse_tags_1[0]), /* 1 */
138 asn_DEF_InnerAtResponse_tags_1, /* Same as above */
139 sizeof(asn_DEF_InnerAtResponse_tags_1)
140 /sizeof(asn_DEF_InnerAtResponse_tags_1[0]), /* 1 */
141 {
142#if !defined(ASN_DISABLE_OER_SUPPORT)
143 &asn_OER_type_InnerAtResponse_constr_1,
144#endif /* !defined(ASN_DISABLE_OER_SUPPORT) */
145#if !defined(ASN_DISABLE_UPER_SUPPORT) || !defined(ASN_DISABLE_APER_SUPPORT)
146 &asn_PER_type_InnerAtResponse_constr_1,
147#endif /* !defined(ASN_DISABLE_UPER_SUPPORT) || !defined(ASN_DISABLE_APER_SUPPORT) */
148 SEQUENCE_constraint
149 },
150 asn_MBR_InnerAtResponse_1,
151 3, /* Elements count */
152 &asn_SPC_InnerAtResponse_specs_1 /* Additional specs */
153};
154