feat: add simulated CCA attester #4
Open
shefali-kamal wants to merge 2 commits into
Open
Conversation
thomas-fossati
approved these changes
Jul 17, 2026
thomas-fossati
left a comment
Contributor
There was a problem hiding this comment.
Excellent contribution, thanks!
I have left a few comments inline for your consideration -- none of which are blocking.
| use ciborium::Value as CborValue; | ||
|
|
||
| impl From<PlatformClaims> for CborValue { | ||
| #[allow(clippy::vec_init_then_push)] |
Contributor
There was a problem hiding this comment.
just a curiosity: why is this needed here and not in the (very similar) RealmClaims (around L199)?
Contributor
There was a problem hiding this comment.
Clippy only flags PlatformClaims because it has five consecutive pushes before any conditional field. RealmClaims branches early with an if let Some(profile) after the first push, so clippy doesn't trigger there. No functional difference - just clippy heuristics.
- Replace the old FakeTsmBuilder with SimulatedTokenBuilder that constructs real CBOR tag 399 tokens from JSON claims and JWK keys - Add encode_cca_token() for building CCA tokens with two COSE_Sign1 signatures (platform + realm) using ES384 on P-384 - Add CcaSimulatedAttester implementing the Attester trait - Add CcaRatsdAttester that posts to RATSD and parses the CMW envelope - Add crypto helpers: load_p384_jwk, build_rak_cose_key, sign_cose_sign1, is_supported_hash_alg, compute_hash - Add serde-enabled CCA token types with CBOR conversions - Add decode_cca_token() and pretty_print_token() utilities - Add CBOR key constants per the Arm CCA attestation token spec - Switch cmw dependency from git to crates.io v0.1.1 Signed-off-by: BISWAS, SREYAN <SREYAN.BISWAS@fujitsu.com>
Signed-off-by: Dhanus M Lal <Dhanus.MLal@fujitsu.com>
Contributor
|
Thanks for addressing all my comments. This looks ready to ship. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replaces the old static-blob FakeTsmBuilder with a real SimulatedTokenBuilder that builds spec-compliant CCA tokens (CBOR tag 399) from JSON claims and JWK keys signed with ES384. No hardware or RATSD daemon needed.