Skip to content

Commit

Permalink
runtime: disable protection check
Browse files Browse the repository at this point in the history
enableProtection() is called when confidential_guest=true, so we
disable this check to allow us to test running with
confidential_guest=true and sev_snp_guest=false.

Note this was already done by Wedson previously to allow testing on
non-SNP CPUs, but the purpose here is different.
  • Loading branch information
sprt committed Jan 12, 2024
1 parent 7da3655 commit 23e3dba
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/runtime/virtcontainers/clh.go
Original file line number Diff line number Diff line change
Expand Up @@ -474,7 +474,8 @@ func (clh *cloudHypervisor) enableProtection() error {
return nil

default:
return errors.New("This system doesn't support Confidential Computing (Guest Protection)")
// Allow running with no hardware protection for testing.
return nil
}
}

Expand Down

0 comments on commit 23e3dba

Please sign in to comment.