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

More test vectors #232

Open
wants to merge 13 commits into
base: main
Choose a base branch
from
Open

More test vectors #232

wants to merge 13 commits into from

Conversation

c2bo
Copy link
Member

@c2bo c2bo commented Jan 17, 2025

Fixes #216

I've moved the existing 2 bit examples and ascii art up - we can revert that change, but it felt more consistent to me that way
I am not exactly sure how to better displays the input (status values for specific positions) - any ideas?

Rendered version: https://drafts.oauth.net/draft-ietf-oauth-status-list/216-test-vectors/draft-ietf-oauth-status-list.html

@paulbastian
Copy link
Contributor

I like it! I initially proposed to move the 2 bit acsii art up there, so that's fine for me :)
I think we require the CWT examples as well in the test vectors, having them for the same input values would be good.

@c2bo
Copy link
Member Author

c2bo commented Jan 17, 2025

I like it! I initially proposed to move the 2 bit acsii art up there, so that's fine for me :) I think we require the CWT examples as well in the test vectors, having them for the same input values would be good.

Hmm, so we would provide the results in CBOR and JSON (we can easily re-use the same values)?

Co-authored-by: Paul Bastian <[email protected]>
@c2bo c2bo changed the title 216 test vectors More test vectors Jan 20, 2025
@c2bo c2bo marked this pull request as ready for review January 20, 2025 10:04
@c2bo c2bo requested a review from tplooker as a code owner January 20, 2025 10:04
@paulbastian
Copy link
Contributor

todo:

  • status list token JWT rendering
  • verifying test vectors inpendently wiht implementations

@paulbastian
Copy link
Contributor

I've got the feedback that it may be irritating to not have dedicated 1-bit test vectors in the appendix

@c2bo
Copy link
Member Author

c2bo commented Jan 23, 2025

I will create a longer 1 bit example then

@c2bo
Copy link
Member Author

c2bo commented Jan 27, 2025

Todo: Wait for feedback on test vectors (check with at least one alternative implementation)

@markuskreusch-bdr
Copy link

markuskreusch-bdr commented Jan 30, 2025

I checked the test vectors by

  • Defining the status[*] = * entries in the code (copy paste + search replace)
  • Parsing the JSON and CBOR from the document with our library
  • Checking in automated testcases, that all status entries have the expected value (0 for the ones not mentioned and the given value for the ones mentioned in the test vectors)

Verification was successful for all values.

Nevertheless I noticed, that the samples (CBOR and JSON) for the one bit status list have 2 instead of 1 bits.

@c2bo
Copy link
Member Author

c2bo commented Jan 30, 2025

I checked the test vectors by

  • Defining the status[*] = * entries in the code (copy paste + search replace)
  • Parsing the JSON and CBOR from the document with our library
  • Checking in automated testcases, that all status entries have the expected value (0 for the ones not mentioned and the given value for the ones mentioned in the test vectors)

Verification was successful for all values.

Nevertheless I noticed, that the samples (CBOR and JSON) for the one bit status list have 2 instead of 1 bits.

Thank you for catching that! That was a copy/paste mistake on my side and should be fixed now.
Could you re-check if everything looks fine now?

@markuskreusch-bdr
Copy link

markuskreusch-bdr commented Jan 30, 2025

Thank you for catching that! That was a copy/paste mistake on my side and should be fixed now. Could you re-check if everything looks fine now?

Everything is fine now.

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.

Test vectors
3 participants