Open minfrin opened 4 years ago
You can read from asn1p_y.y, it does not support versionNumber:
inside [[ ]]
As a result of this bug, it is not possible for asn1c to parse the schemas from https://tools.ietf.org/html/rfc5912#section-14.
I'm seeing the same problem here, which makes it difficult to use asn1c to handle anything that depends on RFC 5912 as well.
@brchiu, do you have any suggestion for how to adapt asn1p_y.y
to support versionNumber
inside [[
and ]]
?
Looks like it has to do with TOK_VBracketLeft
and TOK_VBracketRight
, those only look usable in conjunction with ComponentTypeLists
, and i don't understand yacc/etc well enough to know how to add it.
When trying to parse PKIX1Explicit-2009.asn from https://github.com/P1sec/pycrate/blob/master/pycrate_asn1dir/IETF_PKI_RFC5911/PKIX1Explicit-2009.asn, the following error is thrown:
[minfrin@bob asn1]$ ~/src/asn1/asn1c-trunk/asn1c/asn1c -E -F ./tmp/pycrate-master/pycrate_asn1dir/IETF_PKI_RFC5911/PKIX1Explicit-2009.asn ASN.1 grammar parse error near ./tmp/pycrate-master/pycrate_asn1dir/IETF_PKI_RFC5911/PKIX1Explicit-2009.asn:263 (token "2"): syntax error, unexpected number Cannot parse "./tmp/pycrate-master/pycrate_asn1dir/IETF_PKI_RFC5911/PKIX1Explicit-2009.asn"
Is this a known issue?