SVSM draft specification
Attached is a draft specification with the following changes:
- New single service extended attestation request
- vTPM service update for single service extended attestation request
- UEFI Management Mode service
- Needs references to the request/response formats
- Placeholder for the APIC emulation service
I just noticed that Dionna is now looking instead at adding a new manifest version that would return a list of the various forms of the storage and signing keys. This would eliminate any kernel changes as the caller would now just request the new manifest version in the attest single service request.
I would prefer this as it would eliminate the need for the single service extended attestation request and support for that within each service. For now, this draft specification has the original changes requested. Please review at least for the UEFI MM service, if the direction is to move to a new vTPM manifest version.
Thanks,
Tom
Comments and Suggestions:
* Bit 2 of Flags (Table 23):
The description for bit 2 is, "Secure boot databases are updatable by the guest (db/dbx)."
Does this also apply to other updatable Secure Boot databases like Platform Key (PK), Key Exchange Key (KEK), and Timestamp Signature Database (dbt)? If not, perhaps allocating one bit per UEFI database could enhance flexibility.
* Confusing Statement:
The following statement is unclear:
"If a database does not contain any data or is not present, the offset and size for that database must be 0."
My understanding is that bit 2 is meant to specify whether databases are updatable, not to define thier sizes.. Could you clarify this?
* Typo:
There is a typo in the text: "Secure boot is enabledn." It should be "enabled."
Geoffrey
Quoted 23 lines · Tom Lendacky
Attached is a draft specification with the following changes:
- New single service extended attestation request
- vTPM service update for single service extended attestation request
- UEFI Management Mode service
- Needs references to the request/response formats
- Placeholder for the APIC emulation serviceI just noticed that Dionna is now looking instead at adding a new manifest version that would return a list of the various forms of the storage and signing keys. This would eliminate any kernel changes as the caller would now just request the new manifest version in the attest single service request.
I would prefer this as it would eliminate the need for the single service extended attestation request and support for that within each service. For now, this draft specification has the original changes requested. Please review at least for the UEFI MM service, if the direction is to move to a new vTPM manifest version.
Thanks,
Tom
Quoted 11 lines · Geoffrey Ndu
Comments and Suggestions:
* Bit 2 of Flags (Table 23):
The description for bit 2 is, "Secure boot databases are updatable by the guest (db/dbx)."
Does this also apply to other updatable Secure Boot databases like Platform Key (PK), Key Exchange Key (KEK), and Timestamp Signature Database (dbt)? If not, perhaps allocating one bit per UEFI database could enhance flexibility.
One bit per database is not useful I think. They all should be treated the same.
What possibly makes sense is have separate bits for enrollment and update. "enrollment" means the guest can set those variables if the system is in setup mode (i.e. no keys present). "update" means the guest can update these variables with proper pkcs7 signatures. The later depends on crypto support for the signature verification, the former does not.
Quoted 6 lines
* Confusing Statement:
The following statement is unclear:
"If a database does not contain any data or is not present, the offset and size for that database must be 0."
I think this is a leftover from an older version where 'db' + 'dbx' where added to the manifest, which is not the case any more because the uefi firmware measures them into tpm pcr registers anyway.
take care,
Gerd
Quoted 16 lines · Gerd Hoffmann
Quoted 11 lines · Geoffrey Ndu
Comments and Suggestions:
* Bit 2 of Flags (Table 23):
The description for bit 2 is, "Secure boot databases are updatable by the guest (db/dbx)."
Does this also apply to other updatable Secure Boot databases like Platform Key (PK), Key Exchange Key (KEK), and Timestamp Signature Database (dbt)? If not, perhaps allocating one bit per UEFI database could enhance flexibility.
One bit per database is not useful I think. They all should be treated the same.
Quoted 6 lines
What possibly makes sense is have separate bits for enrollment and update. "enrollment" means the guest can set those variables if the system is in setup mode (i.e. no keys present). "update" means the guest can update these variables with proper pkcs7 signatures. The later depends on crypto support for the signature verification, the former does not.
If there isn't any objection to this in the next few days, I will update the spec to add a new bit for enrollment.
Thanks,
Tom
Quoted 15 lines
Quoted 7 lines
* Confusing Statement:
The following statement is unclear:
"If a database does not contain any data or is not present, the offset and size for that database must be 0."
I think this is a leftover from an older version where 'db' + 'dbx' where added to the manifest, which is not the case any more because the uefi firmware measures them into tpm pcr registers anyway.
take care,
Gerd
Quoted 12 lines · Geoffrey Ndu
Comments and Suggestions:
* Bit 2 of Flags (Table 23):
The description for bit 2 is, "Secure boot databases are updatable by the guest (db/dbx)."
Does this also apply to other updatable Secure Boot databases like Platform Key (PK), Key Exchange Key (KEK), and Timestamp Signature Database (dbt)? If not, perhaps allocating one bit per UEFI database could enhance flexibility.
Quoted 6 lines
* Confusing Statement:
The following statement is unclear:
"If a database does not contain any data or is not present, the offset and size for that database must be 0."
Ah, forgot to remove this statement when I removed the db/dbx from the manifest. Will delete this.
Quoted 7 lines
My understanding is that bit 2 is meant to specify whether databases are updatable, not to define thier sizes.. Could you clarify this?
* Typo:
There is a typo in the text: "Secure boot is enabledn." It should be "enabled."
Got it.
Thanks,
Tom
Quoted 28 lines
Geoffrey
Quoted 23 lines · Tom Lendacky
Attached is a draft specification with the following changes:
- New single service extended attestation request
- vTPM service update for single service extended attestation request
- UEFI Management Mode service
- Needs references to the request/response formats
- Placeholder for the APIC emulation serviceI just noticed that Dionna is now looking instead at adding a new manifest version that would return a list of the various forms of the storage and signing keys. This would eliminate any kernel changes as the caller would now just request the new manifest version in the attest single service request.
I would prefer this as it would eliminate the need for the single service extended attestation request and support for that within each service. For now, this draft specification has the original changes requested. Please review at least for the UEFI MM service, if the direction is to move to a new vTPM manifest version.
Thanks,
Tom
Quoted 5 lines · Tom Lendacky
Attached is a draft specification with the following changes:
- New single service extended attestation request
- vTPM service update for single service extended attestation request
I don't think any of the flags in the vTPM single service attestation are a good idea
1. Whether non volatile UEFI variables have backing or not is nothing to do with the TPM service ... there should be a UEFI variable service that indicates this (when it's even available).
2. How does the vTPM or even the SVSM know if the system is secure booted? That's the province of OVMF to enforce. The SVSM can deduce it possibly from the state of the variables, but on security separation grounds the vTPM service should *not* be accessing the UEFI variable service.
3. Preventing updates to db/dbx will require code changes to the reference implementation ... that's always a bad idea since it moves us away from what the TCG publishes and means we have to keep an out of tree patch. What's the point of it anyway? The way to ensure the guest can't update db/dbx is what we have today for physical systems: not knowing the private key in KEK.
Regards,
James
On Wed, 2025-07-02 at 08:28 -0400, James Bottomley wrote:
[...]
Quoted 7 lines
3. Preventing updates to db/dbx will require code changes to the reference implementation ... that's always a bad idea since it moves us away from what the TCG publishes and means we have to keep an out of tree patch. What's the point of it anyway? The way to ensure the guest can't update db/dbx is what we have today
for physical systems: not knowing the private key in KEK.
Sorry, not enough tea yet. This, again, is actually nothing to do with the TPM (so at least we wouldn't have to change the implementation). However, even if we get a UEFI flash persistence service, updates to variables will again be the province of OVMF and the SVSM will just be providing backing storage. Sure, it can snoop the updates but it still looks like something that's already covered adequately today as stated above.
Regards,
James
Hi,
Quoted 3 lines
However, even if we get a UEFI flash persistence service, updates to variables will again be the province of OVMF and the SVSM will just be providing backing storage.
No. svsm will actually manage the variables and verify updates. Current version can't handle pkcs7 signature verification yet, so the secure boot variables are read-only for now. Also they are not persistent yet. That is expected to change as crypto + storage support in svsm improves.
take care,
Gerd
Quoted 5 lines · Tom Lendacky
Attached is a draft specification with the following changes:
- New single service extended attestation request
- vTPM service update for single service extended attestation request
- UEFI Management Mode service
SVSM_UEFI_MM_REQUEST description refers to *previously registered* communication buffer still, which we do not have any more because we removed the register/unregister calls.
Quoted 1 line
- Needs references to the request/response formats
What do you need here? Links into github.com/tianocore/edk2?
take care,
Gerd
Quoted 10 lines · Gerd Hoffmann
Quoted 5 lines · Tom Lendacky
Attached is a draft specification with the following changes:
- New single service extended attestation request
- vTPM service update for single service extended attestation request
- UEFI Management Mode service
SVSM_UEFI_MM_REQUESTdescription refers to *previously registered* communication buffer still, which we do not have any more because we removed the register/unregister calls.
Ah, thanks. Removed "the previously registered" portion of the sentence.
Quoted 4 lines
Quoted 2 lines
- Needs references to the request/response formats
What do you need here? Links into github.com/tianocore/edk2?
Just something that someone can go to and see what the request / response format is. Is there a more granular link that describes it vs looking at the code?
Thanks,
Tom
Quoted 4 lines
take care,
Gerd
Hi,
Quoted 7 lines
Quoted 3 lines
Quoted 1 line
- Needs references to the request/response formats
What do you need here? Links into github.com/tianocore/edk2?
Just something that someone can go to and see what the request / response format is. Is there a more granular link that describes it vs looking at the code?
I was thinking about the header files, which have the structs and lots of comments on the fields. I'll check if there is some actual documentation too. Stay tuned.
take care,
Gerd