azure: TCTI is hardcoded to the raw /dev/tpm0 device
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 48/100
Research direction
Start in crates/attestation/src/azure/nv_index.rs at the hardcoded TctiNameConf::Device(DeviceConfig::default()) call, then trace the Azure evidence path through az_tdx_vtpm::vtpm and az-cvm-vtpm src/vtpm/mod.rs. Review the linked azure-cvm-tooling issue for the upstream change. Done means the conventional TCTI environment variable is honored while the existing device default remains the fallback across the Azure path.
Written by the indexing model from the issue text.
Description
crates/attestation/src/azure/nv_index.rs builds its TSS context with the
hardcoded default TCTI:
let conf: TctiNameConf = TctiNameConf::Device(DeviceConfig::default());
DeviceConfig::default() is the raw /dev/tpm0 device, which the kernel
hands to one client at a time: any other TPM user on the machine
(tpm2-tools, systemd, a second evidence-generating process) makes context
creation fail with a device-busy error, and vice versa. The kernel's TPM
resource manager (/dev/tpmrm0) multiplexes clients, but there is
currently no way to select it.
Proposal: resolve the TCTI via TctiNameConf::from_environment_variable()
(which honors the conventional TPM2TOOLS_TCTI / TCTI variables, e.g.
device:/dev/tpmrm0) and keep the current default as fallback — no
behavior change unless the variable is set.
Note the azure evidence path also reaches the same hardcoded pattern
upstream through az_tdx_vtpm::vtpm (az-cvm-vtpm src/vtpm/mod.rs), so
fully honoring the variable needs the matching upstream change too — filed
as https://github.com/kinvolk/azure-cvm-tooling/issues/92.
- Dominant language
- Rust
- Stars
- 6
- Forks
- 3
- Avg merge
- 4d 5h
- Merged PRs (30d)
- 7
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from flashbots/attested-tls
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
flashbots/attested-tls#97 ·
-
Difficulty 5/5 Over a week Newbie friendliness 45/100
flashbots/attested-tls#92 · 4 comments ·
-
Difficulty 3/5 1-2 days Newbie friendliness 68/100
flashbots/attested-tls#87 · 1 comment ·
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
flashbots/attested-tls#84 · 7 comments ·
-
Difficulty 3/5 1-2 days Newbie friendliness 58/100
flashbots/attested-tls#82 · 1 comment ·
All issues in flashbots/attested-tls
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Eynzof/Hermes-CN-Desktop#610 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
bug team:backend track:services-maintenance
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
cowprotocol/services#4950 ·
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
gitbutlerapp/gitbutler#15998 · 1 comment ·