OP-TEE / optee_os

Trusted side of the TEE
Other
1.58k stars 1.06k forks source link

fTPM TA not opening the context #7080

Open Palatrauss00 opened 1 week ago

Palatrauss00 commented 1 week ago

Hi, for my master thesis I am working at implementing a fTPM on OPTEE and adding new libraries to it. I have seen the this implementation but it does not work and it is a bit outdated. So, I'm working to adapt the fTPM TA to the latest version of optee .

I am having issues to run the ftpm TA. Running the command ./getRandom, I have received this error

TSS_Dev_Open: Error opening /dev/tpm0 getrandom: failed, rc 000b0008 TSS_RC_NO_CONNECTION - Failure connecting to lower layer I think the error is inside the loading of the kernel module, because the function ftpm_tee_probe that opens the context seems it is not called. So, I think that the fTPM TA is never run but the kernel module is loaded inside the kernel because I have launched lsmod and the tpm_ftpm_tee is printed. What could be the issue?

jenswi-linaro commented 1 week ago

We're currently working on importing the fTPM TA into OP-TEE, have you seen https://github.com/OP-TEE/optee_os/pull/7054?

Palatrauss00 commented 1 week ago

In these days I've seen what you do. But what is the difference between inserting into optee_os and building as external TA?

Also how can I test that is properly working?