Skip to content

Commit e1ffa0d

Browse files
committed
(WIP) Add sublayout to verification pseudocode
Signed-off-by: Aditya Sirish <[email protected]>
1 parent 2397c1f commit e1ffa0d

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

ITE/10/README.adoc

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -230,11 +230,15 @@ func Verify(layoutEnvelope, layoutKeys, attestations, now) {
230230
stepAttestations := attestationsForStep(step.Name, attestations)
231231
for _, predicate := range step.ExpectedPredicates {
232232
predicateAttestations := attestationsForStepPredicate(predicate.Type, stepAttestations)
233-
verifyAttestationSignatures(predicate.Functionaries, predicate.Threshold, predicateAttestations)
234-
for _, attestation := range predicateAttestations {
235-
applyMaterialRules(predicate.ExpectedMaterials, attestation)
236-
applyProductRules(predicate.ExpectedProducts, attestation)
237-
applyAttributeRules(predicate.ExpectedAttributes, attestation)
233+
if predicate.Type == LAYOUT {
234+
Verify(predicateAttestations[0], predicate.Functionaries, predicateAttestations[1:], now)
235+
} else {
236+
verifyAttestationSignatures(predicate.Functionaries, predicate.Threshold, predicateAttestations)
237+
for _, attestation := range predicateAttestations {
238+
applyMaterialRules(predicate.ExpectedMaterials, attestation)
239+
applyProductRules(predicate.ExpectedProducts, attestation)
240+
applyAttributeRules(predicate.ExpectedAttributes, attestation)
241+
}
238242
}
239243
}
240244
}

0 commit comments

Comments
 (0)