asn1_* renamed into asn_*

This commit is contained in:
Lev Walkin 2004-09-29 13:19:37 +00:00
parent 1ca69678d4
commit dfae9758a7
13 changed files with 1561 additions and 1561 deletions

View File

@ -9,7 +9,7 @@
/*** <<< DEPS [Certificate] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_Certificate;
extern asn_TYPE_descriptor_t asn_DEF_Certificate;
/*** <<< TYPE-DECLS [Certificate] >>> ***/
@ -21,19 +21,19 @@ typedef struct Certificate {
Name_t issuer;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} toBeSigned;
OBJECT_IDENTIFIER_t algorithm;
BIT_STRING_t signature;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} Certificate_t;
/*** <<< CODE [Certificate] >>> ***/
static int
memb_signature_1_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
memb_signature_1_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
const BIT_STRING_t *st = sptr;
size_t size;
@ -66,47 +66,47 @@ memb_signature_1_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
/*** <<< STAT-DEFS [Certificate] >>> ***/
static asn1_TYPE_member_t asn1_MBR_toBeSigned[] = {
static asn_TYPE_member_t asn_MBR_toBeSigned[] = {
{ ATF_NOFLAGS, 0, offsetof(struct toBeSigned, version),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_INTEGER,
.type = (void *)&asn_DEF_INTEGER,
.memb_constraints = 0, /* Defer to actual type */
.name = "version"
},
{ ATF_NOFLAGS, 0, offsetof(struct toBeSigned, signature),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (6 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_OBJECT_IDENTIFIER,
.type = (void *)&asn_DEF_OBJECT_IDENTIFIER,
.memb_constraints = 0, /* Defer to actual type */
.name = "signature"
},
{ ATF_NOFLAGS, 0, offsetof(struct toBeSigned, issuer),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_Name,
.type = (void *)&asn_DEF_Name,
.memb_constraints = 0, /* Defer to actual type */
.name = "issuer"
},
};
static ber_tlv_tag_t asn1_DEF_toBeSigned_tags[] = {
static ber_tlv_tag_t asn_DEF_toBeSigned_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_toBeSigned_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_toBeSigned_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, 0, 0 }, /* version at 21 */
{ (ASN_TAG_CLASS_UNIVERSAL | (6 << 2)), 1, 0, 0 }, /* signature at 22 */
{ (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 2, 0, 0 }, /* issuer at 24 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_toBeSigned_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_toBeSigned_specs = {
sizeof(struct toBeSigned),
offsetof(struct toBeSigned, _ber_dec_ctx),
asn1_DEF_toBeSigned_tag2el,
offsetof(struct toBeSigned, _asn_ctx),
asn_DEF_toBeSigned_tag2el,
3, /* Count of tags in the map */
-1, /* Start extensions */
-1 /* Stop extensions */
};
static /* Use -fall-defs-global to expose */
asn1_TYPE_descriptor_t asn1_DEF_toBeSigned = {
asn_TYPE_descriptor_t asn_DEF_toBeSigned = {
"toBeSigned",
SEQUENCE_free,
SEQUENCE_print,
@ -116,57 +116,57 @@ asn1_TYPE_descriptor_t asn1_DEF_toBeSigned = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_toBeSigned_tags,
sizeof(asn1_DEF_toBeSigned_tags)
/sizeof(asn1_DEF_toBeSigned_tags[0]), /* 1 */
asn1_DEF_toBeSigned_tags, /* Same as above */
sizeof(asn1_DEF_toBeSigned_tags)
/sizeof(asn1_DEF_toBeSigned_tags[0]), /* 1 */
asn1_MBR_toBeSigned,
asn_DEF_toBeSigned_tags,
sizeof(asn_DEF_toBeSigned_tags)
/sizeof(asn_DEF_toBeSigned_tags[0]), /* 1 */
asn_DEF_toBeSigned_tags, /* Same as above */
sizeof(asn_DEF_toBeSigned_tags)
/sizeof(asn_DEF_toBeSigned_tags[0]), /* 1 */
asn_MBR_toBeSigned,
3, /* Elements count */
&asn1_DEF_toBeSigned_specs /* Additional specs */
&asn_DEF_toBeSigned_specs /* Additional specs */
};
static asn1_TYPE_member_t asn1_MBR_Certificate[] = {
static asn_TYPE_member_t asn_MBR_Certificate[] = {
{ ATF_NOFLAGS, 0, offsetof(struct Certificate, toBeSigned),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_toBeSigned,
.type = (void *)&asn_DEF_toBeSigned,
.memb_constraints = 0, /* Defer to actual type */
.name = "toBeSigned"
},
{ ATF_NOFLAGS, 0, offsetof(struct Certificate, algorithm),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (6 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_OBJECT_IDENTIFIER,
.type = (void *)&asn_DEF_OBJECT_IDENTIFIER,
.memb_constraints = 0, /* Defer to actual type */
.name = "algorithm"
},
{ ATF_NOFLAGS, 0, offsetof(struct Certificate, signature),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (3 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_BIT_STRING,
.type = (void *)&asn_DEF_BIT_STRING,
.memb_constraints = memb_signature_1_constraint,
.name = "signature"
},
};
static ber_tlv_tag_t asn1_DEF_Certificate_tags[] = {
static ber_tlv_tag_t asn_DEF_Certificate_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_Certificate_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_Certificate_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (3 << 2)), 2, 0, 0 }, /* signature at 17 */
{ (ASN_TAG_CLASS_UNIVERSAL | (6 << 2)), 1, 0, 0 }, /* algorithm at 16 */
{ (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, 0, 0 }, /* toBeSigned at 21 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_Certificate_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_Certificate_specs = {
sizeof(struct Certificate),
offsetof(struct Certificate, _ber_dec_ctx),
asn1_DEF_Certificate_tag2el,
offsetof(struct Certificate, _asn_ctx),
asn_DEF_Certificate_tag2el,
3, /* Count of tags in the map */
-1, /* Start extensions */
-1 /* Stop extensions */
};
asn1_TYPE_descriptor_t asn1_DEF_Certificate = {
asn_TYPE_descriptor_t asn_DEF_Certificate = {
"Certificate",
SEQUENCE_free,
SEQUENCE_print,
@ -176,15 +176,15 @@ asn1_TYPE_descriptor_t asn1_DEF_Certificate = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_Certificate_tags,
sizeof(asn1_DEF_Certificate_tags)
/sizeof(asn1_DEF_Certificate_tags[0]), /* 1 */
asn1_DEF_Certificate_tags, /* Same as above */
sizeof(asn1_DEF_Certificate_tags)
/sizeof(asn1_DEF_Certificate_tags[0]), /* 1 */
asn1_MBR_Certificate,
asn_DEF_Certificate_tags,
sizeof(asn_DEF_Certificate_tags)
/sizeof(asn_DEF_Certificate_tags[0]), /* 1 */
asn_DEF_Certificate_tags, /* Same as above */
sizeof(asn_DEF_Certificate_tags)
/sizeof(asn_DEF_Certificate_tags[0]), /* 1 */
asn_MBR_Certificate,
3, /* Elements count */
&asn1_DEF_Certificate_specs /* Additional specs */
&asn_DEF_Certificate_specs /* Additional specs */
};
@ -196,7 +196,7 @@ asn1_TYPE_descriptor_t asn1_DEF_Certificate = {
/*** <<< DEPS [Name] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_Name;
extern asn_TYPE_descriptor_t asn_DEF_Name;
/*** <<< TYPE-DECLS [Name] >>> ***/
@ -205,29 +205,29 @@ typedef struct Name {
A_SEQUENCE_OF(RelativeDistinguishedName_t) list;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} Name_t;
/*** <<< STAT-DEFS [Name] >>> ***/
static asn1_TYPE_member_t asn1_MBR_Name[] = {
static asn_TYPE_member_t asn_MBR_Name[] = {
{ ATF_NOFLAGS, 0, 0,
.tag = (ASN_TAG_CLASS_UNIVERSAL | (17 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_RelativeDistinguishedName,
.type = (void *)&asn_DEF_RelativeDistinguishedName,
.memb_constraints = 0, /* Defer to actual type */
.name = ""
},
};
static ber_tlv_tag_t asn1_DEF_Name_tags[] = {
static ber_tlv_tag_t asn_DEF_Name_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_SET_OF_specifics_t asn1_DEF_Name_specs = {
static asn_SET_OF_specifics_t asn_DEF_Name_specs = {
sizeof(struct Name),
offsetof(struct Name, _ber_dec_ctx),
offsetof(struct Name, _asn_ctx),
0, /* XER encoding is XMLDelimitedItemList */
};
asn1_TYPE_descriptor_t asn1_DEF_Name = {
asn_TYPE_descriptor_t asn_DEF_Name = {
"Name",
SEQUENCE_OF_free,
SEQUENCE_OF_print,
@ -237,15 +237,15 @@ asn1_TYPE_descriptor_t asn1_DEF_Name = {
0, /* Not implemented yet */
SEQUENCE_OF_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_Name_tags,
sizeof(asn1_DEF_Name_tags)
/sizeof(asn1_DEF_Name_tags[0]), /* 1 */
asn1_DEF_Name_tags, /* Same as above */
sizeof(asn1_DEF_Name_tags)
/sizeof(asn1_DEF_Name_tags[0]), /* 1 */
asn1_MBR_Name,
asn_DEF_Name_tags,
sizeof(asn_DEF_Name_tags)
/sizeof(asn_DEF_Name_tags[0]), /* 1 */
asn_DEF_Name_tags, /* Same as above */
sizeof(asn_DEF_Name_tags)
/sizeof(asn_DEF_Name_tags[0]), /* 1 */
asn_MBR_Name,
1, /* Single element */
&asn1_DEF_Name_specs /* Additional specs */
&asn_DEF_Name_specs /* Additional specs */
};
@ -257,7 +257,7 @@ asn1_TYPE_descriptor_t asn1_DEF_Name = {
/*** <<< DEPS [RelativeDistinguishedName] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_RelativeDistinguishedName;
extern asn_TYPE_descriptor_t asn_DEF_RelativeDistinguishedName;
/*** <<< TYPE-DECLS [RelativeDistinguishedName] >>> ***/
@ -266,7 +266,7 @@ typedef struct RelativeDistinguishedName {
A_SET_OF(IA5String_t) list;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} RelativeDistinguishedName_t;
/*** <<< CTABLES [RelativeDistinguishedName] >>> ***/
@ -300,7 +300,7 @@ static int check_permitted_alphabet_1(const void *sptr) {
/*** <<< CODE [RelativeDistinguishedName] >>> ***/
static int
memb_IA5String_2_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
memb_IA5String_2_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
const IA5String_t *st = sptr;
@ -326,24 +326,24 @@ memb_IA5String_2_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
/*** <<< STAT-DEFS [RelativeDistinguishedName] >>> ***/
static asn1_TYPE_member_t asn1_MBR_RelativeDistinguishedName[] = {
static asn_TYPE_member_t asn_MBR_RelativeDistinguishedName[] = {
{ ATF_NOFLAGS, 0, 0,
.tag = (ASN_TAG_CLASS_UNIVERSAL | (22 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_IA5String,
.type = (void *)&asn_DEF_IA5String,
.memb_constraints = memb_IA5String_2_constraint,
.name = ""
},
};
static ber_tlv_tag_t asn1_DEF_RelativeDistinguishedName_tags[] = {
static ber_tlv_tag_t asn_DEF_RelativeDistinguishedName_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
};
static asn1_SET_OF_specifics_t asn1_DEF_RelativeDistinguishedName_specs = {
static asn_SET_OF_specifics_t asn_DEF_RelativeDistinguishedName_specs = {
sizeof(struct RelativeDistinguishedName),
offsetof(struct RelativeDistinguishedName, _ber_dec_ctx),
offsetof(struct RelativeDistinguishedName, _asn_ctx),
0, /* XER encoding is XMLDelimitedItemList */
};
asn1_TYPE_descriptor_t asn1_DEF_RelativeDistinguishedName = {
asn_TYPE_descriptor_t asn_DEF_RelativeDistinguishedName = {
"RelativeDistinguishedName",
SET_OF_free,
SET_OF_print,
@ -353,14 +353,14 @@ asn1_TYPE_descriptor_t asn1_DEF_RelativeDistinguishedName = {
0, /* Not implemented yet */
SET_OF_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_RelativeDistinguishedName_tags,
sizeof(asn1_DEF_RelativeDistinguishedName_tags)
/sizeof(asn1_DEF_RelativeDistinguishedName_tags[0]), /* 1 */
asn1_DEF_RelativeDistinguishedName_tags, /* Same as above */
sizeof(asn1_DEF_RelativeDistinguishedName_tags)
/sizeof(asn1_DEF_RelativeDistinguishedName_tags[0]), /* 1 */
asn1_MBR_RelativeDistinguishedName,
asn_DEF_RelativeDistinguishedName_tags,
sizeof(asn_DEF_RelativeDistinguishedName_tags)
/sizeof(asn_DEF_RelativeDistinguishedName_tags[0]), /* 1 */
asn_DEF_RelativeDistinguishedName_tags, /* Same as above */
sizeof(asn_DEF_RelativeDistinguishedName_tags)
/sizeof(asn_DEF_RelativeDistinguishedName_tags[0]), /* 1 */
asn_MBR_RelativeDistinguishedName,
1, /* Single element */
&asn1_DEF_RelativeDistinguishedName_specs /* Additional specs */
&asn_DEF_RelativeDistinguishedName_specs /* Additional specs */
};

View File

@ -7,7 +7,7 @@
/*** <<< DEPS [Forest] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_Forest;
extern asn_TYPE_descriptor_t asn_DEF_Forest;
/*** <<< TYPE-DECLS [Forest] >>> ***/
@ -16,29 +16,29 @@ typedef struct Forest {
A_SET_OF(Tree_t) list;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} Forest_t;
/*** <<< STAT-DEFS [Forest] >>> ***/
static asn1_TYPE_member_t asn1_MBR_Forest[] = {
static asn_TYPE_member_t asn_MBR_Forest[] = {
{ ATF_NOFLAGS, 0, 0,
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_Tree,
.type = (void *)&asn_DEF_Tree,
.memb_constraints = 0, /* Defer to actual type */
.name = ""
},
};
static ber_tlv_tag_t asn1_DEF_Forest_tags[] = {
static ber_tlv_tag_t asn_DEF_Forest_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
};
static asn1_SET_OF_specifics_t asn1_DEF_Forest_specs = {
static asn_SET_OF_specifics_t asn_DEF_Forest_specs = {
sizeof(struct Forest),
offsetof(struct Forest, _ber_dec_ctx),
offsetof(struct Forest, _asn_ctx),
0, /* XER encoding is XMLDelimitedItemList */
};
asn1_TYPE_descriptor_t asn1_DEF_Forest = {
asn_TYPE_descriptor_t asn_DEF_Forest = {
"Forest",
SET_OF_free,
SET_OF_print,
@ -48,15 +48,15 @@ asn1_TYPE_descriptor_t asn1_DEF_Forest = {
0, /* Not implemented yet */
SET_OF_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_Forest_tags,
sizeof(asn1_DEF_Forest_tags)
/sizeof(asn1_DEF_Forest_tags[0]), /* 1 */
asn1_DEF_Forest_tags, /* Same as above */
sizeof(asn1_DEF_Forest_tags)
/sizeof(asn1_DEF_Forest_tags[0]), /* 1 */
asn1_MBR_Forest,
asn_DEF_Forest_tags,
sizeof(asn_DEF_Forest_tags)
/sizeof(asn_DEF_Forest_tags[0]), /* 1 */
asn_DEF_Forest_tags, /* Same as above */
sizeof(asn_DEF_Forest_tags)
/sizeof(asn_DEF_Forest_tags[0]), /* 1 */
asn_MBR_Forest,
1, /* Single element */
&asn1_DEF_Forest_specs /* Additional specs */
&asn_DEF_Forest_specs /* Additional specs */
};
@ -67,7 +67,7 @@ asn1_TYPE_descriptor_t asn1_DEF_Forest = {
/*** <<< DEPS [Tree] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_Tree;
extern asn_TYPE_descriptor_t asn_DEF_Tree;
/*** <<< TYPE-DECLS [Tree] >>> ***/
@ -77,43 +77,43 @@ typedef struct Tree {
INTEGER_t width;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} Tree_t;
/*** <<< STAT-DEFS [Tree] >>> ***/
static asn1_TYPE_member_t asn1_MBR_Tree[] = {
static asn_TYPE_member_t asn_MBR_Tree[] = {
{ ATF_NOFLAGS, 0, offsetof(struct Tree, height),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_INTEGER,
.type = (void *)&asn_DEF_INTEGER,
.memb_constraints = 0, /* Defer to actual type */
.name = "height"
},
{ ATF_NOFLAGS, 0, offsetof(struct Tree, width),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_INTEGER,
.type = (void *)&asn_DEF_INTEGER,
.memb_constraints = 0, /* Defer to actual type */
.name = "width"
},
};
static ber_tlv_tag_t asn1_DEF_Tree_tags[] = {
static ber_tlv_tag_t asn_DEF_Tree_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_Tree_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_Tree_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, 0, 1 }, /* height at 17 */
{ (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 1, -1, 0 }, /* width at 19 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_Tree_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_Tree_specs = {
sizeof(struct Tree),
offsetof(struct Tree, _ber_dec_ctx),
asn1_DEF_Tree_tag2el,
offsetof(struct Tree, _asn_ctx),
asn_DEF_Tree_tag2el,
2, /* Count of tags in the map */
-1, /* Start extensions */
-1 /* Stop extensions */
};
asn1_TYPE_descriptor_t asn1_DEF_Tree = {
asn_TYPE_descriptor_t asn_DEF_Tree = {
"Tree",
SEQUENCE_free,
SEQUENCE_print,
@ -123,15 +123,15 @@ asn1_TYPE_descriptor_t asn1_DEF_Tree = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_Tree_tags,
sizeof(asn1_DEF_Tree_tags)
/sizeof(asn1_DEF_Tree_tags[0]), /* 1 */
asn1_DEF_Tree_tags, /* Same as above */
sizeof(asn1_DEF_Tree_tags)
/sizeof(asn1_DEF_Tree_tags[0]), /* 1 */
asn1_MBR_Tree,
asn_DEF_Tree_tags,
sizeof(asn_DEF_Tree_tags)
/sizeof(asn_DEF_Tree_tags[0]), /* 1 */
asn_DEF_Tree_tags, /* Same as above */
sizeof(asn_DEF_Tree_tags)
/sizeof(asn_DEF_Tree_tags[0]), /* 1 */
asn_MBR_Tree,
2, /* Elements count */
&asn1_DEF_Tree_specs /* Additional specs */
&asn_DEF_Tree_specs /* Additional specs */
};
@ -154,7 +154,7 @@ typedef enum Stuff_PR {
Stuff_PR_trees, /* Member trees is present */
Stuff_PR_anything, /* Member anything is present */
} Stuff_PR;
extern asn1_TYPE_descriptor_t asn1_DEF_Stuff;
extern asn_TYPE_descriptor_t asn_DEF_Stuff;
/*** <<< TYPE-DECLS [Stuff] >>> ***/
@ -164,7 +164,7 @@ typedef struct Stuff {
A_SET_OF(Forest_t) list;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} *trees;
struct anything {
A_SET_OF(struct anything_member {
@ -175,11 +175,11 @@ typedef struct Stuff {
*/
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} ) list;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} *anything;
/* Presence bitmask: ASN_SET_ISPRESENT(pStuff, Stuff_PR_x) */
@ -187,31 +187,31 @@ typedef struct Stuff {
[((2+(8*sizeof(unsigned int))-1)/(8*sizeof(unsigned int)))];
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} Stuff_t;
/*** <<< STAT-DEFS [Stuff] >>> ***/
static asn1_TYPE_member_t asn1_MBR_trees[] = {
static asn_TYPE_member_t asn_MBR_trees[] = {
{ ATF_NOFLAGS, 0, 0,
.tag = (ASN_TAG_CLASS_UNIVERSAL | (17 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_Forest,
.type = (void *)&asn_DEF_Forest,
.memb_constraints = 0, /* Defer to actual type */
.name = ""
},
};
static ber_tlv_tag_t asn1_DEF_trees_tags[] = {
static ber_tlv_tag_t asn_DEF_trees_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (0 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
};
static asn1_SET_OF_specifics_t asn1_DEF_trees_specs = {
static asn_SET_OF_specifics_t asn_DEF_trees_specs = {
sizeof(struct trees),
offsetof(struct trees, _ber_dec_ctx),
offsetof(struct trees, _asn_ctx),
0, /* XER encoding is XMLDelimitedItemList */
};
static /* Use -fall-defs-global to expose */
asn1_TYPE_descriptor_t asn1_DEF_trees = {
asn_TYPE_descriptor_t asn_DEF_trees = {
"trees",
SET_OF_free,
SET_OF_print,
@ -221,42 +221,42 @@ asn1_TYPE_descriptor_t asn1_DEF_trees = {
0, /* Not implemented yet */
SET_OF_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_trees_tags,
sizeof(asn1_DEF_trees_tags)
/sizeof(asn1_DEF_trees_tags[0]) - 1, /* 1 */
asn1_DEF_trees_tags, /* Same as above */
sizeof(asn1_DEF_trees_tags)
/sizeof(asn1_DEF_trees_tags[0]), /* 2 */
asn1_MBR_trees,
asn_DEF_trees_tags,
sizeof(asn_DEF_trees_tags)
/sizeof(asn_DEF_trees_tags[0]) - 1, /* 1 */
asn_DEF_trees_tags, /* Same as above */
sizeof(asn_DEF_trees_tags)
/sizeof(asn_DEF_trees_tags[0]), /* 2 */
asn_MBR_trees,
1, /* Single element */
&asn1_DEF_trees_specs /* Additional specs */
&asn_DEF_trees_specs /* Additional specs */
};
static asn1_TYPE_member_t asn1_MBR_anything_member[] = {
static asn_TYPE_member_t asn_MBR_anything_member[] = {
{ ATF_NOFLAGS, 0, offsetof(struct anything_member, cup_of_coffee),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (3 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_BIT_STRING,
.type = (void *)&asn_DEF_BIT_STRING,
.memb_constraints = 0, /* Defer to actual type */
.name = "cup-of-coffee"
},
};
static ber_tlv_tag_t asn1_DEF_anything_member_tags[] = {
static ber_tlv_tag_t asn_DEF_anything_member_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_anything_member_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_anything_member_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (3 << 2)), 0, 0, 0 }, /* cup-of-coffee at 26 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_anything_member_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_anything_member_specs = {
sizeof(struct anything_member),
offsetof(struct anything_member, _ber_dec_ctx),
asn1_DEF_anything_member_tag2el,
offsetof(struct anything_member, _asn_ctx),
asn_DEF_anything_member_tag2el,
1, /* Count of tags in the map */
0, /* Start extensions */
2 /* Stop extensions */
};
static /* Use -fall-defs-global to expose */
asn1_TYPE_descriptor_t asn1_DEF_anything_member = {
asn_TYPE_descriptor_t asn_DEF_anything_member = {
"",
SEQUENCE_free,
SEQUENCE_print,
@ -266,37 +266,37 @@ asn1_TYPE_descriptor_t asn1_DEF_anything_member = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_anything_member_tags,
sizeof(asn1_DEF_anything_member_tags)
/sizeof(asn1_DEF_anything_member_tags[0]), /* 1 */
asn1_DEF_anything_member_tags, /* Same as above */
sizeof(asn1_DEF_anything_member_tags)
/sizeof(asn1_DEF_anything_member_tags[0]), /* 1 */
asn1_MBR_anything_member,
asn_DEF_anything_member_tags,
sizeof(asn_DEF_anything_member_tags)
/sizeof(asn_DEF_anything_member_tags[0]), /* 1 */
asn_DEF_anything_member_tags, /* Same as above */
sizeof(asn_DEF_anything_member_tags)
/sizeof(asn_DEF_anything_member_tags[0]), /* 1 */
asn_MBR_anything_member,
1, /* Elements count */
&asn1_DEF_anything_member_specs /* Additional specs */
&asn_DEF_anything_member_specs /* Additional specs */
};
static asn1_TYPE_member_t asn1_MBR_anything[] = {
static asn_TYPE_member_t asn_MBR_anything[] = {
{ ATF_NOFLAGS, 0, 0,
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_anything_member,
.type = (void *)&asn_DEF_anything_member,
.memb_constraints = 0, /* Defer to actual type */
.name = ""
},
};
static ber_tlv_tag_t asn1_DEF_anything_tags[] = {
static ber_tlv_tag_t asn_DEF_anything_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (1 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
};
static asn1_SET_OF_specifics_t asn1_DEF_anything_specs = {
static asn_SET_OF_specifics_t asn_DEF_anything_specs = {
sizeof(struct anything),
offsetof(struct anything, _ber_dec_ctx),
offsetof(struct anything, _asn_ctx),
0, /* XER encoding is XMLDelimitedItemList */
};
static /* Use -fall-defs-global to expose */
asn1_TYPE_descriptor_t asn1_DEF_anything = {
asn_TYPE_descriptor_t asn_DEF_anything = {
"anything",
SET_OF_free,
SET_OF_print,
@ -306,53 +306,53 @@ asn1_TYPE_descriptor_t asn1_DEF_anything = {
0, /* Not implemented yet */
SET_OF_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_anything_tags,
sizeof(asn1_DEF_anything_tags)
/sizeof(asn1_DEF_anything_tags[0]) - 1, /* 1 */
asn1_DEF_anything_tags, /* Same as above */
sizeof(asn1_DEF_anything_tags)
/sizeof(asn1_DEF_anything_tags[0]), /* 2 */
asn1_MBR_anything,
asn_DEF_anything_tags,
sizeof(asn_DEF_anything_tags)
/sizeof(asn_DEF_anything_tags[0]) - 1, /* 1 */
asn_DEF_anything_tags, /* Same as above */
sizeof(asn_DEF_anything_tags)
/sizeof(asn_DEF_anything_tags[0]), /* 2 */
asn_MBR_anything,
1, /* Single element */
&asn1_DEF_anything_specs /* Additional specs */
&asn_DEF_anything_specs /* Additional specs */
};
static asn1_TYPE_member_t asn1_MBR_Stuff[] = {
static asn_TYPE_member_t asn_MBR_Stuff[] = {
{ ATF_POINTER, 2, offsetof(struct Stuff, trees),
.tag = (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_trees,
.type = (void *)&asn_DEF_trees,
.memb_constraints = 0, /* Defer to actual type */
.name = "trees"
},
{ ATF_POINTER, 1, offsetof(struct Stuff, anything),
.tag = (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_anything,
.type = (void *)&asn_DEF_anything,
.memb_constraints = 0, /* Defer to actual type */
.name = "anything"
},
};
static ber_tlv_tag_t asn1_DEF_Stuff_tags[] = {
static ber_tlv_tag_t asn_DEF_Stuff_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_Stuff_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_Stuff_tag2el[] = {
{ (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* trees at 23 */
{ (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* anything at 28 */
};
static uint8_t asn1_DEF_Stuff_mmap[(2 + (8 * sizeof(unsigned int)) - 1) / 8] = {
static uint8_t asn_DEF_Stuff_mmap[(2 + (8 * sizeof(unsigned int)) - 1) / 8] = {
(0 << 7) | (0 << 6)
};
static asn1_SET_specifics_t asn1_DEF_Stuff_specs = {
static asn_SET_specifics_t asn_DEF_Stuff_specs = {
sizeof(struct Stuff),
offsetof(struct Stuff, _ber_dec_ctx),
offsetof(struct Stuff, _asn_ctx),
offsetof(struct Stuff, _presence_map),
asn1_DEF_Stuff_tag2el,
asn_DEF_Stuff_tag2el,
2, /* Count of tags in the map */
0, /* Whether extensible */
(unsigned int *)asn1_DEF_Stuff_mmap /* Mandatory elements map */
(unsigned int *)asn_DEF_Stuff_mmap /* Mandatory elements map */
};
asn1_TYPE_descriptor_t asn1_DEF_Stuff = {
asn_TYPE_descriptor_t asn_DEF_Stuff = {
"Stuff",
SET_free,
SET_print,
@ -362,14 +362,14 @@ asn1_TYPE_descriptor_t asn1_DEF_Stuff = {
0, /* Not implemented yet */
SET_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_Stuff_tags,
sizeof(asn1_DEF_Stuff_tags)
/sizeof(asn1_DEF_Stuff_tags[0]), /* 1 */
asn1_DEF_Stuff_tags, /* Same as above */
sizeof(asn1_DEF_Stuff_tags)
/sizeof(asn1_DEF_Stuff_tags[0]), /* 1 */
asn1_MBR_Stuff,
asn_DEF_Stuff_tags,
sizeof(asn_DEF_Stuff_tags)
/sizeof(asn_DEF_Stuff_tags[0]), /* 1 */
asn_DEF_Stuff_tags, /* Same as above */
sizeof(asn_DEF_Stuff_tags)
/sizeof(asn_DEF_Stuff_tags[0]), /* 1 */
asn_MBR_Stuff,
2, /* Elements count */
&asn1_DEF_Stuff_specs /* Additional specs */
&asn_DEF_Stuff_specs /* Additional specs */
};

View File

@ -7,7 +7,7 @@
/*** <<< DEPS [Programming] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_Programming;
extern asn_TYPE_descriptor_t asn_DEF_Programming;
/*** <<< TYPE-DECLS [Programming] >>> ***/
@ -16,29 +16,29 @@ typedef struct Programming {
A_SEQUENCE_OF(Fault_t) list;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} Programming_t;
/*** <<< STAT-DEFS [Programming] >>> ***/
static asn1_TYPE_member_t asn1_MBR_Programming[] = {
static asn_TYPE_member_t asn_MBR_Programming[] = {
{ ATF_NOFLAGS, 0, 0,
.tag = (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_Fault,
.type = (void *)&asn_DEF_Fault,
.memb_constraints = 0, /* Defer to actual type */
.name = ""
},
};
static ber_tlv_tag_t asn1_DEF_Programming_tags[] = {
static ber_tlv_tag_t asn_DEF_Programming_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_SET_OF_specifics_t asn1_DEF_Programming_specs = {
static asn_SET_OF_specifics_t asn_DEF_Programming_specs = {
sizeof(struct Programming),
offsetof(struct Programming, _ber_dec_ctx),
offsetof(struct Programming, _asn_ctx),
0, /* XER encoding is XMLDelimitedItemList */
};
asn1_TYPE_descriptor_t asn1_DEF_Programming = {
asn_TYPE_descriptor_t asn_DEF_Programming = {
"Programming",
SEQUENCE_OF_free,
SEQUENCE_OF_print,
@ -48,15 +48,15 @@ asn1_TYPE_descriptor_t asn1_DEF_Programming = {
0, /* Not implemented yet */
SEQUENCE_OF_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_Programming_tags,
sizeof(asn1_DEF_Programming_tags)
/sizeof(asn1_DEF_Programming_tags[0]), /* 1 */
asn1_DEF_Programming_tags, /* Same as above */
sizeof(asn1_DEF_Programming_tags)
/sizeof(asn1_DEF_Programming_tags[0]), /* 1 */
asn1_MBR_Programming,
asn_DEF_Programming_tags,
sizeof(asn_DEF_Programming_tags)
/sizeof(asn_DEF_Programming_tags[0]), /* 1 */
asn_DEF_Programming_tags, /* Same as above */
sizeof(asn_DEF_Programming_tags)
/sizeof(asn_DEF_Programming_tags[0]), /* 1 */
asn_MBR_Programming,
1, /* Single element */
&asn1_DEF_Programming_specs /* Additional specs */
&asn_DEF_Programming_specs /* Additional specs */
};
@ -68,7 +68,7 @@ asn1_TYPE_descriptor_t asn1_DEF_Programming = {
/*** <<< DEPS [Fault] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_Fault;
extern asn_TYPE_descriptor_t asn_DEF_Fault;
/*** <<< TYPE-DECLS [Fault] >>> ***/
@ -77,29 +77,29 @@ typedef struct Fault {
A_SET_OF(Error_t) list;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} Fault_t;
/*** <<< STAT-DEFS [Fault] >>> ***/
static asn1_TYPE_member_t asn1_MBR_Fault[] = {
static asn_TYPE_member_t asn_MBR_Fault[] = {
{ ATF_NOFLAGS, 0, 0,
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_Error,
.type = (void *)&asn_DEF_Error,
.memb_constraints = 0, /* Defer to actual type */
.name = ""
},
};
static ber_tlv_tag_t asn1_DEF_Fault_tags[] = {
static ber_tlv_tag_t asn_DEF_Fault_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
};
static asn1_SET_OF_specifics_t asn1_DEF_Fault_specs = {
static asn_SET_OF_specifics_t asn_DEF_Fault_specs = {
sizeof(struct Fault),
offsetof(struct Fault, _ber_dec_ctx),
offsetof(struct Fault, _asn_ctx),
0, /* XER encoding is XMLDelimitedItemList */
};
asn1_TYPE_descriptor_t asn1_DEF_Fault = {
asn_TYPE_descriptor_t asn_DEF_Fault = {
"Fault",
SET_OF_free,
SET_OF_print,
@ -109,15 +109,15 @@ asn1_TYPE_descriptor_t asn1_DEF_Fault = {
0, /* Not implemented yet */
SET_OF_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_Fault_tags,
sizeof(asn1_DEF_Fault_tags)
/sizeof(asn1_DEF_Fault_tags[0]), /* 1 */
asn1_DEF_Fault_tags, /* Same as above */
sizeof(asn1_DEF_Fault_tags)
/sizeof(asn1_DEF_Fault_tags[0]), /* 1 */
asn1_MBR_Fault,
asn_DEF_Fault_tags,
sizeof(asn_DEF_Fault_tags)
/sizeof(asn_DEF_Fault_tags[0]), /* 1 */
asn_DEF_Fault_tags, /* Same as above */
sizeof(asn_DEF_Fault_tags)
/sizeof(asn_DEF_Fault_tags[0]), /* 1 */
asn_MBR_Fault,
1, /* Single element */
&asn1_DEF_Fault_specs /* Additional specs */
&asn_DEF_Fault_specs /* Additional specs */
};
@ -127,7 +127,7 @@ asn1_TYPE_descriptor_t asn1_DEF_Fault = {
/*** <<< DEPS [Error] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_Error;
extern asn_TYPE_descriptor_t asn_DEF_Error;
/*** <<< TYPE-DECLS [Error] >>> ***/
@ -139,25 +139,25 @@ typedef struct Error {
*/
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} Error_t;
/*** <<< STAT-DEFS [Error] >>> ***/
static ber_tlv_tag_t asn1_DEF_Error_tags[] = {
static ber_tlv_tag_t asn_DEF_Error_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_Error_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_Error_tag2el[] = {
};
static asn1_SEQUENCE_specifics_t asn1_DEF_Error_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_Error_specs = {
sizeof(struct Error),
offsetof(struct Error, _ber_dec_ctx),
asn1_DEF_Error_tag2el,
offsetof(struct Error, _asn_ctx),
asn_DEF_Error_tag2el,
0, /* Count of tags in the map */
-1, /* Start extensions */
-1 /* Stop extensions */
};
asn1_TYPE_descriptor_t asn1_DEF_Error = {
asn_TYPE_descriptor_t asn_DEF_Error = {
"Error",
SEQUENCE_free,
SEQUENCE_print,
@ -167,13 +167,13 @@ asn1_TYPE_descriptor_t asn1_DEF_Error = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_Error_tags,
sizeof(asn1_DEF_Error_tags)
/sizeof(asn1_DEF_Error_tags[0]), /* 1 */
asn1_DEF_Error_tags, /* Same as above */
sizeof(asn1_DEF_Error_tags)
/sizeof(asn1_DEF_Error_tags[0]), /* 1 */
asn_DEF_Error_tags,
sizeof(asn_DEF_Error_tags)
/sizeof(asn_DEF_Error_tags[0]), /* 1 */
asn_DEF_Error_tags, /* Same as above */
sizeof(asn_DEF_Error_tags)
/sizeof(asn_DEF_Error_tags[0]), /* 1 */
0, 0, /* No members */
&asn1_DEF_Error_specs /* Additional specs */
&asn_DEF_Error_specs /* Additional specs */
};

View File

@ -9,7 +9,7 @@
/*** <<< DEPS [T] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T;
extern asn_TYPE_descriptor_t asn_DEF_T;
/*** <<< TYPE-DECLS [T] >>> ***/
@ -20,34 +20,34 @@ typedef struct T {
A_SEQUENCE_OF(T2_t) list;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} collection;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} T_t;
/*** <<< STAT-DEFS [T] >>> ***/
static asn1_TYPE_member_t asn1_MBR_collection[] = {
static asn_TYPE_member_t asn_MBR_collection[] = {
{ ATF_NOFLAGS, 0, 0,
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_T2,
.type = (void *)&asn_DEF_T2,
.memb_constraints = 0, /* Defer to actual type */
.name = ""
},
};
static ber_tlv_tag_t asn1_DEF_collection_tags[] = {
static ber_tlv_tag_t asn_DEF_collection_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_SET_OF_specifics_t asn1_DEF_collection_specs = {
static asn_SET_OF_specifics_t asn_DEF_collection_specs = {
sizeof(struct collection),
offsetof(struct collection, _ber_dec_ctx),
offsetof(struct collection, _asn_ctx),
0, /* XER encoding is XMLDelimitedItemList */
};
static /* Use -fall-defs-global to expose */
asn1_TYPE_descriptor_t asn1_DEF_collection = {
asn_TYPE_descriptor_t asn_DEF_collection = {
"collection",
SEQUENCE_OF_free,
SEQUENCE_OF_print,
@ -57,49 +57,49 @@ asn1_TYPE_descriptor_t asn1_DEF_collection = {
0, /* Not implemented yet */
SEQUENCE_OF_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_collection_tags,
sizeof(asn1_DEF_collection_tags)
/sizeof(asn1_DEF_collection_tags[0]), /* 1 */
asn1_DEF_collection_tags, /* Same as above */
sizeof(asn1_DEF_collection_tags)
/sizeof(asn1_DEF_collection_tags[0]), /* 1 */
asn1_MBR_collection,
asn_DEF_collection_tags,
sizeof(asn_DEF_collection_tags)
/sizeof(asn_DEF_collection_tags[0]), /* 1 */
asn_DEF_collection_tags, /* Same as above */
sizeof(asn_DEF_collection_tags)
/sizeof(asn_DEF_collection_tags[0]), /* 1 */
asn_MBR_collection,
1, /* Single element */
&asn1_DEF_collection_specs /* Additional specs */
&asn_DEF_collection_specs /* Additional specs */
};
static asn1_TYPE_member_t asn1_MBR_T[] = {
static asn_TYPE_member_t asn_MBR_T[] = {
{ ATF_NOFLAGS, 0, offsetof(struct T, int),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_INTEGER,
.type = (void *)&asn_DEF_INTEGER,
.memb_constraints = 0, /* Defer to actual type */
.name = "int"
},
{ ATF_NOFLAGS, 0, offsetof(struct T, collection),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_collection,
.type = (void *)&asn_DEF_collection,
.memb_constraints = 0, /* Defer to actual type */
.name = "collection"
},
};
static ber_tlv_tag_t asn1_DEF_T_tags[] = {
static ber_tlv_tag_t asn_DEF_T_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_T_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_T_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, 0, 0 }, /* int at 15 */
{ (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 1, 0, 0 }, /* collection at 17 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_T_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_T_specs = {
sizeof(struct T),
offsetof(struct T, _ber_dec_ctx),
asn1_DEF_T_tag2el,
offsetof(struct T, _asn_ctx),
asn_DEF_T_tag2el,
2, /* Count of tags in the map */
-1, /* Start extensions */
-1 /* Stop extensions */
};
asn1_TYPE_descriptor_t asn1_DEF_T = {
asn_TYPE_descriptor_t asn_DEF_T = {
"T",
SEQUENCE_free,
SEQUENCE_print,
@ -109,15 +109,15 @@ asn1_TYPE_descriptor_t asn1_DEF_T = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T_tags,
sizeof(asn1_DEF_T_tags)
/sizeof(asn1_DEF_T_tags[0]), /* 1 */
asn1_DEF_T_tags, /* Same as above */
sizeof(asn1_DEF_T_tags)
/sizeof(asn1_DEF_T_tags[0]), /* 1 */
asn1_MBR_T,
asn_DEF_T_tags,
sizeof(asn_DEF_T_tags)
/sizeof(asn_DEF_T_tags[0]), /* 1 */
asn_DEF_T_tags, /* Same as above */
sizeof(asn_DEF_T_tags)
/sizeof(asn_DEF_T_tags[0]), /* 1 */
asn_MBR_T,
2, /* Elements count */
&asn1_DEF_T_specs /* Additional specs */
&asn_DEF_T_specs /* Additional specs */
};
@ -129,7 +129,7 @@ asn1_TYPE_descriptor_t asn1_DEF_T = {
/*** <<< DEPS [T2] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T2;
extern asn_TYPE_descriptor_t asn_DEF_T2;
/*** <<< TYPE-DECLS [T2] >>> ***/
@ -139,43 +139,43 @@ typedef struct T2 {
UTF8String_t str;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} T2_t;
/*** <<< STAT-DEFS [T2] >>> ***/
static asn1_TYPE_member_t asn1_MBR_T2[] = {
static asn_TYPE_member_t asn_MBR_T2[] = {
{ ATF_NOFLAGS, 0, offsetof(struct T2, flag),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (1 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_BOOLEAN,
.type = (void *)&asn_DEF_BOOLEAN,
.memb_constraints = 0, /* Defer to actual type */
.name = "flag"
},
{ ATF_NOFLAGS, 0, offsetof(struct T2, str),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (12 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_UTF8String,
.type = (void *)&asn_DEF_UTF8String,
.memb_constraints = 0, /* Defer to actual type */
.name = "str"
},
};
static ber_tlv_tag_t asn1_DEF_T2_tags[] = {
static ber_tlv_tag_t asn_DEF_T2_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_T2_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_T2_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (1 << 2)), 0, 0, 0 }, /* flag at 20 */
{ (ASN_TAG_CLASS_UNIVERSAL | (12 << 2)), 1, 0, 0 }, /* str at 21 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_T2_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_T2_specs = {
sizeof(struct T2),
offsetof(struct T2, _ber_dec_ctx),
asn1_DEF_T2_tag2el,
offsetof(struct T2, _asn_ctx),
asn_DEF_T2_tag2el,
2, /* Count of tags in the map */
-1, /* Start extensions */
-1 /* Stop extensions */
};
asn1_TYPE_descriptor_t asn1_DEF_T2 = {
asn_TYPE_descriptor_t asn_DEF_T2 = {
"T2",
SEQUENCE_free,
SEQUENCE_print,
@ -185,14 +185,14 @@ asn1_TYPE_descriptor_t asn1_DEF_T2 = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T2_tags,
sizeof(asn1_DEF_T2_tags)
/sizeof(asn1_DEF_T2_tags[0]), /* 1 */
asn1_DEF_T2_tags, /* Same as above */
sizeof(asn1_DEF_T2_tags)
/sizeof(asn1_DEF_T2_tags[0]), /* 1 */
asn1_MBR_T2,
asn_DEF_T2_tags,
sizeof(asn_DEF_T2_tags)
/sizeof(asn_DEF_T2_tags[0]), /* 1 */
asn_DEF_T2_tags, /* Same as above */
sizeof(asn_DEF_T2_tags)
/sizeof(asn_DEF_T2_tags[0]), /* 1 */
asn_MBR_T2,
2, /* Elements count */
&asn1_DEF_T2_specs /* Additional specs */
&asn_DEF_T2_specs /* Additional specs */
};

View File

@ -9,7 +9,7 @@
/*** <<< DEPS [LogLine] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_LogLine;
extern asn_TYPE_descriptor_t asn_DEF_LogLine;
/*** <<< TYPE-DECLS [LogLine] >>> ***/
@ -20,7 +20,7 @@ typedef struct LogLine {
A_SEQUENCE_OF(VariablePartSet_t) list;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} varsets;
/*
* This type is extensible,
@ -28,13 +28,13 @@ typedef struct LogLine {
*/
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} LogLine_t;
/*** <<< CODE [LogLine] >>> ***/
static int
memb_varsets_1_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
memb_varsets_1_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
size_t size;
@ -65,25 +65,25 @@ memb_varsets_1_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
/*** <<< STAT-DEFS [LogLine] >>> ***/
static asn1_TYPE_member_t asn1_MBR_varsets[] = {
static asn_TYPE_member_t asn_MBR_varsets[] = {
{ ATF_NOFLAGS, 0, 0,
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_VariablePartSet,
.type = (void *)&asn_DEF_VariablePartSet,
.memb_constraints = 0, /* Defer to actual type */
.name = ""
},
};
static ber_tlv_tag_t asn1_DEF_varsets_tags[] = {
static ber_tlv_tag_t asn_DEF_varsets_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_SET_OF_specifics_t asn1_DEF_varsets_specs = {
static asn_SET_OF_specifics_t asn_DEF_varsets_specs = {
sizeof(struct varsets),
offsetof(struct varsets, _ber_dec_ctx),
offsetof(struct varsets, _asn_ctx),
0, /* XER encoding is XMLDelimitedItemList */
};
static /* Use -fall-defs-global to expose */
asn1_TYPE_descriptor_t asn1_DEF_varsets = {
asn_TYPE_descriptor_t asn_DEF_varsets = {
"varsets",
SEQUENCE_OF_free,
SEQUENCE_OF_print,
@ -93,49 +93,49 @@ asn1_TYPE_descriptor_t asn1_DEF_varsets = {
0, /* Not implemented yet */
SEQUENCE_OF_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_varsets_tags,
sizeof(asn1_DEF_varsets_tags)
/sizeof(asn1_DEF_varsets_tags[0]), /* 1 */
asn1_DEF_varsets_tags, /* Same as above */
sizeof(asn1_DEF_varsets_tags)
/sizeof(asn1_DEF_varsets_tags[0]), /* 1 */
asn1_MBR_varsets,
asn_DEF_varsets_tags,
sizeof(asn_DEF_varsets_tags)
/sizeof(asn_DEF_varsets_tags[0]), /* 1 */
asn_DEF_varsets_tags, /* Same as above */
sizeof(asn_DEF_varsets_tags)
/sizeof(asn_DEF_varsets_tags[0]), /* 1 */
asn_MBR_varsets,
1, /* Single element */
&asn1_DEF_varsets_specs /* Additional specs */
&asn_DEF_varsets_specs /* Additional specs */
};
static asn1_TYPE_member_t asn1_MBR_LogLine[] = {
static asn_TYPE_member_t asn_MBR_LogLine[] = {
{ ATF_NOFLAGS, 0, offsetof(struct LogLine, line_digest),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (22 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_IA5String,
.type = (void *)&asn_DEF_IA5String,
.memb_constraints = 0, /* Defer to actual type */
.name = "line-digest"
},
{ ATF_NOFLAGS, 0, offsetof(struct LogLine, varsets),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_varsets,
.type = (void *)&asn_DEF_varsets,
.memb_constraints = memb_varsets_1_constraint,
.name = "varsets"
},
};
static ber_tlv_tag_t asn1_DEF_LogLine_tags[] = {
static ber_tlv_tag_t asn_DEF_LogLine_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_LogLine_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_LogLine_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 1, 0, 0 }, /* varsets at 25 */
{ (ASN_TAG_CLASS_UNIVERSAL | (22 << 2)), 0, 0, 0 }, /* line-digest at 23 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_LogLine_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_LogLine_specs = {
sizeof(struct LogLine),
offsetof(struct LogLine, _ber_dec_ctx),
asn1_DEF_LogLine_tag2el,
offsetof(struct LogLine, _asn_ctx),
asn_DEF_LogLine_tag2el,
2, /* Count of tags in the map */
1, /* Start extensions */
3 /* Stop extensions */
};
asn1_TYPE_descriptor_t asn1_DEF_LogLine = {
asn_TYPE_descriptor_t asn_DEF_LogLine = {
"LogLine",
SEQUENCE_free,
SEQUENCE_print,
@ -145,15 +145,15 @@ asn1_TYPE_descriptor_t asn1_DEF_LogLine = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_LogLine_tags,
sizeof(asn1_DEF_LogLine_tags)
/sizeof(asn1_DEF_LogLine_tags[0]), /* 1 */
asn1_DEF_LogLine_tags, /* Same as above */
sizeof(asn1_DEF_LogLine_tags)
/sizeof(asn1_DEF_LogLine_tags[0]), /* 1 */
asn1_MBR_LogLine,
asn_DEF_LogLine_tags,
sizeof(asn_DEF_LogLine_tags)
/sizeof(asn_DEF_LogLine_tags[0]), /* 1 */
asn_DEF_LogLine_tags, /* Same as above */
sizeof(asn_DEF_LogLine_tags)
/sizeof(asn_DEF_LogLine_tags[0]), /* 1 */
asn_MBR_LogLine,
2, /* Elements count */
&asn1_DEF_LogLine_specs /* Additional specs */
&asn_DEF_LogLine_specs /* Additional specs */
};
@ -167,7 +167,7 @@ asn1_TYPE_descriptor_t asn1_DEF_LogLine = {
/*** <<< DEPS [VariablePartSet] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_VariablePartSet;
extern asn_TYPE_descriptor_t asn_DEF_VariablePartSet;
/*** <<< TYPE-DECLS [VariablePartSet] >>> ***/
@ -177,7 +177,7 @@ typedef struct VariablePartSet {
A_SEQUENCE_OF(VariablePart_t) list;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} vparts;
ActionItem_t resolution;
/*
@ -186,13 +186,13 @@ typedef struct VariablePartSet {
*/
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} VariablePartSet_t;
/*** <<< CODE [VariablePartSet] >>> ***/
static int
memb_vparts_2_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
memb_vparts_2_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
if(!sptr) {
@ -213,25 +213,25 @@ memb_vparts_2_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
/*** <<< STAT-DEFS [VariablePartSet] >>> ***/
static asn1_TYPE_member_t asn1_MBR_vparts[] = {
static asn_TYPE_member_t asn_MBR_vparts[] = {
{ ATF_NOFLAGS, 0, 0,
.tag = -1 /* Ambiguous tag (CHOICE?) */,
.tag_mode = 0,
.type = (void *)&asn1_DEF_VariablePart,
.type = (void *)&asn_DEF_VariablePart,
.memb_constraints = 0, /* Defer to actual type */
.name = ""
},
};
static ber_tlv_tag_t asn1_DEF_vparts_tags[] = {
static ber_tlv_tag_t asn_DEF_vparts_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_SET_OF_specifics_t asn1_DEF_vparts_specs = {
static asn_SET_OF_specifics_t asn_DEF_vparts_specs = {
sizeof(struct vparts),
offsetof(struct vparts, _ber_dec_ctx),
offsetof(struct vparts, _asn_ctx),
1, /* XER encoding is XMLValueList */
};
static /* Use -fall-defs-global to expose */
asn1_TYPE_descriptor_t asn1_DEF_vparts = {
asn_TYPE_descriptor_t asn_DEF_vparts = {
"vparts",
SEQUENCE_OF_free,
SEQUENCE_OF_print,
@ -241,49 +241,49 @@ asn1_TYPE_descriptor_t asn1_DEF_vparts = {
0, /* Not implemented yet */
SEQUENCE_OF_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_vparts_tags,
sizeof(asn1_DEF_vparts_tags)
/sizeof(asn1_DEF_vparts_tags[0]), /* 1 */
asn1_DEF_vparts_tags, /* Same as above */
sizeof(asn1_DEF_vparts_tags)
/sizeof(asn1_DEF_vparts_tags[0]), /* 1 */
asn1_MBR_vparts,
asn_DEF_vparts_tags,
sizeof(asn_DEF_vparts_tags)
/sizeof(asn_DEF_vparts_tags[0]), /* 1 */
asn_DEF_vparts_tags, /* Same as above */
sizeof(asn_DEF_vparts_tags)
/sizeof(asn_DEF_vparts_tags[0]), /* 1 */
asn_MBR_vparts,
1, /* Single element */
&asn1_DEF_vparts_specs /* Additional specs */
&asn_DEF_vparts_specs /* Additional specs */
};
static asn1_TYPE_member_t asn1_MBR_VariablePartSet[] = {
static asn_TYPE_member_t asn_MBR_VariablePartSet[] = {
{ ATF_NOFLAGS, 0, offsetof(struct VariablePartSet, vparts),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_vparts,
.type = (void *)&asn_DEF_vparts,
.memb_constraints = memb_vparts_2_constraint,
.name = "vparts"
},
{ ATF_NOFLAGS, 0, offsetof(struct VariablePartSet, resolution),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_ActionItem,
.type = (void *)&asn_DEF_ActionItem,
.memb_constraints = 0, /* Defer to actual type */
.name = "resolution"
},
};
static ber_tlv_tag_t asn1_DEF_VariablePartSet_tags[] = {
static ber_tlv_tag_t asn_DEF_VariablePartSet_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_VariablePartSet_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_VariablePartSet_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, 0, 1 }, /* vparts at 33 */
{ (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 1, -1, 0 }, /* resolution at 35 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_VariablePartSet_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_VariablePartSet_specs = {
sizeof(struct VariablePartSet),
offsetof(struct VariablePartSet, _ber_dec_ctx),
asn1_DEF_VariablePartSet_tag2el,
offsetof(struct VariablePartSet, _asn_ctx),
asn_DEF_VariablePartSet_tag2el,
2, /* Count of tags in the map */
1, /* Start extensions */
3 /* Stop extensions */
};
asn1_TYPE_descriptor_t asn1_DEF_VariablePartSet = {
asn_TYPE_descriptor_t asn_DEF_VariablePartSet = {
"VariablePartSet",
SEQUENCE_free,
SEQUENCE_print,
@ -293,15 +293,15 @@ asn1_TYPE_descriptor_t asn1_DEF_VariablePartSet = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_VariablePartSet_tags,
sizeof(asn1_DEF_VariablePartSet_tags)
/sizeof(asn1_DEF_VariablePartSet_tags[0]), /* 1 */
asn1_DEF_VariablePartSet_tags, /* Same as above */
sizeof(asn1_DEF_VariablePartSet_tags)
/sizeof(asn1_DEF_VariablePartSet_tags[0]), /* 1 */
asn1_MBR_VariablePartSet,
asn_DEF_VariablePartSet_tags,
sizeof(asn_DEF_VariablePartSet_tags)
/sizeof(asn_DEF_VariablePartSet_tags[0]), /* 1 */
asn_DEF_VariablePartSet_tags, /* Same as above */
sizeof(asn_DEF_VariablePartSet_tags)
/sizeof(asn_DEF_VariablePartSet_tags[0]), /* 1 */
asn_MBR_VariablePartSet,
2, /* Elements count */
&asn1_DEF_VariablePartSet_specs /* Additional specs */
&asn_DEF_VariablePartSet_specs /* Additional specs */
};
@ -321,7 +321,7 @@ typedef enum VariablePart_PR {
VariablePart_PR_vrange,
/* Extensions may appear below */
} VariablePart_PR;
extern asn1_TYPE_descriptor_t asn1_DEF_VariablePart;
extern asn_TYPE_descriptor_t asn_DEF_VariablePart;
/*** <<< TYPE-DECLS [VariablePart] >>> ***/
@ -333,7 +333,7 @@ typedef struct VariablePart {
A_SET_OF(VisibleString_t) list;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} vset;
struct vrange {
VisibleString_t from;
@ -344,7 +344,7 @@ typedef struct VariablePart {
*/
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} vrange;
/*
* This type is extensible,
@ -353,13 +353,13 @@ typedef struct VariablePart {
} choice;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} VariablePart_t;
/*** <<< CODE [VariablePart] >>> ***/
static int
memb_vset_3_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
memb_vset_3_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
size_t size;
@ -390,25 +390,25 @@ memb_vset_3_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
/*** <<< STAT-DEFS [VariablePart] >>> ***/
static asn1_TYPE_member_t asn1_MBR_vset[] = {
static asn_TYPE_member_t asn_MBR_vset[] = {
{ ATF_NOFLAGS, 0, 0,
.tag = (ASN_TAG_CLASS_UNIVERSAL | (26 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_VisibleString,
.type = (void *)&asn_DEF_VisibleString,
.memb_constraints = 0, /* Defer to actual type */
.name = ""
},
};
static ber_tlv_tag_t asn1_DEF_vset_tags[] = {
static ber_tlv_tag_t asn_DEF_vset_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
};
static asn1_SET_OF_specifics_t asn1_DEF_vset_specs = {
static asn_SET_OF_specifics_t asn_DEF_vset_specs = {
sizeof(struct vset),
offsetof(struct vset, _ber_dec_ctx),
offsetof(struct vset, _asn_ctx),
0, /* XER encoding is XMLDelimitedItemList */
};
static /* Use -fall-defs-global to expose */
asn1_TYPE_descriptor_t asn1_DEF_vset = {
asn_TYPE_descriptor_t asn_DEF_vset = {
"vset",
SET_OF_free,
SET_OF_print,
@ -418,50 +418,50 @@ asn1_TYPE_descriptor_t asn1_DEF_vset = {
0, /* Not implemented yet */
SET_OF_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_vset_tags,
sizeof(asn1_DEF_vset_tags)
/sizeof(asn1_DEF_vset_tags[0]), /* 1 */
asn1_DEF_vset_tags, /* Same as above */
sizeof(asn1_DEF_vset_tags)
/sizeof(asn1_DEF_vset_tags[0]), /* 1 */
asn1_MBR_vset,
asn_DEF_vset_tags,
sizeof(asn_DEF_vset_tags)
/sizeof(asn_DEF_vset_tags[0]), /* 1 */
asn_DEF_vset_tags, /* Same as above */
sizeof(asn_DEF_vset_tags)
/sizeof(asn_DEF_vset_tags[0]), /* 1 */
asn_MBR_vset,
1, /* Single element */
&asn1_DEF_vset_specs /* Additional specs */
&asn_DEF_vset_specs /* Additional specs */
};
static asn1_TYPE_member_t asn1_MBR_vrange[] = {
static asn_TYPE_member_t asn_MBR_vrange[] = {
{ ATF_NOFLAGS, 0, offsetof(struct vrange, from),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (26 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_VisibleString,
.type = (void *)&asn_DEF_VisibleString,
.memb_constraints = 0, /* Defer to actual type */
.name = "from"
},
{ ATF_NOFLAGS, 0, offsetof(struct vrange, to),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (26 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_VisibleString,
.type = (void *)&asn_DEF_VisibleString,
.memb_constraints = 0, /* Defer to actual type */
.name = "to"
},
};
static ber_tlv_tag_t asn1_DEF_vrange_tags[] = {
static ber_tlv_tag_t asn_DEF_vrange_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_vrange_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_vrange_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (26 << 2)), 0, 0, 1 }, /* from at 45 */
{ (ASN_TAG_CLASS_UNIVERSAL | (26 << 2)), 1, -1, 0 }, /* to at 46 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_vrange_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_vrange_specs = {
sizeof(struct vrange),
offsetof(struct vrange, _ber_dec_ctx),
asn1_DEF_vrange_tag2el,
offsetof(struct vrange, _asn_ctx),
asn_DEF_vrange_tag2el,
2, /* Count of tags in the map */
1, /* Start extensions */
3 /* Stop extensions */
};
static /* Use -fall-defs-global to expose */
asn1_TYPE_descriptor_t asn1_DEF_vrange = {
asn_TYPE_descriptor_t asn_DEF_vrange = {
"vrange",
SEQUENCE_free,
SEQUENCE_print,
@ -471,47 +471,47 @@ asn1_TYPE_descriptor_t asn1_DEF_vrange = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_vrange_tags,
sizeof(asn1_DEF_vrange_tags)
/sizeof(asn1_DEF_vrange_tags[0]), /* 1 */
asn1_DEF_vrange_tags, /* Same as above */
sizeof(asn1_DEF_vrange_tags)
/sizeof(asn1_DEF_vrange_tags[0]), /* 1 */
asn1_MBR_vrange,
asn_DEF_vrange_tags,
sizeof(asn_DEF_vrange_tags)
/sizeof(asn_DEF_vrange_tags[0]), /* 1 */
asn_DEF_vrange_tags, /* Same as above */
sizeof(asn_DEF_vrange_tags)
/sizeof(asn_DEF_vrange_tags[0]), /* 1 */
asn_MBR_vrange,
2, /* Elements count */
&asn1_DEF_vrange_specs /* Additional specs */
&asn_DEF_vrange_specs /* Additional specs */
};
static asn1_TYPE_member_t asn1_MBR_VariablePart[] = {
static asn_TYPE_member_t asn_MBR_VariablePart[] = {
{ ATF_NOFLAGS, 0, offsetof(struct VariablePart, choice.vset),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (17 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_vset,
.type = (void *)&asn_DEF_vset,
.memb_constraints = memb_vset_3_constraint,
.name = "vset"
},
{ ATF_NOFLAGS, 0, offsetof(struct VariablePart, choice.vrange),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_vrange,
.type = (void *)&asn_DEF_vrange,
.memb_constraints = 0, /* Defer to actual type */
.name = "vrange"
},
};
static asn1_TYPE_tag2member_t asn1_DEF_VariablePart_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_VariablePart_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 1, 0, 0 }, /* vrange at 45 */
{ (ASN_TAG_CLASS_UNIVERSAL | (17 << 2)), 0, 0, 0 }, /* vset at 42 */
};
static asn1_CHOICE_specifics_t asn1_DEF_VariablePart_specs = {
static asn_CHOICE_specifics_t asn_DEF_VariablePart_specs = {
sizeof(struct VariablePart),
offsetof(struct VariablePart, _ber_dec_ctx),
offsetof(struct VariablePart, _asn_ctx),
offsetof(struct VariablePart, present),
sizeof(((struct VariablePart *)0)->present),
asn1_DEF_VariablePart_tag2el,
asn_DEF_VariablePart_tag2el,
2, /* Count of tags in the map */
1 /* Whether extensible */
};
asn1_TYPE_descriptor_t asn1_DEF_VariablePart = {
asn_TYPE_descriptor_t asn_DEF_VariablePart = {
"VariablePart",
CHOICE_free,
CHOICE_print,
@ -525,9 +525,9 @@ asn1_TYPE_descriptor_t asn1_DEF_VariablePart = {
0, /* No effective tags (count) */
0, /* No tags (pointer) */
0, /* No tags (count) */
asn1_MBR_VariablePart,
asn_MBR_VariablePart,
2, /* Elements count */
&asn1_DEF_VariablePart_specs /* Additional specs */
&asn_DEF_VariablePart_specs /* Additional specs */
};
@ -550,7 +550,7 @@ typedef enum accept_as {
* Enumeration is extensible
*/
} accept_as_e;
extern asn1_TYPE_descriptor_t asn1_DEF_ActionItem;
extern asn_TYPE_descriptor_t asn_DEF_ActionItem;
/*** <<< TYPE-DECLS [ActionItem] >>> ***/
@ -563,7 +563,7 @@ typedef struct ActionItem {
A_SET_OF(VisibleString_t) list;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} email;
/*
* This type is extensible,
@ -571,7 +571,7 @@ typedef struct ActionItem {
*/
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} *notify;
/*
* This type is extensible,
@ -579,30 +579,30 @@ typedef struct ActionItem {
*/
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} ActionItem_t;
/*** <<< STAT-DEFS [ActionItem] >>> ***/
static asn1_TYPE_member_t asn1_MBR_email[] = {
static asn_TYPE_member_t asn_MBR_email[] = {
{ ATF_NOFLAGS, 0, 0,
.tag = (ASN_TAG_CLASS_UNIVERSAL | (26 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_VisibleString,
.type = (void *)&asn_DEF_VisibleString,
.memb_constraints = 0, /* Defer to actual type */
.name = ""
},
};
static ber_tlv_tag_t asn1_DEF_email_tags[] = {
static ber_tlv_tag_t asn_DEF_email_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
};
static asn1_SET_OF_specifics_t asn1_DEF_email_specs = {
static asn_SET_OF_specifics_t asn_DEF_email_specs = {
sizeof(struct email),
offsetof(struct email, _ber_dec_ctx),
offsetof(struct email, _asn_ctx),
0, /* XER encoding is XMLDelimitedItemList */
};
static /* Use -fall-defs-global to expose */
asn1_TYPE_descriptor_t asn1_DEF_email = {
asn_TYPE_descriptor_t asn_DEF_email = {
"email",
SET_OF_free,
SET_OF_print,
@ -612,50 +612,50 @@ asn1_TYPE_descriptor_t asn1_DEF_email = {
0, /* Not implemented yet */
SET_OF_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_email_tags,
sizeof(asn1_DEF_email_tags)
/sizeof(asn1_DEF_email_tags[0]), /* 1 */
asn1_DEF_email_tags, /* Same as above */
sizeof(asn1_DEF_email_tags)
/sizeof(asn1_DEF_email_tags[0]), /* 1 */
asn1_MBR_email,
asn_DEF_email_tags,
sizeof(asn_DEF_email_tags)
/sizeof(asn_DEF_email_tags[0]), /* 1 */
asn_DEF_email_tags, /* Same as above */
sizeof(asn_DEF_email_tags)
/sizeof(asn_DEF_email_tags[0]), /* 1 */
asn_MBR_email,
1, /* Single element */
&asn1_DEF_email_specs /* Additional specs */
&asn_DEF_email_specs /* Additional specs */
};
static asn1_TYPE_member_t asn1_MBR_notify[] = {
static asn_TYPE_member_t asn_MBR_notify[] = {
{ ATF_NOFLAGS, 0, offsetof(struct notify, critical),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (1 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_BOOLEAN,
.type = (void *)&asn_DEF_BOOLEAN,
.memb_constraints = 0, /* Defer to actual type */
.name = "critical"
},
{ ATF_NOFLAGS, 0, offsetof(struct notify, email),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (17 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_email,
.type = (void *)&asn_DEF_email,
.memb_constraints = 0, /* Defer to actual type */
.name = "email"
},
};
static ber_tlv_tag_t asn1_DEF_notify_tags[] = {
static ber_tlv_tag_t asn_DEF_notify_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_notify_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_notify_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (1 << 2)), 0, 0, 0 }, /* critical at 61 */
{ (ASN_TAG_CLASS_UNIVERSAL | (17 << 2)), 1, 0, 0 }, /* email at 62 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_notify_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_notify_specs = {
sizeof(struct notify),
offsetof(struct notify, _ber_dec_ctx),
asn1_DEF_notify_tag2el,
offsetof(struct notify, _asn_ctx),
asn_DEF_notify_tag2el,
2, /* Count of tags in the map */
1, /* Start extensions */
3 /* Stop extensions */
};
static /* Use -fall-defs-global to expose */
asn1_TYPE_descriptor_t asn1_DEF_notify = {
asn_TYPE_descriptor_t asn_DEF_notify = {
"notify",
SEQUENCE_free,
SEQUENCE_print,
@ -665,49 +665,49 @@ asn1_TYPE_descriptor_t asn1_DEF_notify = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_notify_tags,
sizeof(asn1_DEF_notify_tags)
/sizeof(asn1_DEF_notify_tags[0]), /* 1 */
asn1_DEF_notify_tags, /* Same as above */
sizeof(asn1_DEF_notify_tags)
/sizeof(asn1_DEF_notify_tags[0]), /* 1 */
asn1_MBR_notify,
asn_DEF_notify_tags,
sizeof(asn_DEF_notify_tags)
/sizeof(asn_DEF_notify_tags[0]), /* 1 */
asn_DEF_notify_tags, /* Same as above */
sizeof(asn_DEF_notify_tags)
/sizeof(asn_DEF_notify_tags[0]), /* 1 */
asn_MBR_notify,
2, /* Elements count */
&asn1_DEF_notify_specs /* Additional specs */
&asn_DEF_notify_specs /* Additional specs */
};
static asn1_TYPE_member_t asn1_MBR_ActionItem[] = {
static asn_TYPE_member_t asn_MBR_ActionItem[] = {
{ ATF_NOFLAGS, 0, offsetof(struct ActionItem, accept_as),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (10 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_ENUMERATED,
.type = (void *)&asn_DEF_ENUMERATED,
.memb_constraints = 0, /* Defer to actual type */
.name = "accept-as"
},
{ ATF_POINTER, 1, offsetof(struct ActionItem, notify),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_notify,
.type = (void *)&asn_DEF_notify,
.memb_constraints = 0, /* Defer to actual type */
.name = "notify"
},
};
static ber_tlv_tag_t asn1_DEF_ActionItem_tags[] = {
static ber_tlv_tag_t asn_DEF_ActionItem_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_ActionItem_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_ActionItem_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (10 << 2)), 0, 0, 0 }, /* accept-as at 55 */
{ (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 1, 0, 0 }, /* notify at 61 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_ActionItem_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_ActionItem_specs = {
sizeof(struct ActionItem),
offsetof(struct ActionItem, _ber_dec_ctx),
asn1_DEF_ActionItem_tag2el,
offsetof(struct ActionItem, _asn_ctx),
asn_DEF_ActionItem_tag2el,
2, /* Count of tags in the map */
1, /* Start extensions */
3 /* Stop extensions */
};
asn1_TYPE_descriptor_t asn1_DEF_ActionItem = {
asn_TYPE_descriptor_t asn_DEF_ActionItem = {
"ActionItem",
SEQUENCE_free,
SEQUENCE_print,
@ -717,14 +717,14 @@ asn1_TYPE_descriptor_t asn1_DEF_ActionItem = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_ActionItem_tags,
sizeof(asn1_DEF_ActionItem_tags)
/sizeof(asn1_DEF_ActionItem_tags[0]), /* 1 */
asn1_DEF_ActionItem_tags, /* Same as above */
sizeof(asn1_DEF_ActionItem_tags)
/sizeof(asn1_DEF_ActionItem_tags[0]), /* 1 */
asn1_MBR_ActionItem,
asn_DEF_ActionItem_tags,
sizeof(asn_DEF_ActionItem_tags)
/sizeof(asn_DEF_ActionItem_tags[0]), /* 1 */
asn_DEF_ActionItem_tags, /* Same as above */
sizeof(asn_DEF_ActionItem_tags)
/sizeof(asn_DEF_ActionItem_tags[0]), /* 1 */
asn_MBR_ActionItem,
2, /* Elements count */
&asn1_DEF_ActionItem_specs /* Additional specs */
&asn_DEF_ActionItem_specs /* Additional specs */
};

View File

@ -24,7 +24,7 @@ typedef enum h_PR {
h_PR_i,
h_PR_j,
} h_PR;
extern asn1_TYPE_descriptor_t asn1_DEF_T;
extern asn_TYPE_descriptor_t asn_DEF_T;
/*** <<< TYPE-DECLS [T] >>> ***/
@ -44,7 +44,7 @@ typedef struct T {
} choice;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} e;
struct h {
h_PR present;
@ -54,51 +54,51 @@ typedef struct T {
} choice;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} h;
} choice;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} b;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} T_t;
/*** <<< STAT-DEFS [T] >>> ***/
static asn1_TYPE_member_t asn1_MBR_e[] = {
static asn_TYPE_member_t asn_MBR_e[] = {
{ ATF_NOFLAGS, 0, offsetof(struct e, choice.f),
.tag = (ASN_TAG_CLASS_PRIVATE | (7 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_NULL,
.type = (void *)&asn_DEF_NULL,
.memb_constraints = 0, /* Defer to actual type */
.name = "f"
},
{ ATF_NOFLAGS, 0, offsetof(struct e, choice.g),
.tag = (ASN_TAG_CLASS_PRIVATE | (8 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_NULL,
.type = (void *)&asn_DEF_NULL,
.memb_constraints = 0, /* Defer to actual type */
.name = "g"
},
};
static asn1_TYPE_tag2member_t asn1_DEF_e_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_e_tag2el[] = {
{ (ASN_TAG_CLASS_PRIVATE | (7 << 2)), 0, 0, 0 }, /* f at 20 */
{ (ASN_TAG_CLASS_PRIVATE | (8 << 2)), 1, 0, 0 }, /* g at 21 */
};
static asn1_CHOICE_specifics_t asn1_DEF_e_specs = {
static asn_CHOICE_specifics_t asn_DEF_e_specs = {
sizeof(struct e),
offsetof(struct e, _ber_dec_ctx),
offsetof(struct e, _asn_ctx),
offsetof(struct e, present),
sizeof(((struct e *)0)->present),
asn1_DEF_e_tag2el,
asn_DEF_e_tag2el,
2, /* Count of tags in the map */
0 /* Whether extensible */
};
static /* Use -fall-defs-global to expose */
asn1_TYPE_descriptor_t asn1_DEF_e = {
asn_TYPE_descriptor_t asn_DEF_e = {
"e",
CHOICE_free,
CHOICE_print,
@ -112,42 +112,42 @@ asn1_TYPE_descriptor_t asn1_DEF_e = {
0, /* No effective tags (count) */
0, /* No tags (pointer) */
0, /* No tags (count) */
asn1_MBR_e,
asn_MBR_e,
2, /* Elements count */
&asn1_DEF_e_specs /* Additional specs */
&asn_DEF_e_specs /* Additional specs */
};
static asn1_TYPE_member_t asn1_MBR_h[] = {
static asn_TYPE_member_t asn_MBR_h[] = {
{ ATF_NOFLAGS, 0, offsetof(struct h, choice.i),
.tag = (ASN_TAG_CLASS_PRIVATE | (1 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_NULL,
.type = (void *)&asn_DEF_NULL,
.memb_constraints = 0, /* Defer to actual type */
.name = "i"
},
{ ATF_NOFLAGS, 0, offsetof(struct h, choice.j),
.tag = (ASN_TAG_CLASS_PRIVATE | (2 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_NULL,
.type = (void *)&asn_DEF_NULL,
.memb_constraints = 0, /* Defer to actual type */
.name = "j"
},
};
static asn1_TYPE_tag2member_t asn1_DEF_h_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_h_tag2el[] = {
{ (ASN_TAG_CLASS_PRIVATE | (1 << 2)), 0, 0, 0 }, /* i at 24 */
{ (ASN_TAG_CLASS_PRIVATE | (2 << 2)), 1, 0, 0 }, /* j at 25 */
};
static asn1_CHOICE_specifics_t asn1_DEF_h_specs = {
static asn_CHOICE_specifics_t asn_DEF_h_specs = {
sizeof(struct h),
offsetof(struct h, _ber_dec_ctx),
offsetof(struct h, _asn_ctx),
offsetof(struct h, present),
sizeof(((struct h *)0)->present),
asn1_DEF_h_tag2el,
asn_DEF_h_tag2el,
2, /* Count of tags in the map */
0 /* Whether extensible */
};
static /* Use -fall-defs-global to expose */
asn1_TYPE_descriptor_t asn1_DEF_h = {
asn_TYPE_descriptor_t asn_DEF_h = {
"h",
CHOICE_free,
CHOICE_print,
@ -161,59 +161,59 @@ asn1_TYPE_descriptor_t asn1_DEF_h = {
0, /* No effective tags (count) */
0, /* No tags (pointer) */
0, /* No tags (count) */
asn1_MBR_h,
asn_MBR_h,
2, /* Elements count */
&asn1_DEF_h_specs /* Additional specs */
&asn_DEF_h_specs /* Additional specs */
};
static asn1_TYPE_member_t asn1_MBR_b[] = {
static asn_TYPE_member_t asn_MBR_b[] = {
{ ATF_NOFLAGS, 0, offsetof(struct b, choice.c),
.tag = (ASN_TAG_CLASS_PRIVATE | (5 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_NULL,
.type = (void *)&asn_DEF_NULL,
.memb_constraints = 0, /* Defer to actual type */
.name = "c"
},
{ ATF_NOFLAGS, 0, offsetof(struct b, choice.d),
.tag = (ASN_TAG_CLASS_PRIVATE | (6 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_NULL,
.type = (void *)&asn_DEF_NULL,
.memb_constraints = 0, /* Defer to actual type */
.name = "d"
},
{ ATF_NOFLAGS, 0, offsetof(struct b, choice.e),
.tag = -1 /* Ambiguous tag (CHOICE?) */,
.tag_mode = 0,
.type = (void *)&asn1_DEF_e,
.type = (void *)&asn_DEF_e,
.memb_constraints = 0, /* Defer to actual type */
.name = "e"
},
{ ATF_NOFLAGS, 0, offsetof(struct b, choice.h),
.tag = (ASN_TAG_CLASS_PRIVATE | (9 << 2)),
.tag_mode = +1, /* EXPLICIT tag at current level */
.type = (void *)&asn1_DEF_h,
.type = (void *)&asn_DEF_h,
.memb_constraints = 0, /* Defer to actual type */
.name = "h"
},
};
static asn1_TYPE_tag2member_t asn1_DEF_b_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_b_tag2el[] = {
{ (ASN_TAG_CLASS_PRIVATE | (5 << 2)), 0, 0, 0 }, /* c at 17 */
{ (ASN_TAG_CLASS_PRIVATE | (6 << 2)), 1, 0, 0 }, /* d at 18 */
{ (ASN_TAG_CLASS_PRIVATE | (7 << 2)), 2, 0, 0 }, /* f at 20 */
{ (ASN_TAG_CLASS_PRIVATE | (8 << 2)), 2, 0, 0 }, /* g at 21 */
{ (ASN_TAG_CLASS_PRIVATE | (9 << 2)), 3, 0, 0 }, /* h at 24 */
};
static asn1_CHOICE_specifics_t asn1_DEF_b_specs = {
static asn_CHOICE_specifics_t asn_DEF_b_specs = {
sizeof(struct b),
offsetof(struct b, _ber_dec_ctx),
offsetof(struct b, _asn_ctx),
offsetof(struct b, present),
sizeof(((struct b *)0)->present),
asn1_DEF_b_tag2el,
asn_DEF_b_tag2el,
5, /* Count of tags in the map */
0 /* Whether extensible */
};
static /* Use -fall-defs-global to expose */
asn1_TYPE_descriptor_t asn1_DEF_b = {
asn_TYPE_descriptor_t asn_DEF_b = {
"b",
CHOICE_free,
CHOICE_print,
@ -227,32 +227,32 @@ asn1_TYPE_descriptor_t asn1_DEF_b = {
0, /* No effective tags (count) */
0, /* No tags (pointer) */
0, /* No tags (count) */
asn1_MBR_b,
asn_MBR_b,
4, /* Elements count */
&asn1_DEF_b_specs /* Additional specs */
&asn_DEF_b_specs /* Additional specs */
};
static asn1_TYPE_member_t asn1_MBR_T[] = {
static asn_TYPE_member_t asn_MBR_T[] = {
{ ATF_NOFLAGS, 0, offsetof(struct T, a),
.tag = (ASN_TAG_CLASS_PRIVATE | (2 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_NULL,
.type = (void *)&asn_DEF_NULL,
.memb_constraints = 0, /* Defer to actual type */
.name = "a"
},
{ ATF_NOFLAGS, 0, offsetof(struct T, b),
.tag = -1 /* Ambiguous tag (CHOICE?) */,
.tag_mode = 0,
.type = (void *)&asn1_DEF_b,
.type = (void *)&asn_DEF_b,
.memb_constraints = 0, /* Defer to actual type */
.name = "b"
},
};
static ber_tlv_tag_t asn1_DEF_T_tags[] = {
static ber_tlv_tag_t asn_DEF_T_tags[] = {
(ASN_TAG_CLASS_PRIVATE | (1 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_T_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_T_tag2el[] = {
{ (ASN_TAG_CLASS_PRIVATE | (2 << 2)), 0, 0, 0 }, /* a at 15 */
{ (ASN_TAG_CLASS_PRIVATE | (5 << 2)), 1, 0, 0 }, /* c at 17 */
{ (ASN_TAG_CLASS_PRIVATE | (6 << 2)), 1, 0, 0 }, /* d at 18 */
@ -260,15 +260,15 @@ static asn1_TYPE_tag2member_t asn1_DEF_T_tag2el[] = {
{ (ASN_TAG_CLASS_PRIVATE | (8 << 2)), 1, 0, 0 }, /* g at 21 */
{ (ASN_TAG_CLASS_PRIVATE | (9 << 2)), 1, 0, 0 }, /* h at 24 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_T_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_T_specs = {
sizeof(struct T),
offsetof(struct T, _ber_dec_ctx),
asn1_DEF_T_tag2el,
offsetof(struct T, _asn_ctx),
asn_DEF_T_tag2el,
6, /* Count of tags in the map */
-1, /* Start extensions */
-1 /* Stop extensions */
};
asn1_TYPE_descriptor_t asn1_DEF_T = {
asn_TYPE_descriptor_t asn_DEF_T = {
"T",
SEQUENCE_free,
SEQUENCE_print,
@ -278,14 +278,14 @@ asn1_TYPE_descriptor_t asn1_DEF_T = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T_tags,
sizeof(asn1_DEF_T_tags)
/sizeof(asn1_DEF_T_tags[0]) - 1, /* 1 */
asn1_DEF_T_tags, /* Same as above */
sizeof(asn1_DEF_T_tags)
/sizeof(asn1_DEF_T_tags[0]), /* 2 */
asn1_MBR_T,
asn_DEF_T_tags,
sizeof(asn_DEF_T_tags)
/sizeof(asn_DEF_T_tags[0]) - 1, /* 1 */
asn_DEF_T_tags, /* Same as above */
sizeof(asn_DEF_T_tags)
/sizeof(asn_DEF_T_tags[0]), /* 2 */
asn_MBR_T,
2, /* Elements count */
&asn1_DEF_T_specs /* Additional specs */
&asn_DEF_T_specs /* Additional specs */
};

View File

@ -11,7 +11,7 @@ typedef OCTET_STRING_t PrimitiveType_t;
/*** <<< FUNC-DECLS [PrimitiveType] >>> ***/
/* This type is equivalent to OCTET_STRING */
#define asn1_DEF_PrimitiveType asn1_DEF_OCTET_STRING
#define asn_DEF_PrimitiveType asn_DEF_OCTET_STRING
/*** <<< CODE [PrimitiveType] >>> ***/
@ -25,7 +25,7 @@ typedef OCTET_STRING_t PrimitiveType_t;
/*** <<< DEPS [ConstructedType] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_ConstructedType;
extern asn_TYPE_descriptor_t asn_DEF_ConstructedType;
/*** <<< TYPE-DECLS [ConstructedType] >>> ***/
@ -34,35 +34,35 @@ typedef struct ConstructedType {
PrimitiveType_t field;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} ConstructedType_t;
/*** <<< STAT-DEFS [ConstructedType] >>> ***/
static asn1_TYPE_member_t asn1_MBR_ConstructedType[] = {
static asn_TYPE_member_t asn_MBR_ConstructedType[] = {
{ ATF_NOFLAGS, 0, offsetof(struct ConstructedType, field),
.tag = (ASN_TAG_CLASS_CONTEXT | (5 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_PrimitiveType,
.type = (void *)&asn_DEF_PrimitiveType,
.memb_constraints = 0, /* Defer to actual type */
.name = "field"
},
};
static ber_tlv_tag_t asn1_DEF_ConstructedType_tags[] = {
static ber_tlv_tag_t asn_DEF_ConstructedType_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_ConstructedType_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_ConstructedType_tag2el[] = {
{ (ASN_TAG_CLASS_CONTEXT | (5 << 2)), 0, 0, 0 }, /* field at 18 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_ConstructedType_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_ConstructedType_specs = {
sizeof(struct ConstructedType),
offsetof(struct ConstructedType, _ber_dec_ctx),
asn1_DEF_ConstructedType_tag2el,
offsetof(struct ConstructedType, _asn_ctx),
asn_DEF_ConstructedType_tag2el,
1, /* Count of tags in the map */
-1, /* Start extensions */
-1 /* Stop extensions */
};
asn1_TYPE_descriptor_t asn1_DEF_ConstructedType = {
asn_TYPE_descriptor_t asn_DEF_ConstructedType = {
"ConstructedType",
SEQUENCE_free,
SEQUENCE_print,
@ -72,15 +72,15 @@ asn1_TYPE_descriptor_t asn1_DEF_ConstructedType = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_ConstructedType_tags,
sizeof(asn1_DEF_ConstructedType_tags)
/sizeof(asn1_DEF_ConstructedType_tags[0]), /* 1 */
asn1_DEF_ConstructedType_tags, /* Same as above */
sizeof(asn1_DEF_ConstructedType_tags)
/sizeof(asn1_DEF_ConstructedType_tags[0]), /* 1 */
asn1_MBR_ConstructedType,
asn_DEF_ConstructedType_tags,
sizeof(asn_DEF_ConstructedType_tags)
/sizeof(asn_DEF_ConstructedType_tags[0]), /* 1 */
asn_DEF_ConstructedType_tags, /* Same as above */
sizeof(asn_DEF_ConstructedType_tags)
/sizeof(asn_DEF_ConstructedType_tags[0]), /* 1 */
asn_MBR_ConstructedType,
1, /* Elements count */
&asn1_DEF_ConstructedType_specs /* Additional specs */
&asn_DEF_ConstructedType_specs /* Additional specs */
};
@ -95,7 +95,7 @@ typedef ConstructedType_t T_t;
/*** <<< FUNC-DECLS [T] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T;
extern asn_TYPE_descriptor_t asn_DEF_T;
asn_struct_free_f T_free;
asn_struct_print_f T_print;
asn_constr_check_f T_constraint;
@ -106,10 +106,10 @@ xer_type_encoder_f T_encode_xer;
/*** <<< CODE [T] >>> ***/
int
T_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
T_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
/* Replace with underlying type checker */
td->check_constraints = asn1_DEF_ConstructedType.check_constraints;
td->check_constraints = asn_DEF_ConstructedType.check_constraints;
return td->check_constraints(td, sptr, app_errlog, app_key);
}
@ -118,41 +118,41 @@ T_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
* so here we adjust the DEF accordingly.
*/
static void
T_inherit_TYPE_descriptor(asn1_TYPE_descriptor_t *td) {
td->free_struct = asn1_DEF_ConstructedType.free_struct;
td->print_struct = asn1_DEF_ConstructedType.print_struct;
td->ber_decoder = asn1_DEF_ConstructedType.ber_decoder;
td->der_encoder = asn1_DEF_ConstructedType.der_encoder;
td->xer_decoder = asn1_DEF_ConstructedType.xer_decoder;
td->xer_encoder = asn1_DEF_ConstructedType.xer_encoder;
td->elements = asn1_DEF_ConstructedType.elements;
td->elements_count = asn1_DEF_ConstructedType.elements_count;
td->specifics = asn1_DEF_ConstructedType.specifics;
T_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
td->free_struct = asn_DEF_ConstructedType.free_struct;
td->print_struct = asn_DEF_ConstructedType.print_struct;
td->ber_decoder = asn_DEF_ConstructedType.ber_decoder;
td->der_encoder = asn_DEF_ConstructedType.der_encoder;
td->xer_decoder = asn_DEF_ConstructedType.xer_decoder;
td->xer_encoder = asn_DEF_ConstructedType.xer_encoder;
td->elements = asn_DEF_ConstructedType.elements;
td->elements_count = asn_DEF_ConstructedType.elements_count;
td->specifics = asn_DEF_ConstructedType.specifics;
}
void
T_free(asn1_TYPE_descriptor_t *td,
T_free(asn_TYPE_descriptor_t *td,
void *struct_ptr, int contents_only) {
T_inherit_TYPE_descriptor(td);
td->free_struct(td, struct_ptr, contents_only);
}
int
T_print(asn1_TYPE_descriptor_t *td, const void *struct_ptr,
T_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
T_inherit_TYPE_descriptor(td);
return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
}
ber_dec_rval_t
T_decode_ber(asn1_TYPE_descriptor_t *td,
T_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
void **structure, void *bufptr, size_t size, int tag_mode) {
T_inherit_TYPE_descriptor(td);
return td->ber_decoder(td, structure, bufptr, size, tag_mode);
return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
}
asn_enc_rval_t
T_encode_der(asn1_TYPE_descriptor_t *td,
T_encode_der(asn_TYPE_descriptor_t *td,
void *structure, int tag_mode, ber_tlv_tag_t tag,
asn_app_consume_bytes_f *cb, void *app_key) {
T_inherit_TYPE_descriptor(td);
@ -160,7 +160,7 @@ T_encode_der(asn1_TYPE_descriptor_t *td,
}
asn_enc_rval_t
T_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
T_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
int ilevel, enum xer_encoder_flags_e flags,
asn_app_consume_bytes_f *cb, void *app_key) {
T_inherit_TYPE_descriptor(td);
@ -170,11 +170,11 @@ T_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
/*** <<< STAT-DEFS [T] >>> ***/
static ber_tlv_tag_t asn1_DEF_T_tags[] = {
static ber_tlv_tag_t asn_DEF_T_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (3 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
asn1_TYPE_descriptor_t asn1_DEF_T = {
asn_TYPE_descriptor_t asn_DEF_T = {
"T",
T_free,
T_print,
@ -184,12 +184,12 @@ asn1_TYPE_descriptor_t asn1_DEF_T = {
0, /* Not implemented yet */
T_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T_tags,
sizeof(asn1_DEF_T_tags)
/sizeof(asn1_DEF_T_tags[0]) - 1, /* 1 */
asn1_DEF_T_tags, /* Same as above */
sizeof(asn1_DEF_T_tags)
/sizeof(asn1_DEF_T_tags[0]), /* 2 */
asn_DEF_T_tags,
sizeof(asn_DEF_T_tags)
/sizeof(asn_DEF_T_tags[0]) - 1, /* 1 */
asn_DEF_T_tags, /* Same as above */
sizeof(asn_DEF_T_tags)
/sizeof(asn_DEF_T_tags[0]), /* 2 */
0, 0, /* Defined elsewhere */
0 /* No specifics */
};

View File

@ -13,7 +13,7 @@
typedef enum T1_PR {
T1_PR_i, /* Member i is present */
} T1_PR;
extern asn1_TYPE_descriptor_t asn1_DEF_T1;
extern asn_TYPE_descriptor_t asn_DEF_T1;
/*** <<< TYPE-DECLS [T1] >>> ***/
@ -30,39 +30,39 @@ typedef struct T1 {
[((1+(8*sizeof(unsigned int))-1)/(8*sizeof(unsigned int)))];
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} T1_t;
/*** <<< STAT-DEFS [T1] >>> ***/
static asn1_TYPE_member_t asn1_MBR_T1[] = {
static asn_TYPE_member_t asn_MBR_T1[] = {
{ ATF_NOFLAGS, 0, offsetof(struct T1, i),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_INTEGER,
.type = (void *)&asn_DEF_INTEGER,
.memb_constraints = 0, /* Defer to actual type */
.name = "i"
},
};
static ber_tlv_tag_t asn1_DEF_T1_tags[] = {
static ber_tlv_tag_t asn_DEF_T1_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_T1_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_T1_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, 0, 0 }, /* i at 14 */
};
static uint8_t asn1_DEF_T1_mmap[(1 + (8 * sizeof(unsigned int)) - 1) / 8] = {
static uint8_t asn_DEF_T1_mmap[(1 + (8 * sizeof(unsigned int)) - 1) / 8] = {
(1 << 7)
};
static asn1_SET_specifics_t asn1_DEF_T1_specs = {
static asn_SET_specifics_t asn_DEF_T1_specs = {
sizeof(struct T1),
offsetof(struct T1, _ber_dec_ctx),
offsetof(struct T1, _asn_ctx),
offsetof(struct T1, _presence_map),
asn1_DEF_T1_tag2el,
asn_DEF_T1_tag2el,
1, /* Count of tags in the map */
1, /* Whether extensible */
(unsigned int *)asn1_DEF_T1_mmap /* Mandatory elements map */
(unsigned int *)asn_DEF_T1_mmap /* Mandatory elements map */
};
asn1_TYPE_descriptor_t asn1_DEF_T1 = {
asn_TYPE_descriptor_t asn_DEF_T1 = {
"T1",
SET_free,
SET_print,
@ -72,15 +72,15 @@ asn1_TYPE_descriptor_t asn1_DEF_T1 = {
0, /* Not implemented yet */
SET_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T1_tags,
sizeof(asn1_DEF_T1_tags)
/sizeof(asn1_DEF_T1_tags[0]), /* 1 */
asn1_DEF_T1_tags, /* Same as above */
sizeof(asn1_DEF_T1_tags)
/sizeof(asn1_DEF_T1_tags[0]), /* 1 */
asn1_MBR_T1,
asn_DEF_T1_tags,
sizeof(asn_DEF_T1_tags)
/sizeof(asn_DEF_T1_tags[0]), /* 1 */
asn_DEF_T1_tags, /* Same as above */
sizeof(asn_DEF_T1_tags)
/sizeof(asn_DEF_T1_tags[0]), /* 1 */
asn_MBR_T1,
1, /* Elements count */
&asn1_DEF_T1_specs /* Additional specs */
&asn_DEF_T1_specs /* Additional specs */
};
@ -98,7 +98,7 @@ asn1_TYPE_descriptor_t asn1_DEF_T1 = {
typedef enum T2_PR {
T2_PR_i, /* Member i is present */
} T2_PR;
extern asn1_TYPE_descriptor_t asn1_DEF_T2;
extern asn_TYPE_descriptor_t asn_DEF_T2;
/*** <<< TYPE-DECLS [T2] >>> ***/
@ -115,39 +115,39 @@ typedef struct T2 {
[((1+(8*sizeof(unsigned int))-1)/(8*sizeof(unsigned int)))];
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} T2_t;
/*** <<< STAT-DEFS [T2] >>> ***/
static asn1_TYPE_member_t asn1_MBR_T2[] = {
static asn_TYPE_member_t asn_MBR_T2[] = {
{ ATF_NOFLAGS, 0, offsetof(struct T2, i),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_INTEGER,
.type = (void *)&asn_DEF_INTEGER,
.memb_constraints = 0, /* Defer to actual type */
.name = "i"
},
};
static ber_tlv_tag_t asn1_DEF_T2_tags[] = {
static ber_tlv_tag_t asn_DEF_T2_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_T2_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_T2_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, 0, 0 }, /* i at 15 */
};
static uint8_t asn1_DEF_T2_mmap[(1 + (8 * sizeof(unsigned int)) - 1) / 8] = {
static uint8_t asn_DEF_T2_mmap[(1 + (8 * sizeof(unsigned int)) - 1) / 8] = {
(1 << 7)
};
static asn1_SET_specifics_t asn1_DEF_T2_specs = {
static asn_SET_specifics_t asn_DEF_T2_specs = {
sizeof(struct T2),
offsetof(struct T2, _ber_dec_ctx),
offsetof(struct T2, _asn_ctx),
offsetof(struct T2, _presence_map),
asn1_DEF_T2_tag2el,
asn_DEF_T2_tag2el,
1, /* Count of tags in the map */
1, /* Whether extensible */
(unsigned int *)asn1_DEF_T2_mmap /* Mandatory elements map */
(unsigned int *)asn_DEF_T2_mmap /* Mandatory elements map */
};
asn1_TYPE_descriptor_t asn1_DEF_T2 = {
asn_TYPE_descriptor_t asn_DEF_T2 = {
"T2",
SET_free,
SET_print,
@ -157,15 +157,15 @@ asn1_TYPE_descriptor_t asn1_DEF_T2 = {
0, /* Not implemented yet */
SET_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T2_tags,
sizeof(asn1_DEF_T2_tags)
/sizeof(asn1_DEF_T2_tags[0]), /* 1 */
asn1_DEF_T2_tags, /* Same as above */
sizeof(asn1_DEF_T2_tags)
/sizeof(asn1_DEF_T2_tags[0]), /* 1 */
asn1_MBR_T2,
asn_DEF_T2_tags,
sizeof(asn_DEF_T2_tags)
/sizeof(asn_DEF_T2_tags[0]), /* 1 */
asn_DEF_T2_tags, /* Same as above */
sizeof(asn_DEF_T2_tags)
/sizeof(asn_DEF_T2_tags[0]), /* 1 */
asn_MBR_T2,
1, /* Elements count */
&asn1_DEF_T2_specs /* Additional specs */
&asn_DEF_T2_specs /* Additional specs */
};
@ -181,7 +181,7 @@ typedef enum T3_PR {
T3_PR_i,
/* Extensions may appear below */
} T3_PR;
extern asn1_TYPE_descriptor_t asn1_DEF_T3;
extern asn_TYPE_descriptor_t asn_DEF_T3;
/*** <<< TYPE-DECLS [T3] >>> ***/
@ -197,33 +197,33 @@ typedef struct T3 {
} choice;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} T3_t;
/*** <<< STAT-DEFS [T3] >>> ***/
static asn1_TYPE_member_t asn1_MBR_T3[] = {
static asn_TYPE_member_t asn_MBR_T3[] = {
{ ATF_NOFLAGS, 0, offsetof(struct T3, choice.i),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_INTEGER,
.type = (void *)&asn_DEF_INTEGER,
.memb_constraints = 0, /* Defer to actual type */
.name = "i"
},
};
static asn1_TYPE_tag2member_t asn1_DEF_T3_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_T3_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, 0, 0 }, /* i at 16 */
};
static asn1_CHOICE_specifics_t asn1_DEF_T3_specs = {
static asn_CHOICE_specifics_t asn_DEF_T3_specs = {
sizeof(struct T3),
offsetof(struct T3, _ber_dec_ctx),
offsetof(struct T3, _asn_ctx),
offsetof(struct T3, present),
sizeof(((struct T3 *)0)->present),
asn1_DEF_T3_tag2el,
asn_DEF_T3_tag2el,
1, /* Count of tags in the map */
1 /* Whether extensible */
};
asn1_TYPE_descriptor_t asn1_DEF_T3 = {
asn_TYPE_descriptor_t asn_DEF_T3 = {
"T3",
CHOICE_free,
CHOICE_print,
@ -237,9 +237,9 @@ asn1_TYPE_descriptor_t asn1_DEF_T3 = {
0, /* No effective tags (count) */
0, /* No tags (pointer) */
0, /* No tags (count) */
asn1_MBR_T3,
asn_MBR_T3,
1, /* Elements count */
&asn1_DEF_T3_specs /* Additional specs */
&asn_DEF_T3_specs /* Additional specs */
};
@ -255,7 +255,7 @@ typedef enum T4_PR {
T4_PR_i,
/* Extensions may appear below */
} T4_PR;
extern asn1_TYPE_descriptor_t asn1_DEF_T4;
extern asn_TYPE_descriptor_t asn_DEF_T4;
/*** <<< TYPE-DECLS [T4] >>> ***/
@ -271,33 +271,33 @@ typedef struct T4 {
} choice;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} T4_t;
/*** <<< STAT-DEFS [T4] >>> ***/
static asn1_TYPE_member_t asn1_MBR_T4[] = {
static asn_TYPE_member_t asn_MBR_T4[] = {
{ ATF_NOFLAGS, 0, offsetof(struct T4, choice.i),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_INTEGER,
.type = (void *)&asn_DEF_INTEGER,
.memb_constraints = 0, /* Defer to actual type */
.name = "i"
},
};
static asn1_TYPE_tag2member_t asn1_DEF_T4_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_T4_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, 0, 0 }, /* i at 17 */
};
static asn1_CHOICE_specifics_t asn1_DEF_T4_specs = {
static asn_CHOICE_specifics_t asn_DEF_T4_specs = {
sizeof(struct T4),
offsetof(struct T4, _ber_dec_ctx),
offsetof(struct T4, _asn_ctx),
offsetof(struct T4, present),
sizeof(((struct T4 *)0)->present),
asn1_DEF_T4_tag2el,
asn_DEF_T4_tag2el,
1, /* Count of tags in the map */
1 /* Whether extensible */
};
asn1_TYPE_descriptor_t asn1_DEF_T4 = {
asn_TYPE_descriptor_t asn_DEF_T4 = {
"T4",
CHOICE_free,
CHOICE_print,
@ -311,8 +311,8 @@ asn1_TYPE_descriptor_t asn1_DEF_T4 = {
0, /* No effective tags (count) */
0, /* No tags (pointer) */
0, /* No tags (count) */
asn1_MBR_T4,
asn_MBR_T4,
1, /* Elements count */
&asn1_DEF_T4_specs /* Additional specs */
&asn_DEF_T4_specs /* Additional specs */
};

File diff suppressed because it is too large Load Diff

View File

@ -7,7 +7,7 @@
/*** <<< DEPS [T1] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T1;
extern asn_TYPE_descriptor_t asn_DEF_T1;
/*** <<< TYPE-DECLS [T1] >>> ***/
@ -17,42 +17,42 @@ typedef struct T1 {
ANY_t any;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} T1_t;
/*** <<< STAT-DEFS [T1] >>> ***/
static asn1_TYPE_member_t asn1_MBR_T1[] = {
static asn_TYPE_member_t asn_MBR_T1[] = {
{ ATF_NOFLAGS, 0, offsetof(struct T1, i),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_INTEGER,
.type = (void *)&asn_DEF_INTEGER,
.memb_constraints = 0, /* Defer to actual type */
.name = "i"
},
{ ATF_OPEN_TYPE | ATF_NOFLAGS, 0, offsetof(struct T1, any),
.tag = -1 /* Ambiguous tag (ANY?) */,
.tag_mode = 0,
.type = (void *)&asn1_DEF_ANY,
.type = (void *)&asn_DEF_ANY,
.memb_constraints = 0, /* Defer to actual type */
.name = "any"
},
};
static ber_tlv_tag_t asn1_DEF_T1_tags[] = {
static ber_tlv_tag_t asn_DEF_T1_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_T1_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_T1_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, 0, 0 }, /* i at 15 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_T1_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_T1_specs = {
sizeof(struct T1),
offsetof(struct T1, _ber_dec_ctx),
asn1_DEF_T1_tag2el,
offsetof(struct T1, _asn_ctx),
asn_DEF_T1_tag2el,
1, /* Count of tags in the map */
-1, /* Start extensions */
-1 /* Stop extensions */
};
asn1_TYPE_descriptor_t asn1_DEF_T1 = {
asn_TYPE_descriptor_t asn_DEF_T1 = {
"T1",
SEQUENCE_free,
SEQUENCE_print,
@ -62,15 +62,15 @@ asn1_TYPE_descriptor_t asn1_DEF_T1 = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T1_tags,
sizeof(asn1_DEF_T1_tags)
/sizeof(asn1_DEF_T1_tags[0]), /* 1 */
asn1_DEF_T1_tags, /* Same as above */
sizeof(asn1_DEF_T1_tags)
/sizeof(asn1_DEF_T1_tags[0]), /* 1 */
asn1_MBR_T1,
asn_DEF_T1_tags,
sizeof(asn_DEF_T1_tags)
/sizeof(asn_DEF_T1_tags[0]), /* 1 */
asn_DEF_T1_tags, /* Same as above */
sizeof(asn_DEF_T1_tags)
/sizeof(asn_DEF_T1_tags[0]), /* 1 */
asn_MBR_T1,
2, /* Elements count */
&asn1_DEF_T1_specs /* Additional specs */
&asn_DEF_T1_specs /* Additional specs */
};
@ -82,7 +82,7 @@ asn1_TYPE_descriptor_t asn1_DEF_T1 = {
/*** <<< DEPS [T2] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T2;
extern asn_TYPE_descriptor_t asn_DEF_T2;
/*** <<< TYPE-DECLS [T2] >>> ***/
@ -92,43 +92,43 @@ typedef struct T2 {
ANY_t *any /* OPTIONAL */;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} T2_t;
/*** <<< STAT-DEFS [T2] >>> ***/
static asn1_TYPE_member_t asn1_MBR_T2[] = {
static asn_TYPE_member_t asn_MBR_T2[] = {
{ ATF_NOFLAGS, 0, offsetof(struct T2, i),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_INTEGER,
.type = (void *)&asn_DEF_INTEGER,
.memb_constraints = 0, /* Defer to actual type */
.name = "i"
},
{ ATF_POINTER, 1, offsetof(struct T2, any),
.tag = (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
.tag_mode = +1, /* EXPLICIT tag at current level */
.type = (void *)&asn1_DEF_ANY,
.type = (void *)&asn_DEF_ANY,
.memb_constraints = 0, /* Defer to actual type */
.name = "any"
},
};
static ber_tlv_tag_t asn1_DEF_T2_tags[] = {
static ber_tlv_tag_t asn_DEF_T2_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_T2_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_T2_tag2el[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, 0, 0 }, /* i at 20 */
{ (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 1, 0, 0 }, /* any at 21 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_T2_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_T2_specs = {
sizeof(struct T2),
offsetof(struct T2, _ber_dec_ctx),
asn1_DEF_T2_tag2el,
offsetof(struct T2, _asn_ctx),
asn_DEF_T2_tag2el,
2, /* Count of tags in the map */
-1, /* Start extensions */
-1 /* Stop extensions */
};
asn1_TYPE_descriptor_t asn1_DEF_T2 = {
asn_TYPE_descriptor_t asn_DEF_T2 = {
"T2",
SEQUENCE_free,
SEQUENCE_print,
@ -138,14 +138,14 @@ asn1_TYPE_descriptor_t asn1_DEF_T2 = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T2_tags,
sizeof(asn1_DEF_T2_tags)
/sizeof(asn1_DEF_T2_tags[0]), /* 1 */
asn1_DEF_T2_tags, /* Same as above */
sizeof(asn1_DEF_T2_tags)
/sizeof(asn1_DEF_T2_tags[0]), /* 1 */
asn1_MBR_T2,
asn_DEF_T2_tags,
sizeof(asn_DEF_T2_tags)
/sizeof(asn_DEF_T2_tags[0]), /* 1 */
asn_DEF_T2_tags, /* Same as above */
sizeof(asn_DEF_T2_tags)
/sizeof(asn_DEF_T2_tags[0]), /* 1 */
asn_MBR_T2,
2, /* Elements count */
&asn1_DEF_T2_specs /* Additional specs */
&asn_DEF_T2_specs /* Additional specs */
};

View File

@ -10,7 +10,7 @@ typedef T2_t T1_t;
/*** <<< FUNC-DECLS [T1] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T1;
extern asn_TYPE_descriptor_t asn_DEF_T1;
asn_struct_free_f T1_free;
asn_struct_print_f T1_print;
asn_constr_check_f T1_constraint;
@ -21,10 +21,10 @@ xer_type_encoder_f T1_encode_xer;
/*** <<< CODE [T1] >>> ***/
int
T1_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
T1_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
/* Replace with underlying type checker */
td->check_constraints = asn1_DEF_T2.check_constraints;
td->check_constraints = asn_DEF_T2.check_constraints;
return td->check_constraints(td, sptr, app_errlog, app_key);
}
@ -33,41 +33,41 @@ T1_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
* so here we adjust the DEF accordingly.
*/
static void
T1_inherit_TYPE_descriptor(asn1_TYPE_descriptor_t *td) {
td->free_struct = asn1_DEF_T2.free_struct;
td->print_struct = asn1_DEF_T2.print_struct;
td->ber_decoder = asn1_DEF_T2.ber_decoder;
td->der_encoder = asn1_DEF_T2.der_encoder;
td->xer_decoder = asn1_DEF_T2.xer_decoder;
td->xer_encoder = asn1_DEF_T2.xer_encoder;
td->elements = asn1_DEF_T2.elements;
td->elements_count = asn1_DEF_T2.elements_count;
td->specifics = asn1_DEF_T2.specifics;
T1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
td->free_struct = asn_DEF_T2.free_struct;
td->print_struct = asn_DEF_T2.print_struct;
td->ber_decoder = asn_DEF_T2.ber_decoder;
td->der_encoder = asn_DEF_T2.der_encoder;
td->xer_decoder = asn_DEF_T2.xer_decoder;
td->xer_encoder = asn_DEF_T2.xer_encoder;
td->elements = asn_DEF_T2.elements;
td->elements_count = asn_DEF_T2.elements_count;
td->specifics = asn_DEF_T2.specifics;
}
void
T1_free(asn1_TYPE_descriptor_t *td,
T1_free(asn_TYPE_descriptor_t *td,
void *struct_ptr, int contents_only) {
T1_inherit_TYPE_descriptor(td);
td->free_struct(td, struct_ptr, contents_only);
}
int
T1_print(asn1_TYPE_descriptor_t *td, const void *struct_ptr,
T1_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
T1_inherit_TYPE_descriptor(td);
return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
}
ber_dec_rval_t
T1_decode_ber(asn1_TYPE_descriptor_t *td,
T1_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
void **structure, void *bufptr, size_t size, int tag_mode) {
T1_inherit_TYPE_descriptor(td);
return td->ber_decoder(td, structure, bufptr, size, tag_mode);
return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
}
asn_enc_rval_t
T1_encode_der(asn1_TYPE_descriptor_t *td,
T1_encode_der(asn_TYPE_descriptor_t *td,
void *structure, int tag_mode, ber_tlv_tag_t tag,
asn_app_consume_bytes_f *cb, void *app_key) {
T1_inherit_TYPE_descriptor(td);
@ -75,7 +75,7 @@ T1_encode_der(asn1_TYPE_descriptor_t *td,
}
asn_enc_rval_t
T1_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
T1_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
int ilevel, enum xer_encoder_flags_e flags,
asn_app_consume_bytes_f *cb, void *app_key) {
T1_inherit_TYPE_descriptor(td);
@ -85,13 +85,13 @@ T1_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
/*** <<< STAT-DEFS [T1] >>> ***/
static ber_tlv_tag_t asn1_DEF_T1_tags[] = {
static ber_tlv_tag_t asn_DEF_T1_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (2 << 2)),
(ASN_TAG_CLASS_CONTEXT | (3 << 2)),
(ASN_TAG_CLASS_CONTEXT | (4 << 2)),
(ASN_TAG_CLASS_CONTEXT | (6 << 2))
};
static ber_tlv_tag_t asn1_DEF_T1_all_tags[] = {
static ber_tlv_tag_t asn_DEF_T1_all_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (2 << 2)),
(ASN_TAG_CLASS_CONTEXT | (3 << 2)),
(ASN_TAG_CLASS_CONTEXT | (4 << 2)),
@ -99,7 +99,7 @@ static ber_tlv_tag_t asn1_DEF_T1_all_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (6 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (9 << 2))
};
asn1_TYPE_descriptor_t asn1_DEF_T1 = {
asn_TYPE_descriptor_t asn_DEF_T1 = {
"T1",
T1_free,
T1_print,
@ -109,12 +109,12 @@ asn1_TYPE_descriptor_t asn1_DEF_T1 = {
0, /* Not implemented yet */
T1_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T1_tags,
sizeof(asn1_DEF_T1_tags)
/sizeof(asn1_DEF_T1_tags[0]), /* 4 */
asn1_DEF_T1_all_tags,
sizeof(asn1_DEF_T1_all_tags)
/sizeof(asn1_DEF_T1_all_tags[0]), /* 6 */
asn_DEF_T1_tags,
sizeof(asn_DEF_T1_tags)
/sizeof(asn_DEF_T1_tags[0]), /* 4 */
asn_DEF_T1_all_tags,
sizeof(asn_DEF_T1_all_tags)
/sizeof(asn_DEF_T1_all_tags[0]), /* 6 */
0, 0, /* No members */
0 /* No specifics */
};
@ -131,7 +131,7 @@ typedef T3_t T2_t;
/*** <<< FUNC-DECLS [T2] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T2;
extern asn_TYPE_descriptor_t asn_DEF_T2;
asn_struct_free_f T2_free;
asn_struct_print_f T2_print;
asn_constr_check_f T2_constraint;
@ -142,10 +142,10 @@ xer_type_encoder_f T2_encode_xer;
/*** <<< CODE [T2] >>> ***/
int
T2_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
T2_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
/* Replace with underlying type checker */
td->check_constraints = asn1_DEF_T3.check_constraints;
td->check_constraints = asn_DEF_T3.check_constraints;
return td->check_constraints(td, sptr, app_errlog, app_key);
}
@ -154,41 +154,41 @@ T2_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
* so here we adjust the DEF accordingly.
*/
static void
T2_inherit_TYPE_descriptor(asn1_TYPE_descriptor_t *td) {
td->free_struct = asn1_DEF_T3.free_struct;
td->print_struct = asn1_DEF_T3.print_struct;
td->ber_decoder = asn1_DEF_T3.ber_decoder;
td->der_encoder = asn1_DEF_T3.der_encoder;
td->xer_decoder = asn1_DEF_T3.xer_decoder;
td->xer_encoder = asn1_DEF_T3.xer_encoder;
td->elements = asn1_DEF_T3.elements;
td->elements_count = asn1_DEF_T3.elements_count;
td->specifics = asn1_DEF_T3.specifics;
T2_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
td->free_struct = asn_DEF_T3.free_struct;
td->print_struct = asn_DEF_T3.print_struct;
td->ber_decoder = asn_DEF_T3.ber_decoder;
td->der_encoder = asn_DEF_T3.der_encoder;
td->xer_decoder = asn_DEF_T3.xer_decoder;
td->xer_encoder = asn_DEF_T3.xer_encoder;
td->elements = asn_DEF_T3.elements;
td->elements_count = asn_DEF_T3.elements_count;
td->specifics = asn_DEF_T3.specifics;
}
void
T2_free(asn1_TYPE_descriptor_t *td,
T2_free(asn_TYPE_descriptor_t *td,
void *struct_ptr, int contents_only) {
T2_inherit_TYPE_descriptor(td);
td->free_struct(td, struct_ptr, contents_only);
}
int
T2_print(asn1_TYPE_descriptor_t *td, const void *struct_ptr,
T2_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
T2_inherit_TYPE_descriptor(td);
return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
}
ber_dec_rval_t
T2_decode_ber(asn1_TYPE_descriptor_t *td,
T2_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
void **structure, void *bufptr, size_t size, int tag_mode) {
T2_inherit_TYPE_descriptor(td);
return td->ber_decoder(td, structure, bufptr, size, tag_mode);
return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
}
asn_enc_rval_t
T2_encode_der(asn1_TYPE_descriptor_t *td,
T2_encode_der(asn_TYPE_descriptor_t *td,
void *structure, int tag_mode, ber_tlv_tag_t tag,
asn_app_consume_bytes_f *cb, void *app_key) {
T2_inherit_TYPE_descriptor(td);
@ -196,7 +196,7 @@ T2_encode_der(asn1_TYPE_descriptor_t *td,
}
asn_enc_rval_t
T2_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
T2_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
int ilevel, enum xer_encoder_flags_e flags,
asn_app_consume_bytes_f *cb, void *app_key) {
T2_inherit_TYPE_descriptor(td);
@ -206,19 +206,19 @@ T2_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
/*** <<< STAT-DEFS [T2] >>> ***/
static ber_tlv_tag_t asn1_DEF_T2_tags[] = {
static ber_tlv_tag_t asn_DEF_T2_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (3 << 2)),
(ASN_TAG_CLASS_CONTEXT | (4 << 2)),
(ASN_TAG_CLASS_CONTEXT | (6 << 2))
};
static ber_tlv_tag_t asn1_DEF_T2_all_tags[] = {
static ber_tlv_tag_t asn_DEF_T2_all_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (3 << 2)),
(ASN_TAG_CLASS_CONTEXT | (4 << 2)),
(ASN_TAG_CLASS_CONTEXT | (5 << 2)),
(ASN_TAG_CLASS_CONTEXT | (6 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (9 << 2))
};
asn1_TYPE_descriptor_t asn1_DEF_T2 = {
asn_TYPE_descriptor_t asn_DEF_T2 = {
"T2",
T2_free,
T2_print,
@ -228,12 +228,12 @@ asn1_TYPE_descriptor_t asn1_DEF_T2 = {
0, /* Not implemented yet */
T2_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T2_tags,
sizeof(asn1_DEF_T2_tags)
/sizeof(asn1_DEF_T2_tags[0]), /* 3 */
asn1_DEF_T2_all_tags,
sizeof(asn1_DEF_T2_all_tags)
/sizeof(asn1_DEF_T2_all_tags[0]), /* 5 */
asn_DEF_T2_tags,
sizeof(asn_DEF_T2_tags)
/sizeof(asn_DEF_T2_tags[0]), /* 3 */
asn_DEF_T2_all_tags,
sizeof(asn_DEF_T2_all_tags)
/sizeof(asn_DEF_T2_all_tags[0]), /* 5 */
0, 0, /* No members */
0 /* No specifics */
};
@ -250,7 +250,7 @@ typedef T4_t T3_t;
/*** <<< FUNC-DECLS [T3] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T3;
extern asn_TYPE_descriptor_t asn_DEF_T3;
asn_struct_free_f T3_free;
asn_struct_print_f T3_print;
asn_constr_check_f T3_constraint;
@ -261,10 +261,10 @@ xer_type_encoder_f T3_encode_xer;
/*** <<< CODE [T3] >>> ***/
int
T3_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
T3_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
/* Replace with underlying type checker */
td->check_constraints = asn1_DEF_T4.check_constraints;
td->check_constraints = asn_DEF_T4.check_constraints;
return td->check_constraints(td, sptr, app_errlog, app_key);
}
@ -273,41 +273,41 @@ T3_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
* so here we adjust the DEF accordingly.
*/
static void
T3_inherit_TYPE_descriptor(asn1_TYPE_descriptor_t *td) {
td->free_struct = asn1_DEF_T4.free_struct;
td->print_struct = asn1_DEF_T4.print_struct;
td->ber_decoder = asn1_DEF_T4.ber_decoder;
td->der_encoder = asn1_DEF_T4.der_encoder;
td->xer_decoder = asn1_DEF_T4.xer_decoder;
td->xer_encoder = asn1_DEF_T4.xer_encoder;
td->elements = asn1_DEF_T4.elements;
td->elements_count = asn1_DEF_T4.elements_count;
td->specifics = asn1_DEF_T4.specifics;
T3_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
td->free_struct = asn_DEF_T4.free_struct;
td->print_struct = asn_DEF_T4.print_struct;
td->ber_decoder = asn_DEF_T4.ber_decoder;
td->der_encoder = asn_DEF_T4.der_encoder;
td->xer_decoder = asn_DEF_T4.xer_decoder;
td->xer_encoder = asn_DEF_T4.xer_encoder;
td->elements = asn_DEF_T4.elements;
td->elements_count = asn_DEF_T4.elements_count;
td->specifics = asn_DEF_T4.specifics;
}
void
T3_free(asn1_TYPE_descriptor_t *td,
T3_free(asn_TYPE_descriptor_t *td,
void *struct_ptr, int contents_only) {
T3_inherit_TYPE_descriptor(td);
td->free_struct(td, struct_ptr, contents_only);
}
int
T3_print(asn1_TYPE_descriptor_t *td, const void *struct_ptr,
T3_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
T3_inherit_TYPE_descriptor(td);
return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
}
ber_dec_rval_t
T3_decode_ber(asn1_TYPE_descriptor_t *td,
T3_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
void **structure, void *bufptr, size_t size, int tag_mode) {
T3_inherit_TYPE_descriptor(td);
return td->ber_decoder(td, structure, bufptr, size, tag_mode);
return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
}
asn_enc_rval_t
T3_encode_der(asn1_TYPE_descriptor_t *td,
T3_encode_der(asn_TYPE_descriptor_t *td,
void *structure, int tag_mode, ber_tlv_tag_t tag,
asn_app_consume_bytes_f *cb, void *app_key) {
T3_inherit_TYPE_descriptor(td);
@ -315,7 +315,7 @@ T3_encode_der(asn1_TYPE_descriptor_t *td,
}
asn_enc_rval_t
T3_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
T3_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
int ilevel, enum xer_encoder_flags_e flags,
asn_app_consume_bytes_f *cb, void *app_key) {
T3_inherit_TYPE_descriptor(td);
@ -325,17 +325,17 @@ T3_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
/*** <<< STAT-DEFS [T3] >>> ***/
static ber_tlv_tag_t asn1_DEF_T3_tags[] = {
static ber_tlv_tag_t asn_DEF_T3_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (4 << 2)),
(ASN_TAG_CLASS_CONTEXT | (6 << 2))
};
static ber_tlv_tag_t asn1_DEF_T3_all_tags[] = {
static ber_tlv_tag_t asn_DEF_T3_all_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (4 << 2)),
(ASN_TAG_CLASS_CONTEXT | (5 << 2)),
(ASN_TAG_CLASS_CONTEXT | (6 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (9 << 2))
};
asn1_TYPE_descriptor_t asn1_DEF_T3 = {
asn_TYPE_descriptor_t asn_DEF_T3 = {
"T3",
T3_free,
T3_print,
@ -345,12 +345,12 @@ asn1_TYPE_descriptor_t asn1_DEF_T3 = {
0, /* Not implemented yet */
T3_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T3_tags,
sizeof(asn1_DEF_T3_tags)
/sizeof(asn1_DEF_T3_tags[0]), /* 2 */
asn1_DEF_T3_all_tags,
sizeof(asn1_DEF_T3_all_tags)
/sizeof(asn1_DEF_T3_all_tags[0]), /* 4 */
asn_DEF_T3_tags,
sizeof(asn_DEF_T3_tags)
/sizeof(asn_DEF_T3_tags[0]), /* 2 */
asn_DEF_T3_all_tags,
sizeof(asn_DEF_T3_all_tags)
/sizeof(asn_DEF_T3_all_tags[0]), /* 4 */
0, 0, /* No members */
0 /* No specifics */
};
@ -367,7 +367,7 @@ typedef T5_t T4_t;
/*** <<< FUNC-DECLS [T4] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T4;
extern asn_TYPE_descriptor_t asn_DEF_T4;
asn_struct_free_f T4_free;
asn_struct_print_f T4_print;
asn_constr_check_f T4_constraint;
@ -378,10 +378,10 @@ xer_type_encoder_f T4_encode_xer;
/*** <<< CODE [T4] >>> ***/
int
T4_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
T4_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
/* Replace with underlying type checker */
td->check_constraints = asn1_DEF_T5.check_constraints;
td->check_constraints = asn_DEF_T5.check_constraints;
return td->check_constraints(td, sptr, app_errlog, app_key);
}
@ -390,41 +390,41 @@ T4_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
* so here we adjust the DEF accordingly.
*/
static void
T4_inherit_TYPE_descriptor(asn1_TYPE_descriptor_t *td) {
td->free_struct = asn1_DEF_T5.free_struct;
td->print_struct = asn1_DEF_T5.print_struct;
td->ber_decoder = asn1_DEF_T5.ber_decoder;
td->der_encoder = asn1_DEF_T5.der_encoder;
td->xer_decoder = asn1_DEF_T5.xer_decoder;
td->xer_encoder = asn1_DEF_T5.xer_encoder;
td->elements = asn1_DEF_T5.elements;
td->elements_count = asn1_DEF_T5.elements_count;
td->specifics = asn1_DEF_T5.specifics;
T4_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
td->free_struct = asn_DEF_T5.free_struct;
td->print_struct = asn_DEF_T5.print_struct;
td->ber_decoder = asn_DEF_T5.ber_decoder;
td->der_encoder = asn_DEF_T5.der_encoder;
td->xer_decoder = asn_DEF_T5.xer_decoder;
td->xer_encoder = asn_DEF_T5.xer_encoder;
td->elements = asn_DEF_T5.elements;
td->elements_count = asn_DEF_T5.elements_count;
td->specifics = asn_DEF_T5.specifics;
}
void
T4_free(asn1_TYPE_descriptor_t *td,
T4_free(asn_TYPE_descriptor_t *td,
void *struct_ptr, int contents_only) {
T4_inherit_TYPE_descriptor(td);
td->free_struct(td, struct_ptr, contents_only);
}
int
T4_print(asn1_TYPE_descriptor_t *td, const void *struct_ptr,
T4_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
T4_inherit_TYPE_descriptor(td);
return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
}
ber_dec_rval_t
T4_decode_ber(asn1_TYPE_descriptor_t *td,
T4_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
void **structure, void *bufptr, size_t size, int tag_mode) {
T4_inherit_TYPE_descriptor(td);
return td->ber_decoder(td, structure, bufptr, size, tag_mode);
return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
}
asn_enc_rval_t
T4_encode_der(asn1_TYPE_descriptor_t *td,
T4_encode_der(asn_TYPE_descriptor_t *td,
void *structure, int tag_mode, ber_tlv_tag_t tag,
asn_app_consume_bytes_f *cb, void *app_key) {
T4_inherit_TYPE_descriptor(td);
@ -432,7 +432,7 @@ T4_encode_der(asn1_TYPE_descriptor_t *td,
}
asn_enc_rval_t
T4_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
T4_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
int ilevel, enum xer_encoder_flags_e flags,
asn_app_consume_bytes_f *cb, void *app_key) {
T4_inherit_TYPE_descriptor(td);
@ -442,12 +442,12 @@ T4_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
/*** <<< STAT-DEFS [T4] >>> ***/
static ber_tlv_tag_t asn1_DEF_T4_tags[] = {
static ber_tlv_tag_t asn_DEF_T4_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (5 << 2)),
(ASN_TAG_CLASS_CONTEXT | (6 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (9 << 2))
};
asn1_TYPE_descriptor_t asn1_DEF_T4 = {
asn_TYPE_descriptor_t asn_DEF_T4 = {
"T4",
T4_free,
T4_print,
@ -457,12 +457,12 @@ asn1_TYPE_descriptor_t asn1_DEF_T4 = {
0, /* Not implemented yet */
T4_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T4_tags,
sizeof(asn1_DEF_T4_tags)
/sizeof(asn1_DEF_T4_tags[0]) - 1, /* 2 */
asn1_DEF_T4_tags, /* Same as above */
sizeof(asn1_DEF_T4_tags)
/sizeof(asn1_DEF_T4_tags[0]), /* 3 */
asn_DEF_T4_tags,
sizeof(asn_DEF_T4_tags)
/sizeof(asn_DEF_T4_tags[0]) - 1, /* 2 */
asn_DEF_T4_tags, /* Same as above */
sizeof(asn_DEF_T4_tags)
/sizeof(asn_DEF_T4_tags[0]), /* 3 */
0, 0, /* No members */
0 /* No specifics */
};
@ -479,7 +479,7 @@ typedef T6_t T5_t;
/*** <<< FUNC-DECLS [T5] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T5;
extern asn_TYPE_descriptor_t asn_DEF_T5;
asn_struct_free_f T5_free;
asn_struct_print_f T5_print;
asn_constr_check_f T5_constraint;
@ -490,10 +490,10 @@ xer_type_encoder_f T5_encode_xer;
/*** <<< CODE [T5] >>> ***/
int
T5_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
T5_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
/* Replace with underlying type checker */
td->check_constraints = asn1_DEF_T6.check_constraints;
td->check_constraints = asn_DEF_T6.check_constraints;
return td->check_constraints(td, sptr, app_errlog, app_key);
}
@ -502,41 +502,41 @@ T5_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
* so here we adjust the DEF accordingly.
*/
static void
T5_inherit_TYPE_descriptor(asn1_TYPE_descriptor_t *td) {
td->free_struct = asn1_DEF_T6.free_struct;
td->print_struct = asn1_DEF_T6.print_struct;
td->ber_decoder = asn1_DEF_T6.ber_decoder;
td->der_encoder = asn1_DEF_T6.der_encoder;
td->xer_decoder = asn1_DEF_T6.xer_decoder;
td->xer_encoder = asn1_DEF_T6.xer_encoder;
td->elements = asn1_DEF_T6.elements;
td->elements_count = asn1_DEF_T6.elements_count;
td->specifics = asn1_DEF_T6.specifics;
T5_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
td->free_struct = asn_DEF_T6.free_struct;
td->print_struct = asn_DEF_T6.print_struct;
td->ber_decoder = asn_DEF_T6.ber_decoder;
td->der_encoder = asn_DEF_T6.der_encoder;
td->xer_decoder = asn_DEF_T6.xer_decoder;
td->xer_encoder = asn_DEF_T6.xer_encoder;
td->elements = asn_DEF_T6.elements;
td->elements_count = asn_DEF_T6.elements_count;
td->specifics = asn_DEF_T6.specifics;
}
void
T5_free(asn1_TYPE_descriptor_t *td,
T5_free(asn_TYPE_descriptor_t *td,
void *struct_ptr, int contents_only) {
T5_inherit_TYPE_descriptor(td);
td->free_struct(td, struct_ptr, contents_only);
}
int
T5_print(asn1_TYPE_descriptor_t *td, const void *struct_ptr,
T5_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
T5_inherit_TYPE_descriptor(td);
return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
}
ber_dec_rval_t
T5_decode_ber(asn1_TYPE_descriptor_t *td,
T5_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
void **structure, void *bufptr, size_t size, int tag_mode) {
T5_inherit_TYPE_descriptor(td);
return td->ber_decoder(td, structure, bufptr, size, tag_mode);
return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
}
asn_enc_rval_t
T5_encode_der(asn1_TYPE_descriptor_t *td,
T5_encode_der(asn_TYPE_descriptor_t *td,
void *structure, int tag_mode, ber_tlv_tag_t tag,
asn_app_consume_bytes_f *cb, void *app_key) {
T5_inherit_TYPE_descriptor(td);
@ -544,7 +544,7 @@ T5_encode_der(asn1_TYPE_descriptor_t *td,
}
asn_enc_rval_t
T5_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
T5_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
int ilevel, enum xer_encoder_flags_e flags,
asn_app_consume_bytes_f *cb, void *app_key) {
T5_inherit_TYPE_descriptor(td);
@ -554,11 +554,11 @@ T5_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
/*** <<< STAT-DEFS [T5] >>> ***/
static ber_tlv_tag_t asn1_DEF_T5_tags[] = {
static ber_tlv_tag_t asn_DEF_T5_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (6 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (9 << 2))
};
asn1_TYPE_descriptor_t asn1_DEF_T5 = {
asn_TYPE_descriptor_t asn_DEF_T5 = {
"T5",
T5_free,
T5_print,
@ -568,12 +568,12 @@ asn1_TYPE_descriptor_t asn1_DEF_T5 = {
0, /* Not implemented yet */
T5_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T5_tags,
sizeof(asn1_DEF_T5_tags)
/sizeof(asn1_DEF_T5_tags[0]) - 1, /* 1 */
asn1_DEF_T5_tags, /* Same as above */
sizeof(asn1_DEF_T5_tags)
/sizeof(asn1_DEF_T5_tags[0]), /* 2 */
asn_DEF_T5_tags,
sizeof(asn_DEF_T5_tags)
/sizeof(asn_DEF_T5_tags[0]) - 1, /* 1 */
asn_DEF_T5_tags, /* Same as above */
sizeof(asn_DEF_T5_tags)
/sizeof(asn_DEF_T5_tags[0]), /* 2 */
0, 0, /* No members */
0 /* No specifics */
};
@ -591,7 +591,7 @@ typedef REAL_t T6_t;
/*** <<< FUNC-DECLS [T6] >>> ***/
/* This type is equivalent to REAL */
#define asn1_DEF_T6 asn1_DEF_REAL
#define asn_DEF_T6 asn_DEF_REAL
/*** <<< CODE [T6] >>> ***/
@ -609,7 +609,7 @@ typedef Ts_t T_t;
/*** <<< FUNC-DECLS [T] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T;
extern asn_TYPE_descriptor_t asn_DEF_T;
asn_struct_free_f T_free;
asn_struct_print_f T_print;
asn_constr_check_f T_constraint;
@ -620,10 +620,10 @@ xer_type_encoder_f T_encode_xer;
/*** <<< CODE [T] >>> ***/
int
T_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
T_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
/* Replace with underlying type checker */
td->check_constraints = asn1_DEF_Ts.check_constraints;
td->check_constraints = asn_DEF_Ts.check_constraints;
return td->check_constraints(td, sptr, app_errlog, app_key);
}
@ -632,41 +632,41 @@ T_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
* so here we adjust the DEF accordingly.
*/
static void
T_inherit_TYPE_descriptor(asn1_TYPE_descriptor_t *td) {
td->free_struct = asn1_DEF_Ts.free_struct;
td->print_struct = asn1_DEF_Ts.print_struct;
td->ber_decoder = asn1_DEF_Ts.ber_decoder;
td->der_encoder = asn1_DEF_Ts.der_encoder;
td->xer_decoder = asn1_DEF_Ts.xer_decoder;
td->xer_encoder = asn1_DEF_Ts.xer_encoder;
td->elements = asn1_DEF_Ts.elements;
td->elements_count = asn1_DEF_Ts.elements_count;
td->specifics = asn1_DEF_Ts.specifics;
T_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
td->free_struct = asn_DEF_Ts.free_struct;
td->print_struct = asn_DEF_Ts.print_struct;
td->ber_decoder = asn_DEF_Ts.ber_decoder;
td->der_encoder = asn_DEF_Ts.der_encoder;
td->xer_decoder = asn_DEF_Ts.xer_decoder;
td->xer_encoder = asn_DEF_Ts.xer_encoder;
td->elements = asn_DEF_Ts.elements;
td->elements_count = asn_DEF_Ts.elements_count;
td->specifics = asn_DEF_Ts.specifics;
}
void
T_free(asn1_TYPE_descriptor_t *td,
T_free(asn_TYPE_descriptor_t *td,
void *struct_ptr, int contents_only) {
T_inherit_TYPE_descriptor(td);
td->free_struct(td, struct_ptr, contents_only);
}
int
T_print(asn1_TYPE_descriptor_t *td, const void *struct_ptr,
T_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
T_inherit_TYPE_descriptor(td);
return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
}
ber_dec_rval_t
T_decode_ber(asn1_TYPE_descriptor_t *td,
T_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
void **structure, void *bufptr, size_t size, int tag_mode) {
T_inherit_TYPE_descriptor(td);
return td->ber_decoder(td, structure, bufptr, size, tag_mode);
return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
}
asn_enc_rval_t
T_encode_der(asn1_TYPE_descriptor_t *td,
T_encode_der(asn_TYPE_descriptor_t *td,
void *structure, int tag_mode, ber_tlv_tag_t tag,
asn_app_consume_bytes_f *cb, void *app_key) {
T_inherit_TYPE_descriptor(td);
@ -674,7 +674,7 @@ T_encode_der(asn1_TYPE_descriptor_t *td,
}
asn_enc_rval_t
T_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
T_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
int ilevel, enum xer_encoder_flags_e flags,
asn_app_consume_bytes_f *cb, void *app_key) {
T_inherit_TYPE_descriptor(td);
@ -684,12 +684,12 @@ T_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
/*** <<< STAT-DEFS [T] >>> ***/
static ber_tlv_tag_t asn1_DEF_T_tags[] = {
static ber_tlv_tag_t asn_DEF_T_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (0 << 2)),
(ASN_TAG_CLASS_CONTEXT | (123 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
asn1_TYPE_descriptor_t asn1_DEF_T = {
asn_TYPE_descriptor_t asn_DEF_T = {
"T",
T_free,
T_print,
@ -699,12 +699,12 @@ asn1_TYPE_descriptor_t asn1_DEF_T = {
0, /* Not implemented yet */
T_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T_tags,
sizeof(asn1_DEF_T_tags)
/sizeof(asn1_DEF_T_tags[0]) - 2, /* 1 */
asn1_DEF_T_tags, /* Same as above */
sizeof(asn1_DEF_T_tags)
/sizeof(asn1_DEF_T_tags[0]), /* 3 */
asn_DEF_T_tags,
sizeof(asn_DEF_T_tags)
/sizeof(asn_DEF_T_tags[0]) - 2, /* 1 */
asn_DEF_T_tags, /* Same as above */
sizeof(asn_DEF_T_tags)
/sizeof(asn_DEF_T_tags[0]), /* 3 */
0, 0, /* Defined elsewhere */
0 /* No specifics */
};
@ -718,7 +718,7 @@ asn1_TYPE_descriptor_t asn1_DEF_T = {
/*** <<< DEPS [Ts] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_Ts;
extern asn_TYPE_descriptor_t asn_DEF_Ts;
/*** <<< TYPE-DECLS [Ts] >>> ***/
@ -729,52 +729,52 @@ typedef struct Ts {
T3_t m3;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} Ts_t;
/*** <<< STAT-DEFS [Ts] >>> ***/
static asn1_TYPE_member_t asn1_MBR_Ts[] = {
static asn_TYPE_member_t asn_MBR_Ts[] = {
{ ATF_NOFLAGS, 0, offsetof(struct Ts, m1),
.tag = (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_T2,
.type = (void *)&asn_DEF_T2,
.memb_constraints = 0, /* Defer to actual type */
.name = "m1"
},
{ ATF_POINTER, 1, offsetof(struct Ts, m2),
.tag = (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
.tag_mode = +1, /* EXPLICIT tag at current level */
.type = (void *)&asn1_DEF_T3,
.type = (void *)&asn_DEF_T3,
.memb_constraints = 0, /* Defer to actual type */
.name = "m2"
},
{ ATF_NOFLAGS, 0, offsetof(struct Ts, m3),
.tag = (ASN_TAG_CLASS_CONTEXT | (3 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_T3,
.type = (void *)&asn_DEF_T3,
.memb_constraints = 0, /* Defer to actual type */
.name = "m3"
},
};
static ber_tlv_tag_t asn1_DEF_Ts_tags[] = {
static ber_tlv_tag_t asn_DEF_Ts_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (123 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_Ts_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_Ts_tag2el[] = {
{ (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 0, 0, 0 }, /* m1 at 24 */
{ (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 1, 0, 0 }, /* m2 at 25 */
{ (ASN_TAG_CLASS_CONTEXT | (3 << 2)), 2, 0, 0 }, /* m3 at 27 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_Ts_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_Ts_specs = {
sizeof(struct Ts),
offsetof(struct Ts, _ber_dec_ctx),
asn1_DEF_Ts_tag2el,
offsetof(struct Ts, _asn_ctx),
asn_DEF_Ts_tag2el,
3, /* Count of tags in the map */
-1, /* Start extensions */
-1 /* Stop extensions */
};
asn1_TYPE_descriptor_t asn1_DEF_Ts = {
asn_TYPE_descriptor_t asn_DEF_Ts = {
"Ts",
SEQUENCE_free,
SEQUENCE_print,
@ -784,14 +784,14 @@ asn1_TYPE_descriptor_t asn1_DEF_Ts = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_Ts_tags,
sizeof(asn1_DEF_Ts_tags)
/sizeof(asn1_DEF_Ts_tags[0]) - 1, /* 1 */
asn1_DEF_Ts_tags, /* Same as above */
sizeof(asn1_DEF_Ts_tags)
/sizeof(asn1_DEF_Ts_tags[0]), /* 2 */
asn1_MBR_Ts,
asn_DEF_Ts_tags,
sizeof(asn_DEF_Ts_tags)
/sizeof(asn_DEF_Ts_tags[0]) - 1, /* 1 */
asn_DEF_Ts_tags, /* Same as above */
sizeof(asn_DEF_Ts_tags)
/sizeof(asn_DEF_Ts_tags[0]), /* 2 */
asn_MBR_Ts,
3, /* Elements count */
&asn1_DEF_Ts_specs /* Additional specs */
&asn_DEF_Ts_specs /* Additional specs */
};

View File

@ -10,7 +10,7 @@ typedef T2_t T1_t;
/*** <<< FUNC-DECLS [T1] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T1;
extern asn_TYPE_descriptor_t asn_DEF_T1;
asn_struct_free_f T1_free;
asn_struct_print_f T1_print;
asn_constr_check_f T1_constraint;
@ -21,10 +21,10 @@ xer_type_encoder_f T1_encode_xer;
/*** <<< CODE [T1] >>> ***/
int
T1_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
T1_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
/* Replace with underlying type checker */
td->check_constraints = asn1_DEF_T2.check_constraints;
td->check_constraints = asn_DEF_T2.check_constraints;
return td->check_constraints(td, sptr, app_errlog, app_key);
}
@ -33,41 +33,41 @@ T1_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
* so here we adjust the DEF accordingly.
*/
static void
T1_inherit_TYPE_descriptor(asn1_TYPE_descriptor_t *td) {
td->free_struct = asn1_DEF_T2.free_struct;
td->print_struct = asn1_DEF_T2.print_struct;
td->ber_decoder = asn1_DEF_T2.ber_decoder;
td->der_encoder = asn1_DEF_T2.der_encoder;
td->xer_decoder = asn1_DEF_T2.xer_decoder;
td->xer_encoder = asn1_DEF_T2.xer_encoder;
td->elements = asn1_DEF_T2.elements;
td->elements_count = asn1_DEF_T2.elements_count;
td->specifics = asn1_DEF_T2.specifics;
T1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
td->free_struct = asn_DEF_T2.free_struct;
td->print_struct = asn_DEF_T2.print_struct;
td->ber_decoder = asn_DEF_T2.ber_decoder;
td->der_encoder = asn_DEF_T2.der_encoder;
td->xer_decoder = asn_DEF_T2.xer_decoder;
td->xer_encoder = asn_DEF_T2.xer_encoder;
td->elements = asn_DEF_T2.elements;
td->elements_count = asn_DEF_T2.elements_count;
td->specifics = asn_DEF_T2.specifics;
}
void
T1_free(asn1_TYPE_descriptor_t *td,
T1_free(asn_TYPE_descriptor_t *td,
void *struct_ptr, int contents_only) {
T1_inherit_TYPE_descriptor(td);
td->free_struct(td, struct_ptr, contents_only);
}
int
T1_print(asn1_TYPE_descriptor_t *td, const void *struct_ptr,
T1_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
T1_inherit_TYPE_descriptor(td);
return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
}
ber_dec_rval_t
T1_decode_ber(asn1_TYPE_descriptor_t *td,
T1_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
void **structure, void *bufptr, size_t size, int tag_mode) {
T1_inherit_TYPE_descriptor(td);
return td->ber_decoder(td, structure, bufptr, size, tag_mode);
return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
}
asn_enc_rval_t
T1_encode_der(asn1_TYPE_descriptor_t *td,
T1_encode_der(asn_TYPE_descriptor_t *td,
void *structure, int tag_mode, ber_tlv_tag_t tag,
asn_app_consume_bytes_f *cb, void *app_key) {
T1_inherit_TYPE_descriptor(td);
@ -75,7 +75,7 @@ T1_encode_der(asn1_TYPE_descriptor_t *td,
}
asn_enc_rval_t
T1_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
T1_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
int ilevel, enum xer_encoder_flags_e flags,
asn_app_consume_bytes_f *cb, void *app_key) {
T1_inherit_TYPE_descriptor(td);
@ -85,13 +85,13 @@ T1_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
/*** <<< STAT-DEFS [T1] >>> ***/
static ber_tlv_tag_t asn1_DEF_T1_tags[] = {
static ber_tlv_tag_t asn_DEF_T1_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (2 << 2)),
(ASN_TAG_CLASS_CONTEXT | (3 << 2)),
(ASN_TAG_CLASS_CONTEXT | (4 << 2)),
(ASN_TAG_CLASS_CONTEXT | (6 << 2))
};
static ber_tlv_tag_t asn1_DEF_T1_all_tags[] = {
static ber_tlv_tag_t asn_DEF_T1_all_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (2 << 2)),
(ASN_TAG_CLASS_CONTEXT | (3 << 2)),
(ASN_TAG_CLASS_CONTEXT | (4 << 2)),
@ -99,7 +99,7 @@ static ber_tlv_tag_t asn1_DEF_T1_all_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (6 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (9 << 2))
};
asn1_TYPE_descriptor_t asn1_DEF_T1 = {
asn_TYPE_descriptor_t asn_DEF_T1 = {
"T1",
T1_free,
T1_print,
@ -109,12 +109,12 @@ asn1_TYPE_descriptor_t asn1_DEF_T1 = {
0, /* Not implemented yet */
T1_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T1_tags,
sizeof(asn1_DEF_T1_tags)
/sizeof(asn1_DEF_T1_tags[0]), /* 4 */
asn1_DEF_T1_all_tags,
sizeof(asn1_DEF_T1_all_tags)
/sizeof(asn1_DEF_T1_all_tags[0]), /* 6 */
asn_DEF_T1_tags,
sizeof(asn_DEF_T1_tags)
/sizeof(asn_DEF_T1_tags[0]), /* 4 */
asn_DEF_T1_all_tags,
sizeof(asn_DEF_T1_all_tags)
/sizeof(asn_DEF_T1_all_tags[0]), /* 6 */
0, 0, /* No members */
0 /* No specifics */
};
@ -131,7 +131,7 @@ typedef T3_t T2_t;
/*** <<< FUNC-DECLS [T2] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T2;
extern asn_TYPE_descriptor_t asn_DEF_T2;
asn_struct_free_f T2_free;
asn_struct_print_f T2_print;
asn_constr_check_f T2_constraint;
@ -142,10 +142,10 @@ xer_type_encoder_f T2_encode_xer;
/*** <<< CODE [T2] >>> ***/
int
T2_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
T2_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
/* Replace with underlying type checker */
td->check_constraints = asn1_DEF_T3.check_constraints;
td->check_constraints = asn_DEF_T3.check_constraints;
return td->check_constraints(td, sptr, app_errlog, app_key);
}
@ -154,41 +154,41 @@ T2_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
* so here we adjust the DEF accordingly.
*/
static void
T2_inherit_TYPE_descriptor(asn1_TYPE_descriptor_t *td) {
td->free_struct = asn1_DEF_T3.free_struct;
td->print_struct = asn1_DEF_T3.print_struct;
td->ber_decoder = asn1_DEF_T3.ber_decoder;
td->der_encoder = asn1_DEF_T3.der_encoder;
td->xer_decoder = asn1_DEF_T3.xer_decoder;
td->xer_encoder = asn1_DEF_T3.xer_encoder;
td->elements = asn1_DEF_T3.elements;
td->elements_count = asn1_DEF_T3.elements_count;
td->specifics = asn1_DEF_T3.specifics;
T2_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
td->free_struct = asn_DEF_T3.free_struct;
td->print_struct = asn_DEF_T3.print_struct;
td->ber_decoder = asn_DEF_T3.ber_decoder;
td->der_encoder = asn_DEF_T3.der_encoder;
td->xer_decoder = asn_DEF_T3.xer_decoder;
td->xer_encoder = asn_DEF_T3.xer_encoder;
td->elements = asn_DEF_T3.elements;
td->elements_count = asn_DEF_T3.elements_count;
td->specifics = asn_DEF_T3.specifics;
}
void
T2_free(asn1_TYPE_descriptor_t *td,
T2_free(asn_TYPE_descriptor_t *td,
void *struct_ptr, int contents_only) {
T2_inherit_TYPE_descriptor(td);
td->free_struct(td, struct_ptr, contents_only);
}
int
T2_print(asn1_TYPE_descriptor_t *td, const void *struct_ptr,
T2_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
T2_inherit_TYPE_descriptor(td);
return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
}
ber_dec_rval_t
T2_decode_ber(asn1_TYPE_descriptor_t *td,
T2_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
void **structure, void *bufptr, size_t size, int tag_mode) {
T2_inherit_TYPE_descriptor(td);
return td->ber_decoder(td, structure, bufptr, size, tag_mode);
return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
}
asn_enc_rval_t
T2_encode_der(asn1_TYPE_descriptor_t *td,
T2_encode_der(asn_TYPE_descriptor_t *td,
void *structure, int tag_mode, ber_tlv_tag_t tag,
asn_app_consume_bytes_f *cb, void *app_key) {
T2_inherit_TYPE_descriptor(td);
@ -196,7 +196,7 @@ T2_encode_der(asn1_TYPE_descriptor_t *td,
}
asn_enc_rval_t
T2_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
T2_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
int ilevel, enum xer_encoder_flags_e flags,
asn_app_consume_bytes_f *cb, void *app_key) {
T2_inherit_TYPE_descriptor(td);
@ -206,19 +206,19 @@ T2_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
/*** <<< STAT-DEFS [T2] >>> ***/
static ber_tlv_tag_t asn1_DEF_T2_tags[] = {
static ber_tlv_tag_t asn_DEF_T2_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (3 << 2)),
(ASN_TAG_CLASS_CONTEXT | (4 << 2)),
(ASN_TAG_CLASS_CONTEXT | (6 << 2))
};
static ber_tlv_tag_t asn1_DEF_T2_all_tags[] = {
static ber_tlv_tag_t asn_DEF_T2_all_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (3 << 2)),
(ASN_TAG_CLASS_CONTEXT | (4 << 2)),
(ASN_TAG_CLASS_CONTEXT | (5 << 2)),
(ASN_TAG_CLASS_CONTEXT | (6 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (9 << 2))
};
asn1_TYPE_descriptor_t asn1_DEF_T2 = {
asn_TYPE_descriptor_t asn_DEF_T2 = {
"T2",
T2_free,
T2_print,
@ -228,12 +228,12 @@ asn1_TYPE_descriptor_t asn1_DEF_T2 = {
0, /* Not implemented yet */
T2_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T2_tags,
sizeof(asn1_DEF_T2_tags)
/sizeof(asn1_DEF_T2_tags[0]), /* 3 */
asn1_DEF_T2_all_tags,
sizeof(asn1_DEF_T2_all_tags)
/sizeof(asn1_DEF_T2_all_tags[0]), /* 5 */
asn_DEF_T2_tags,
sizeof(asn_DEF_T2_tags)
/sizeof(asn_DEF_T2_tags[0]), /* 3 */
asn_DEF_T2_all_tags,
sizeof(asn_DEF_T2_all_tags)
/sizeof(asn_DEF_T2_all_tags[0]), /* 5 */
0, 0, /* No members */
0 /* No specifics */
};
@ -250,7 +250,7 @@ typedef T4_t T3_t;
/*** <<< FUNC-DECLS [T3] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T3;
extern asn_TYPE_descriptor_t asn_DEF_T3;
asn_struct_free_f T3_free;
asn_struct_print_f T3_print;
asn_constr_check_f T3_constraint;
@ -261,10 +261,10 @@ xer_type_encoder_f T3_encode_xer;
/*** <<< CODE [T3] >>> ***/
int
T3_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
T3_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
/* Replace with underlying type checker */
td->check_constraints = asn1_DEF_T4.check_constraints;
td->check_constraints = asn_DEF_T4.check_constraints;
return td->check_constraints(td, sptr, app_errlog, app_key);
}
@ -273,41 +273,41 @@ T3_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
* so here we adjust the DEF accordingly.
*/
static void
T3_inherit_TYPE_descriptor(asn1_TYPE_descriptor_t *td) {
td->free_struct = asn1_DEF_T4.free_struct;
td->print_struct = asn1_DEF_T4.print_struct;
td->ber_decoder = asn1_DEF_T4.ber_decoder;
td->der_encoder = asn1_DEF_T4.der_encoder;
td->xer_decoder = asn1_DEF_T4.xer_decoder;
td->xer_encoder = asn1_DEF_T4.xer_encoder;
td->elements = asn1_DEF_T4.elements;
td->elements_count = asn1_DEF_T4.elements_count;
td->specifics = asn1_DEF_T4.specifics;
T3_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
td->free_struct = asn_DEF_T4.free_struct;
td->print_struct = asn_DEF_T4.print_struct;
td->ber_decoder = asn_DEF_T4.ber_decoder;
td->der_encoder = asn_DEF_T4.der_encoder;
td->xer_decoder = asn_DEF_T4.xer_decoder;
td->xer_encoder = asn_DEF_T4.xer_encoder;
td->elements = asn_DEF_T4.elements;
td->elements_count = asn_DEF_T4.elements_count;
td->specifics = asn_DEF_T4.specifics;
}
void
T3_free(asn1_TYPE_descriptor_t *td,
T3_free(asn_TYPE_descriptor_t *td,
void *struct_ptr, int contents_only) {
T3_inherit_TYPE_descriptor(td);
td->free_struct(td, struct_ptr, contents_only);
}
int
T3_print(asn1_TYPE_descriptor_t *td, const void *struct_ptr,
T3_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
T3_inherit_TYPE_descriptor(td);
return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
}
ber_dec_rval_t
T3_decode_ber(asn1_TYPE_descriptor_t *td,
T3_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
void **structure, void *bufptr, size_t size, int tag_mode) {
T3_inherit_TYPE_descriptor(td);
return td->ber_decoder(td, structure, bufptr, size, tag_mode);
return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
}
asn_enc_rval_t
T3_encode_der(asn1_TYPE_descriptor_t *td,
T3_encode_der(asn_TYPE_descriptor_t *td,
void *structure, int tag_mode, ber_tlv_tag_t tag,
asn_app_consume_bytes_f *cb, void *app_key) {
T3_inherit_TYPE_descriptor(td);
@ -315,7 +315,7 @@ T3_encode_der(asn1_TYPE_descriptor_t *td,
}
asn_enc_rval_t
T3_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
T3_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
int ilevel, enum xer_encoder_flags_e flags,
asn_app_consume_bytes_f *cb, void *app_key) {
T3_inherit_TYPE_descriptor(td);
@ -325,17 +325,17 @@ T3_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
/*** <<< STAT-DEFS [T3] >>> ***/
static ber_tlv_tag_t asn1_DEF_T3_tags[] = {
static ber_tlv_tag_t asn_DEF_T3_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (4 << 2)),
(ASN_TAG_CLASS_CONTEXT | (6 << 2))
};
static ber_tlv_tag_t asn1_DEF_T3_all_tags[] = {
static ber_tlv_tag_t asn_DEF_T3_all_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (4 << 2)),
(ASN_TAG_CLASS_CONTEXT | (5 << 2)),
(ASN_TAG_CLASS_CONTEXT | (6 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (9 << 2))
};
asn1_TYPE_descriptor_t asn1_DEF_T3 = {
asn_TYPE_descriptor_t asn_DEF_T3 = {
"T3",
T3_free,
T3_print,
@ -345,12 +345,12 @@ asn1_TYPE_descriptor_t asn1_DEF_T3 = {
0, /* Not implemented yet */
T3_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T3_tags,
sizeof(asn1_DEF_T3_tags)
/sizeof(asn1_DEF_T3_tags[0]), /* 2 */
asn1_DEF_T3_all_tags,
sizeof(asn1_DEF_T3_all_tags)
/sizeof(asn1_DEF_T3_all_tags[0]), /* 4 */
asn_DEF_T3_tags,
sizeof(asn_DEF_T3_tags)
/sizeof(asn_DEF_T3_tags[0]), /* 2 */
asn_DEF_T3_all_tags,
sizeof(asn_DEF_T3_all_tags)
/sizeof(asn_DEF_T3_all_tags[0]), /* 4 */
0, 0, /* No members */
0 /* No specifics */
};
@ -367,7 +367,7 @@ typedef T5_t T4_t;
/*** <<< FUNC-DECLS [T4] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T4;
extern asn_TYPE_descriptor_t asn_DEF_T4;
asn_struct_free_f T4_free;
asn_struct_print_f T4_print;
asn_constr_check_f T4_constraint;
@ -378,10 +378,10 @@ xer_type_encoder_f T4_encode_xer;
/*** <<< CODE [T4] >>> ***/
int
T4_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
T4_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
/* Replace with underlying type checker */
td->check_constraints = asn1_DEF_T5.check_constraints;
td->check_constraints = asn_DEF_T5.check_constraints;
return td->check_constraints(td, sptr, app_errlog, app_key);
}
@ -390,41 +390,41 @@ T4_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
* so here we adjust the DEF accordingly.
*/
static void
T4_inherit_TYPE_descriptor(asn1_TYPE_descriptor_t *td) {
td->free_struct = asn1_DEF_T5.free_struct;
td->print_struct = asn1_DEF_T5.print_struct;
td->ber_decoder = asn1_DEF_T5.ber_decoder;
td->der_encoder = asn1_DEF_T5.der_encoder;
td->xer_decoder = asn1_DEF_T5.xer_decoder;
td->xer_encoder = asn1_DEF_T5.xer_encoder;
td->elements = asn1_DEF_T5.elements;
td->elements_count = asn1_DEF_T5.elements_count;
td->specifics = asn1_DEF_T5.specifics;
T4_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
td->free_struct = asn_DEF_T5.free_struct;
td->print_struct = asn_DEF_T5.print_struct;
td->ber_decoder = asn_DEF_T5.ber_decoder;
td->der_encoder = asn_DEF_T5.der_encoder;
td->xer_decoder = asn_DEF_T5.xer_decoder;
td->xer_encoder = asn_DEF_T5.xer_encoder;
td->elements = asn_DEF_T5.elements;
td->elements_count = asn_DEF_T5.elements_count;
td->specifics = asn_DEF_T5.specifics;
}
void
T4_free(asn1_TYPE_descriptor_t *td,
T4_free(asn_TYPE_descriptor_t *td,
void *struct_ptr, int contents_only) {
T4_inherit_TYPE_descriptor(td);
td->free_struct(td, struct_ptr, contents_only);
}
int
T4_print(asn1_TYPE_descriptor_t *td, const void *struct_ptr,
T4_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
T4_inherit_TYPE_descriptor(td);
return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
}
ber_dec_rval_t
T4_decode_ber(asn1_TYPE_descriptor_t *td,
T4_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
void **structure, void *bufptr, size_t size, int tag_mode) {
T4_inherit_TYPE_descriptor(td);
return td->ber_decoder(td, structure, bufptr, size, tag_mode);
return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
}
asn_enc_rval_t
T4_encode_der(asn1_TYPE_descriptor_t *td,
T4_encode_der(asn_TYPE_descriptor_t *td,
void *structure, int tag_mode, ber_tlv_tag_t tag,
asn_app_consume_bytes_f *cb, void *app_key) {
T4_inherit_TYPE_descriptor(td);
@ -432,7 +432,7 @@ T4_encode_der(asn1_TYPE_descriptor_t *td,
}
asn_enc_rval_t
T4_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
T4_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
int ilevel, enum xer_encoder_flags_e flags,
asn_app_consume_bytes_f *cb, void *app_key) {
T4_inherit_TYPE_descriptor(td);
@ -442,12 +442,12 @@ T4_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
/*** <<< STAT-DEFS [T4] >>> ***/
static ber_tlv_tag_t asn1_DEF_T4_tags[] = {
static ber_tlv_tag_t asn_DEF_T4_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (5 << 2)),
(ASN_TAG_CLASS_CONTEXT | (6 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (9 << 2))
};
asn1_TYPE_descriptor_t asn1_DEF_T4 = {
asn_TYPE_descriptor_t asn_DEF_T4 = {
"T4",
T4_free,
T4_print,
@ -457,12 +457,12 @@ asn1_TYPE_descriptor_t asn1_DEF_T4 = {
0, /* Not implemented yet */
T4_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T4_tags,
sizeof(asn1_DEF_T4_tags)
/sizeof(asn1_DEF_T4_tags[0]) - 1, /* 2 */
asn1_DEF_T4_tags, /* Same as above */
sizeof(asn1_DEF_T4_tags)
/sizeof(asn1_DEF_T4_tags[0]), /* 3 */
asn_DEF_T4_tags,
sizeof(asn_DEF_T4_tags)
/sizeof(asn_DEF_T4_tags[0]) - 1, /* 2 */
asn_DEF_T4_tags, /* Same as above */
sizeof(asn_DEF_T4_tags)
/sizeof(asn_DEF_T4_tags[0]), /* 3 */
0, 0, /* No members */
0 /* No specifics */
};
@ -479,7 +479,7 @@ typedef T6_t T5_t;
/*** <<< FUNC-DECLS [T5] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T5;
extern asn_TYPE_descriptor_t asn_DEF_T5;
asn_struct_free_f T5_free;
asn_struct_print_f T5_print;
asn_constr_check_f T5_constraint;
@ -490,10 +490,10 @@ xer_type_encoder_f T5_encode_xer;
/*** <<< CODE [T5] >>> ***/
int
T5_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
T5_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
/* Replace with underlying type checker */
td->check_constraints = asn1_DEF_T6.check_constraints;
td->check_constraints = asn_DEF_T6.check_constraints;
return td->check_constraints(td, sptr, app_errlog, app_key);
}
@ -502,41 +502,41 @@ T5_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
* so here we adjust the DEF accordingly.
*/
static void
T5_inherit_TYPE_descriptor(asn1_TYPE_descriptor_t *td) {
td->free_struct = asn1_DEF_T6.free_struct;
td->print_struct = asn1_DEF_T6.print_struct;
td->ber_decoder = asn1_DEF_T6.ber_decoder;
td->der_encoder = asn1_DEF_T6.der_encoder;
td->xer_decoder = asn1_DEF_T6.xer_decoder;
td->xer_encoder = asn1_DEF_T6.xer_encoder;
td->elements = asn1_DEF_T6.elements;
td->elements_count = asn1_DEF_T6.elements_count;
td->specifics = asn1_DEF_T6.specifics;
T5_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
td->free_struct = asn_DEF_T6.free_struct;
td->print_struct = asn_DEF_T6.print_struct;
td->ber_decoder = asn_DEF_T6.ber_decoder;
td->der_encoder = asn_DEF_T6.der_encoder;
td->xer_decoder = asn_DEF_T6.xer_decoder;
td->xer_encoder = asn_DEF_T6.xer_encoder;
td->elements = asn_DEF_T6.elements;
td->elements_count = asn_DEF_T6.elements_count;
td->specifics = asn_DEF_T6.specifics;
}
void
T5_free(asn1_TYPE_descriptor_t *td,
T5_free(asn_TYPE_descriptor_t *td,
void *struct_ptr, int contents_only) {
T5_inherit_TYPE_descriptor(td);
td->free_struct(td, struct_ptr, contents_only);
}
int
T5_print(asn1_TYPE_descriptor_t *td, const void *struct_ptr,
T5_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
T5_inherit_TYPE_descriptor(td);
return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
}
ber_dec_rval_t
T5_decode_ber(asn1_TYPE_descriptor_t *td,
T5_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
void **structure, void *bufptr, size_t size, int tag_mode) {
T5_inherit_TYPE_descriptor(td);
return td->ber_decoder(td, structure, bufptr, size, tag_mode);
return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
}
asn_enc_rval_t
T5_encode_der(asn1_TYPE_descriptor_t *td,
T5_encode_der(asn_TYPE_descriptor_t *td,
void *structure, int tag_mode, ber_tlv_tag_t tag,
asn_app_consume_bytes_f *cb, void *app_key) {
T5_inherit_TYPE_descriptor(td);
@ -544,7 +544,7 @@ T5_encode_der(asn1_TYPE_descriptor_t *td,
}
asn_enc_rval_t
T5_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
T5_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
int ilevel, enum xer_encoder_flags_e flags,
asn_app_consume_bytes_f *cb, void *app_key) {
T5_inherit_TYPE_descriptor(td);
@ -554,11 +554,11 @@ T5_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
/*** <<< STAT-DEFS [T5] >>> ***/
static ber_tlv_tag_t asn1_DEF_T5_tags[] = {
static ber_tlv_tag_t asn_DEF_T5_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (6 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (9 << 2))
};
asn1_TYPE_descriptor_t asn1_DEF_T5 = {
asn_TYPE_descriptor_t asn_DEF_T5 = {
"T5",
T5_free,
T5_print,
@ -568,12 +568,12 @@ asn1_TYPE_descriptor_t asn1_DEF_T5 = {
0, /* Not implemented yet */
T5_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T5_tags,
sizeof(asn1_DEF_T5_tags)
/sizeof(asn1_DEF_T5_tags[0]) - 1, /* 1 */
asn1_DEF_T5_tags, /* Same as above */
sizeof(asn1_DEF_T5_tags)
/sizeof(asn1_DEF_T5_tags[0]), /* 2 */
asn_DEF_T5_tags,
sizeof(asn_DEF_T5_tags)
/sizeof(asn_DEF_T5_tags[0]) - 1, /* 1 */
asn_DEF_T5_tags, /* Same as above */
sizeof(asn_DEF_T5_tags)
/sizeof(asn_DEF_T5_tags[0]), /* 2 */
0, 0, /* No members */
0 /* No specifics */
};
@ -591,7 +591,7 @@ typedef double T6_t;
/*** <<< FUNC-DECLS [T6] >>> ***/
/* This type is equivalent to NativeReal */
#define asn1_DEF_T6 asn1_DEF_NativeReal
#define asn_DEF_T6 asn_DEF_NativeReal
/*** <<< CODE [T6] >>> ***/
@ -609,7 +609,7 @@ typedef Ts_t T_t;
/*** <<< FUNC-DECLS [T] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T;
extern asn_TYPE_descriptor_t asn_DEF_T;
asn_struct_free_f T_free;
asn_struct_print_f T_print;
asn_constr_check_f T_constraint;
@ -620,10 +620,10 @@ xer_type_encoder_f T_encode_xer;
/*** <<< CODE [T] >>> ***/
int
T_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
T_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
/* Replace with underlying type checker */
td->check_constraints = asn1_DEF_Ts.check_constraints;
td->check_constraints = asn_DEF_Ts.check_constraints;
return td->check_constraints(td, sptr, app_errlog, app_key);
}
@ -632,41 +632,41 @@ T_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
* so here we adjust the DEF accordingly.
*/
static void
T_inherit_TYPE_descriptor(asn1_TYPE_descriptor_t *td) {
td->free_struct = asn1_DEF_Ts.free_struct;
td->print_struct = asn1_DEF_Ts.print_struct;
td->ber_decoder = asn1_DEF_Ts.ber_decoder;
td->der_encoder = asn1_DEF_Ts.der_encoder;
td->xer_decoder = asn1_DEF_Ts.xer_decoder;
td->xer_encoder = asn1_DEF_Ts.xer_encoder;
td->elements = asn1_DEF_Ts.elements;
td->elements_count = asn1_DEF_Ts.elements_count;
td->specifics = asn1_DEF_Ts.specifics;
T_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
td->free_struct = asn_DEF_Ts.free_struct;
td->print_struct = asn_DEF_Ts.print_struct;
td->ber_decoder = asn_DEF_Ts.ber_decoder;
td->der_encoder = asn_DEF_Ts.der_encoder;
td->xer_decoder = asn_DEF_Ts.xer_decoder;
td->xer_encoder = asn_DEF_Ts.xer_encoder;
td->elements = asn_DEF_Ts.elements;
td->elements_count = asn_DEF_Ts.elements_count;
td->specifics = asn_DEF_Ts.specifics;
}
void
T_free(asn1_TYPE_descriptor_t *td,
T_free(asn_TYPE_descriptor_t *td,
void *struct_ptr, int contents_only) {
T_inherit_TYPE_descriptor(td);
td->free_struct(td, struct_ptr, contents_only);
}
int
T_print(asn1_TYPE_descriptor_t *td, const void *struct_ptr,
T_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
T_inherit_TYPE_descriptor(td);
return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
}
ber_dec_rval_t
T_decode_ber(asn1_TYPE_descriptor_t *td,
T_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
void **structure, void *bufptr, size_t size, int tag_mode) {
T_inherit_TYPE_descriptor(td);
return td->ber_decoder(td, structure, bufptr, size, tag_mode);
return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
}
asn_enc_rval_t
T_encode_der(asn1_TYPE_descriptor_t *td,
T_encode_der(asn_TYPE_descriptor_t *td,
void *structure, int tag_mode, ber_tlv_tag_t tag,
asn_app_consume_bytes_f *cb, void *app_key) {
T_inherit_TYPE_descriptor(td);
@ -674,7 +674,7 @@ T_encode_der(asn1_TYPE_descriptor_t *td,
}
asn_enc_rval_t
T_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
T_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
int ilevel, enum xer_encoder_flags_e flags,
asn_app_consume_bytes_f *cb, void *app_key) {
T_inherit_TYPE_descriptor(td);
@ -684,12 +684,12 @@ T_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
/*** <<< STAT-DEFS [T] >>> ***/
static ber_tlv_tag_t asn1_DEF_T_tags[] = {
static ber_tlv_tag_t asn_DEF_T_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (0 << 2)),
(ASN_TAG_CLASS_CONTEXT | (123 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
asn1_TYPE_descriptor_t asn1_DEF_T = {
asn_TYPE_descriptor_t asn_DEF_T = {
"T",
T_free,
T_print,
@ -699,12 +699,12 @@ asn1_TYPE_descriptor_t asn1_DEF_T = {
0, /* Not implemented yet */
T_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T_tags,
sizeof(asn1_DEF_T_tags)
/sizeof(asn1_DEF_T_tags[0]) - 2, /* 1 */
asn1_DEF_T_tags, /* Same as above */
sizeof(asn1_DEF_T_tags)
/sizeof(asn1_DEF_T_tags[0]), /* 3 */
asn_DEF_T_tags,
sizeof(asn_DEF_T_tags)
/sizeof(asn_DEF_T_tags[0]) - 2, /* 1 */
asn_DEF_T_tags, /* Same as above */
sizeof(asn_DEF_T_tags)
/sizeof(asn_DEF_T_tags[0]), /* 3 */
0, 0, /* Defined elsewhere */
0 /* No specifics */
};
@ -718,7 +718,7 @@ asn1_TYPE_descriptor_t asn1_DEF_T = {
/*** <<< DEPS [Ts] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_Ts;
extern asn_TYPE_descriptor_t asn_DEF_Ts;
/*** <<< TYPE-DECLS [Ts] >>> ***/
@ -729,52 +729,52 @@ typedef struct Ts {
T3_t m3;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} Ts_t;
/*** <<< STAT-DEFS [Ts] >>> ***/
static asn1_TYPE_member_t asn1_MBR_Ts[] = {
static asn_TYPE_member_t asn_MBR_Ts[] = {
{ ATF_NOFLAGS, 0, offsetof(struct Ts, m1),
.tag = (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_T2,
.type = (void *)&asn_DEF_T2,
.memb_constraints = 0, /* Defer to actual type */
.name = "m1"
},
{ ATF_POINTER, 1, offsetof(struct Ts, m2),
.tag = (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
.tag_mode = +1, /* EXPLICIT tag at current level */
.type = (void *)&asn1_DEF_T3,
.type = (void *)&asn_DEF_T3,
.memb_constraints = 0, /* Defer to actual type */
.name = "m2"
},
{ ATF_NOFLAGS, 0, offsetof(struct Ts, m3),
.tag = (ASN_TAG_CLASS_CONTEXT | (3 << 2)),
.tag_mode = -1, /* IMPLICIT tag at current level */
.type = (void *)&asn1_DEF_T3,
.type = (void *)&asn_DEF_T3,
.memb_constraints = 0, /* Defer to actual type */
.name = "m3"
},
};
static ber_tlv_tag_t asn1_DEF_Ts_tags[] = {
static ber_tlv_tag_t asn_DEF_Ts_tags[] = {
(ASN_TAG_CLASS_CONTEXT | (123 << 2)),
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static asn1_TYPE_tag2member_t asn1_DEF_Ts_tag2el[] = {
static asn_TYPE_tag2member_t asn_DEF_Ts_tag2el[] = {
{ (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 0, 0, 0 }, /* m1 at 24 */
{ (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 1, 0, 0 }, /* m2 at 25 */
{ (ASN_TAG_CLASS_CONTEXT | (3 << 2)), 2, 0, 0 }, /* m3 at 27 */
};
static asn1_SEQUENCE_specifics_t asn1_DEF_Ts_specs = {
static asn_SEQUENCE_specifics_t asn_DEF_Ts_specs = {
sizeof(struct Ts),
offsetof(struct Ts, _ber_dec_ctx),
asn1_DEF_Ts_tag2el,
offsetof(struct Ts, _asn_ctx),
asn_DEF_Ts_tag2el,
3, /* Count of tags in the map */
-1, /* Start extensions */
-1 /* Stop extensions */
};
asn1_TYPE_descriptor_t asn1_DEF_Ts = {
asn_TYPE_descriptor_t asn_DEF_Ts = {
"Ts",
SEQUENCE_free,
SEQUENCE_print,
@ -784,14 +784,14 @@ asn1_TYPE_descriptor_t asn1_DEF_Ts = {
0, /* Not implemented yet */
SEQUENCE_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_Ts_tags,
sizeof(asn1_DEF_Ts_tags)
/sizeof(asn1_DEF_Ts_tags[0]) - 1, /* 1 */
asn1_DEF_Ts_tags, /* Same as above */
sizeof(asn1_DEF_Ts_tags)
/sizeof(asn1_DEF_Ts_tags[0]), /* 2 */
asn1_MBR_Ts,
asn_DEF_Ts_tags,
sizeof(asn_DEF_Ts_tags)
/sizeof(asn_DEF_Ts_tags[0]) - 1, /* 1 */
asn_DEF_Ts_tags, /* Same as above */
sizeof(asn_DEF_Ts_tags)
/sizeof(asn_DEF_Ts_tags[0]), /* 2 */
asn_MBR_Ts,
3, /* Elements count */
&asn1_DEF_Ts_specs /* Additional specs */
&asn_DEF_Ts_specs /* Additional specs */
};

View File

@ -7,7 +7,7 @@
/*** <<< DEPS [T] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_T;
extern asn_TYPE_descriptor_t asn_DEF_T;
/*** <<< TYPE-DECLS [T] >>> ***/
@ -16,29 +16,29 @@ typedef struct T {
A_SET_OF(SimpleType_t) list;
/* Context for parsing across buffer boundaries */
ber_dec_ctx_t _ber_dec_ctx;
asn_struct_ctx_t _asn_ctx;
} T_t;
/*** <<< STAT-DEFS [T] >>> ***/
static asn1_TYPE_member_t asn1_MBR_T[] = {
static asn_TYPE_member_t asn_MBR_T[] = {
{ ATF_NOFLAGS, 0, 0,
.tag = (ASN_TAG_CLASS_UNIVERSAL | (10 << 2)),
.tag_mode = 0,
.type = (void *)&asn1_DEF_SimpleType,
.type = (void *)&asn_DEF_SimpleType,
.memb_constraints = 0, /* Defer to actual type */
.name = ""
},
};
static ber_tlv_tag_t asn1_DEF_T_tags[] = {
static ber_tlv_tag_t asn_DEF_T_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
};
static asn1_SET_OF_specifics_t asn1_DEF_T_specs = {
static asn_SET_OF_specifics_t asn_DEF_T_specs = {
sizeof(struct T),
offsetof(struct T, _ber_dec_ctx),
offsetof(struct T, _asn_ctx),
1, /* XER encoding is XMLValueList */
};
asn1_TYPE_descriptor_t asn1_DEF_T = {
asn_TYPE_descriptor_t asn_DEF_T = {
"T",
SET_OF_free,
SET_OF_print,
@ -48,15 +48,15 @@ asn1_TYPE_descriptor_t asn1_DEF_T = {
0, /* Not implemented yet */
SET_OF_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_T_tags,
sizeof(asn1_DEF_T_tags)
/sizeof(asn1_DEF_T_tags[0]), /* 1 */
asn1_DEF_T_tags, /* Same as above */
sizeof(asn1_DEF_T_tags)
/sizeof(asn1_DEF_T_tags[0]), /* 1 */
asn1_MBR_T,
asn_DEF_T_tags,
sizeof(asn_DEF_T_tags)
/sizeof(asn_DEF_T_tags[0]), /* 1 */
asn_DEF_T_tags, /* Same as above */
sizeof(asn_DEF_T_tags)
/sizeof(asn_DEF_T_tags[0]), /* 1 */
asn_MBR_T,
1, /* Single element */
&asn1_DEF_T_specs /* Additional specs */
&asn_DEF_T_specs /* Additional specs */
};
@ -79,7 +79,7 @@ typedef ENUMERATED_t SimpleType_t;
/*** <<< FUNC-DECLS [SimpleType] >>> ***/
extern asn1_TYPE_descriptor_t asn1_DEF_SimpleType;
extern asn_TYPE_descriptor_t asn_DEF_SimpleType;
asn_struct_free_f SimpleType_free;
asn_struct_print_f SimpleType_print;
asn_constr_check_f SimpleType_constraint;
@ -90,10 +90,10 @@ xer_type_encoder_f SimpleType_encode_xer;
/*** <<< CODE [SimpleType] >>> ***/
int
SimpleType_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
SimpleType_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
asn_app_consume_bytes_f *app_errlog, void *app_key) {
/* Replace with underlying type checker */
td->check_constraints = asn1_DEF_ENUMERATED.check_constraints;
td->check_constraints = asn_DEF_ENUMERATED.check_constraints;
return td->check_constraints(td, sptr, app_errlog, app_key);
}
@ -102,41 +102,41 @@ SimpleType_constraint(asn1_TYPE_descriptor_t *td, const void *sptr,
* so here we adjust the DEF accordingly.
*/
static void
SimpleType_inherit_TYPE_descriptor(asn1_TYPE_descriptor_t *td) {
td->free_struct = asn1_DEF_ENUMERATED.free_struct;
td->print_struct = asn1_DEF_ENUMERATED.print_struct;
td->ber_decoder = asn1_DEF_ENUMERATED.ber_decoder;
td->der_encoder = asn1_DEF_ENUMERATED.der_encoder;
td->xer_decoder = asn1_DEF_ENUMERATED.xer_decoder;
td->xer_encoder = asn1_DEF_ENUMERATED.xer_encoder;
td->elements = asn1_DEF_ENUMERATED.elements;
td->elements_count = asn1_DEF_ENUMERATED.elements_count;
td->specifics = asn1_DEF_ENUMERATED.specifics;
SimpleType_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
td->free_struct = asn_DEF_ENUMERATED.free_struct;
td->print_struct = asn_DEF_ENUMERATED.print_struct;
td->ber_decoder = asn_DEF_ENUMERATED.ber_decoder;
td->der_encoder = asn_DEF_ENUMERATED.der_encoder;
td->xer_decoder = asn_DEF_ENUMERATED.xer_decoder;
td->xer_encoder = asn_DEF_ENUMERATED.xer_encoder;
td->elements = asn_DEF_ENUMERATED.elements;
td->elements_count = asn_DEF_ENUMERATED.elements_count;
td->specifics = asn_DEF_ENUMERATED.specifics;
}
void
SimpleType_free(asn1_TYPE_descriptor_t *td,
SimpleType_free(asn_TYPE_descriptor_t *td,
void *struct_ptr, int contents_only) {
SimpleType_inherit_TYPE_descriptor(td);
td->free_struct(td, struct_ptr, contents_only);
}
int
SimpleType_print(asn1_TYPE_descriptor_t *td, const void *struct_ptr,
SimpleType_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
SimpleType_inherit_TYPE_descriptor(td);
return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
}
ber_dec_rval_t
SimpleType_decode_ber(asn1_TYPE_descriptor_t *td,
SimpleType_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
void **structure, void *bufptr, size_t size, int tag_mode) {
SimpleType_inherit_TYPE_descriptor(td);
return td->ber_decoder(td, structure, bufptr, size, tag_mode);
return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
}
asn_enc_rval_t
SimpleType_encode_der(asn1_TYPE_descriptor_t *td,
SimpleType_encode_der(asn_TYPE_descriptor_t *td,
void *structure, int tag_mode, ber_tlv_tag_t tag,
asn_app_consume_bytes_f *cb, void *app_key) {
SimpleType_inherit_TYPE_descriptor(td);
@ -144,7 +144,7 @@ SimpleType_encode_der(asn1_TYPE_descriptor_t *td,
}
asn_enc_rval_t
SimpleType_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
SimpleType_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
int ilevel, enum xer_encoder_flags_e flags,
asn_app_consume_bytes_f *cb, void *app_key) {
SimpleType_inherit_TYPE_descriptor(td);
@ -154,10 +154,10 @@ SimpleType_encode_xer(asn1_TYPE_descriptor_t *td, void *structure,
/*** <<< STAT-DEFS [SimpleType] >>> ***/
static ber_tlv_tag_t asn1_DEF_SimpleType_tags[] = {
static ber_tlv_tag_t asn_DEF_SimpleType_tags[] = {
(ASN_TAG_CLASS_UNIVERSAL | (10 << 2))
};
asn1_TYPE_descriptor_t asn1_DEF_SimpleType = {
asn_TYPE_descriptor_t asn_DEF_SimpleType = {
"SimpleType",
SimpleType_free,
SimpleType_print,
@ -167,12 +167,12 @@ asn1_TYPE_descriptor_t asn1_DEF_SimpleType = {
0, /* Not implemented yet */
SimpleType_encode_xer,
0, /* Use generic outmost tag fetcher */
asn1_DEF_SimpleType_tags,
sizeof(asn1_DEF_SimpleType_tags)
/sizeof(asn1_DEF_SimpleType_tags[0]), /* 1 */
asn1_DEF_SimpleType_tags, /* Same as above */
sizeof(asn1_DEF_SimpleType_tags)
/sizeof(asn1_DEF_SimpleType_tags[0]), /* 1 */
asn_DEF_SimpleType_tags,
sizeof(asn_DEF_SimpleType_tags)
/sizeof(asn_DEF_SimpleType_tags[0]), /* 1 */
asn_DEF_SimpleType_tags, /* Same as above */
sizeof(asn_DEF_SimpleType_tags)
/sizeof(asn_DEF_SimpleType_tags[0]), /* 1 */
0, 0, /* No members */
0 /* No specifics */
};