Skip to content

Commit 79ace00

Browse files
committed
Update encryption key retrieval
Update encryption key retrieval to use PCR selection from policy. Signed-off-by: Shahriyar Jalayeri <shahriyar@posteo.de>
1 parent 80555c5 commit 79ace00

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

pkg/vtpm/swtpm-vtpm/src/main.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,8 @@ var (
5151
return err == nil
5252
}
5353
getEncryptionKey = func() ([]byte, error) {
54-
// FIX-ME : update this after pillar changes is merged!!!
55-
return etpm.UnsealDiskKey(etpm.DiskKeySealingPCRs)
54+
pcrSelection := etpm.GetDiskKeyPolicyPcrOrDefault(types.PolicyPcrFile)
55+
return etpm.UnsealDiskKeyWithRecovery(pcrSelection)
5656
}
5757
)
5858

0 commit comments

Comments
 (0)