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 AuthenticationExtensionsAuthenticatorInputs/Outputs CDDL #2221

Merged
merged 2 commits into from
Dec 18, 2024

Conversation

emlun
Copy link
Member

@emlun emlun commented Dec 18, 2024

This is the combination of PR #2219 and the changes proposed in tidoust#1 . Merging this PR would effectively merge #2219 as well, and means we don't need to wait for @tidoust to review tidoust#1.

The issue is similar to the "proposed change 1" of #2210. I recently had clarified on the CDDL mail list that control operators only apply to types, not groups. @tidoust's PR #2219 fixes the right-hand side, but not the left-hand side. This PR completes the fix.


Preview | Diff

tidoust and others added 2 commits December 3, 2024 14:06
According to the CDDL grammar, after a control operator (called `ctlop` in the
ABNF grammar), there can only be a `type2` production:
https://datatracker.ietf.org/doc/html/rfc8610#appendix-B

In a `type2` production, wrapping parentheses can only be used to wrap a `type`
production. `tstr => any` is a `group` production, and needs to be wrapped in
curly braces or brackets.

In other words, from a CDDL grammar perspective, this is an invalid type:
  `foo .within ( tstr => any )`

This is valid:
  `foo .within { tstr => any }`

This update fixes the CDDL type definitions that used the `.within` operator
with an invalid type2.
@emlun emlun requested a review from selfissued December 18, 2024 15:30
@emlun emlun self-assigned this Dec 18, 2024
@tidoust
Copy link
Member

tidoust commented Dec 18, 2024

Sorry, I hadn't realized that you had sent a pull request on my fork! GitHub's handling of notifications for personal repositories never ceases to amaze me... Anyway, this looks good to me, and feel free to ditch the initial PR I had prepared!

Copy link
Member

@timcappalli timcappalli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@selfissued selfissued merged commit 57efac8 into main Dec 18, 2024
2 checks passed
github-actions bot added a commit that referenced this pull request Dec 18, 2024
SHA: 57efac8
Reason: push, by selfissued

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants