lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 2 Jul 2019 16:54:49 +0000
From:   Thirupathaiah Annapureddy <thiruan@...rosoft.com>
To:     Ilias Apalodimas <ilias.apalodimas@...aro.org>,
        Jarkko Sakkinen <jarkko.sakkinen@...ux.intel.com>
CC:     Sasha Levin <sashal@...nel.org>,
        "peterhuewe@....de" <peterhuewe@....de>,
        "jgg@...pe.ca" <jgg@...pe.ca>, "corbet@....net" <corbet@....net>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "linux-doc@...r.kernel.org" <linux-doc@...r.kernel.org>,
        "linux-integrity@...r.kernel.org" <linux-integrity@...r.kernel.org>,
        Microsoft Linux Kernel List <linux-kernel@...rosoft.com>,
        "Bryan Kelly (CSI)" <bryankel@...rosoft.com>,
        "tee-dev@...ts.linaro.org" <tee-dev@...ts.linaro.org>,
        "sumit.garg@...aro.org" <sumit.garg@...aro.org>,
        "rdunlap@...radead.org" <rdunlap@...radead.org>
Subject: RE: [PATCH v7 1/2] fTPM: firmware TPM running in TEE

Hi Ilias,

First of all, Thanks a lot for trying to test the driver. 

> -----Original Message-----
> From: Ilias Apalodimas <ilias.apalodimas@...aro.org>
> Sent: Tuesday, July 2, 2019 7:21 AM
> To: Jarkko Sakkinen <jarkko.sakkinen@...ux.intel.com>
> Cc: Sasha Levin <sashal@...nel.org>; peterhuewe@....de; jgg@...pe.ca;
> corbet@....net; linux-kernel@...r.kernel.org; linux-doc@...r.kernel.org;
> linux-integrity@...r.kernel.org; Microsoft Linux Kernel List <linux-
> kernel@...rosoft.com>; Thirupathaiah Annapureddy <thiruan@...rosoft.com>;
> Bryan Kelly (CSI) <bryankel@...rosoft.com>; tee-dev@...ts.linaro.org;
> sumit.garg@...aro.org; rdunlap@...radead.org
> Subject: Re: [PATCH v7 1/2] fTPM: firmware TPM running in TEE
> 
> Hi,
> 
> > On Thu, 2019-06-27 at 16:30 +0300, Ilias Apalodimas wrote:
> > > is really useful. I don't have hardware to test this at the moment, but
> once i
> > > get it, i'll give it a spin.
> >
> > Thank you for responding, really appreciate it.
> >
> No worries
> > Please note, however, that I already did my v5.3 PR so there is a lot of
> > time to give it a spin. In all cases, we will find a way to put this to
> > my v5.4 PR. I don't see any reason why not.
> >
> > As soon as the cosmetic stuff is fixed that I remarked in v7 I'm ready
> > to take this to my tree and after that soonish make it available on
> > linux-next.
> I managed to do some quick testing in QEMU.
> Everything works fine when i build this as a module (using IBM's TPM 2.0
> TSS)
> 
> - As module
> # insmod /lib/modules/5.2.0-rc1/kernel/drivers/char/tpm/tpm_ftpm_tee.ko
> # getrandom -by 8
> randomBytes length 8
> 23 b9 3d c3 90 13 d9 6b
> 
> - Built-in
> # dmesg | grep optee
> ftpm-tee firmware:optee: ftpm_tee_probe:tee_client_open_session failed,
> err=ffff0008
This (0xffff0008) translates to TEE_ERROR_ITEM_NOT_FOUND.

Where is fTPM TA located in the your test setup? 
Is it stitched into TEE binary as an EARLY_TA or 
Is it expected to be loaded during run-time with the help of user mode OP-TEE supplicant?

My guess is that you are trying to load fTPM TA through user mode OP-TEE supplicant. 
Can you confirm? 
If that is the true, 
- In the case of driver built as a module (CONFIG_TCG_FTPM_TEE=m), this is works fine 
as user mode supplicant is ready. 
- In the built-in case (CONFIG_TCG_FTPM_TEE=y), 
This would result in the above error 0xffff0008 as TEE is unable to find fTPM TA. 

The expectation is that fTPM TA is built as an EARLY_TA (in BL32) so that
U-boot and Linux driver stacks work seamlessly without dependency on supplicant.  


> ftpm-tee: probe of firmware:optee failed with error -22
> # getrandom -by 8
> random: fast init done
> urandom_read: 2 callbacks suppressed
> random: getrandom: uninitialized urandom read (32 bytes read)
> TSS_Dev_Open: Error opening /dev/tpm0
> getrandom: failed, rc 000b0008
> TSS_RC_NO_CONNECTION - Failure connecting to lower layer
> 
> Am i missing anything?
> 
> Thanks
> /Ilias

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ