Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix BMPString universal class; Add missing ASN.1 tags (14, 30-36) #67

Merged
merged 2 commits into from
Dec 9, 2022

Conversation

lvkv
Copy link
Contributor

@lvkv lvkv commented Dec 8, 2022

Tag::BMP_STRING is incorrectly assigned the class UNIVERSAL 29 instead of UNIVERSAL 30 1. Additionally, a number of universal class tag assignments are missing in tag.rs. This commit fixes addresses both of these issues alongside a few minor nitpicks.

All changes are to tag.rs:

  • Correctly assign UNIVERSAL 30 to Tag::BMP_STRING (BMPString)1
  • Correctly assign UNIVERSAL 29 to missing ASN.1 tag Tag::CHARACTER_STRING (CHARACTER STRING)2
  • Add missing ASN.1 tag Tag::TIME (TIME, UNIVERSAL 14)3
  • Add missing ASN.1 tag Tag::DATE (DATE, UNIVERSAL 31)34
  • Add missing ASN.1 tag Tag::TIME_OF_DAY (TIME-OF-DAY UNIVERSAL 32)34
  • Add missing ASN.1 tag Tag::DATE_TIME (DATE-TIME, UNIVERSAL 33)34
  • Add missing ASN.1 tag Tag::DURATION (DURATION, UNIVERSAL 34)34
  • Add missing ASN.1 tag Tag::OID_IRI (OID-IRI, UNIVERSAL 35)35
  • Add missing ASN.1 tag Tag::RELATIVE_OID_IRI (RELATIVE-OID-IRI, UNIVERSAL 36)36
  • Correct comment spelling (UNIVERAL ➡️ UNIVERSAL) for ENUMERATED, EMBEDDED_PDV, RELATIVE_OID and GENERALIZED_TIME
  • Remove trailing whitespace below LAST_OCTET_MASK

Thank you for bcder!

Footnotes

  1. ITU-T X.680 (02/2021) Table 8 – List of restricted character string types 2

  2. ITU-T X.680 (02/2021) 44 Definition of unrestricted character string types

  3. ITU-T X.680 (02/2021) Table 1 – Universal class tag assignments 2 3 4 5 6 7

  4. ITU-T X.680 (02/2021) 38.4 Useful time types 2 3 4

  5. ITU-T X.680 (02/2021) 34 Notation for the OID internationalized resource identifier type

  6. ITU-T X.680 (02/2021) 35 Notation for the relative OID internationalized resource identifier type

@partim
Copy link
Member

partim commented Dec 8, 2022

Thank you for the PR! It is looking great. I will merge it and also publish a release 0.7.1 as soon as all the CI shenanigans have completed.

@partim
Copy link
Member

partim commented Dec 8, 2022

Looks like older MacOS toolchains are broken for some reason. I changed main to test with 1.64.0 as the oldest version. Could you perchance merge main into your branch so we can have the CI go green?

@lvkv
Copy link
Contributor Author

lvkv commented Dec 8, 2022

Looks like older MacOS toolchains are broken for some reason. I changed main to test with 1.64.0 as the oldest version. Could you perchance merge main into your branch so we can have the CI go green?

Merged in dde24e4 (above)

@partim partim merged commit 71e45d0 into NLnetLabs:main Dec 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants