Skip to content

Update to latest corim-store plus fixes#416

Merged
setrofim merged 2 commits into
mainfrom
setrofim/store-update
May 13, 2026
Merged

Update to latest corim-store plus fixes#416
setrofim merged 2 commits into
mainfrom
setrofim/store-update

Conversation

@setrofim
Copy link
Copy Markdown
Collaborator

  • Update to the latest corim-store, switching to it to handle CoSERV
  • Fix CCA attestation handling of updated endorsement formats

- Up the required go version 1.26 due to it being required by the latest
  corim-store.
- Use the new corim-store API to implement CoSERV handling.
- Switching to using AddBytes instead of AddCorim inside
  SubmitEndorsements so that the raw token bytes are added to the store
  alongside the parsed CoRIM. Store configuration is also updated to
  allow adding signed CoRIMs without signature verification (as they
  have already been verified prior to adding them to the store).
- Update not-after in integration-tests CoRIM to be in the future, as
  validity is now being considered when retrieving endorsements.

Signed-off-by: Sergei Trofimov <sergei.trofimov@arm.com>
Comment thread scheme/arm-cca/scheme.go
Comment thread scheme/arm-cca/scheme.go
Comment thread scheme/arm-cca/scheme.go Outdated
@setrofim setrofim force-pushed the setrofim/store-update branch 2 times, most recently from a78f5b7 to 627ddb3 Compare May 12, 2026 10:24
Update AppraiseClaims to expect the new endorsements format introduced
in d4c39f7.

Also update expected results in integration tests to expect "affirming"
for realm. They were originally "warning" because all schemes were
tested using the same end-to-end test that could only provision one
CoRIM, and so only platform endorsements were provisioned. We have since
switched CCA to use its own flow that provisions both platform and realm
endorsements. The fact that we were still expecting "warning" partially
obscured the other issue being fixed here.

Signed-off-by: Sergei Trofimov <sergei.trofimov@arm.com>
@setrofim setrofim force-pushed the setrofim/store-update branch from 627ddb3 to 892f8af Compare May 13, 2026 07:39
Comment thread scheme/arm-cca/scheme.go
refVal.PersonalizationValue, err = measurement.Val.RawValue.GetBytes()
switch mkey {
case cca.CCARealmInitialMeasurementMkey:
digest, err := readMeasurementDigestBytes(&measurement)
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Just wondering, we are reading via readMeasurementDigestBytes(),

we should also check the allowed Digest Algorithm for CCA, as ONLY three values are allowed.

cca-realm-measurement-type = bytes .size 32 / bytes .size 48 / bytes .size 64

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

But this has no bearing on verification algorithm. This has already been validated by the profile-validation when the CoRIM was originally added. Here, we only care whether digests match the evidence. Structural validity of CoRIMs and evidence tokens is validated elsewhere.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Sure, I wanted to check, whether when storing CoRIMs in the store this aspect has been validated or not???

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Yes, this is validated by the profile-specific validation code.

Copy link
Copy Markdown
Collaborator

@yogeshbdeshpande yogeshbdeshpande left a comment

Choose a reason for hiding this comment

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

LGTM!

Comment thread scheme/arm-cca/scheme.go
}

func allMatch(lhs, rhs [][]byte) bool {
if len(lhs) != len(rhs) {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Orthogonal to this code review, something to remember is the case when len (lhs) can be > than len(rhs) which we should allow, but the reverse should be a failure!! Here I assume rhs is reference and lhs is Evidence

@setrofim setrofim merged commit 21ec232 into main May 13, 2026
9 checks passed
@setrofim setrofim deleted the setrofim/store-update branch May 13, 2026 09:19
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.

4 participants