-
Notifications
You must be signed in to change notification settings - Fork 1
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
feat(core): KID in NanoTDF #324
Conversation
Introduces a new enum for identifier length and modifies the ResourceLocator class to include this identifier and its encoding/decoding logic. This enhances the resource locator functionality by supporting identifiers of varying lengths.
If these changes look good, signoff on them with:
If they aren't any good, please remove them with:
|
Signed-off-by: Paul Flynn <pflynn@virtru.com>
a87e092
to
8262fbd
Compare
Corrected the bitwise operation for identifier type nibble check to accurately detect the 'None' type. Also removed an outdated TODO comment related to padding in identifier decoding.
Initialize `identifierType` to `None` explicitly before evaluating the protocol nibble. This simplifies the conditional logic by setting a default value upfront and adjusting it only when specific conditions are met.
If these changes look good, signoff on them with:
If they aren't any good, please remove them with:
|
Initialized `identifierType` to `ResourceLocatorIdentifierEnum.None` by default in the `ResourceLocator` model. Removed redundant assignment in constructor and adjusted identifier length calculation accordingly. Signed-off-by: Paul Flynn <pflynn@virtru.com>
42211e6
to
bcef48d
Compare
Changed the allocation of the buffer to use identifierType.valueOf() instead of this.identifier.length. This ensures accurate buffer sizing based on the identifier type's value.
Changed the allocation of the buffer to use identifierType.valueOf() instead of this.identifier.length. This ensures accurate buffer sizing based on the identifier type's value. Signed-off-by: Paul Flynn <pflynn@virtru.com>
2de3c0d
to
aa8a011
Compare
Included new test cases to verify the parsing logic of the ResourceLocator identifiers in different byte formats such as two bytes, eight bytes, and thirty-two bytes. This ensures that the identifier type and value are correctly parsed and validated.
If these changes look good, signoff on them with:
If they aren't any good, please remove them with:
|
00d825c
to
c548f4f
Compare
Signed-off-by: Paul Flynn <pflynn@virtru.com>
c548f4f
to
0b587f6
Compare
Streamline the identifier extraction by removing padding bytes before decoding. This change accounts for null byte padding that was previously being included in the identifier, ensuring cleaner and more accurate decoding.
Quality Gate passedIssues Measures |
NanoTDF will now have the KAS KID set in the KAS ResourceLocator
Introduces a new enum for identifier length and modifies the ResourceLocator class to include this identifier and its encoding/decoding logic. This enhances the resource locator functionality by supporting identifiers of varying lengths.
Resolves #311
Specification: opentdf/spec#40
ADR: opentdf/platform#900