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  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Wed, 13 Feb 2019 18:33:16 +0200
From:   Jarkko Sakkinen <jarkko.sakkinen@...ux.intel.com>
To:     Tadeusz Struk <tadeusz.struk@...el.com>
Cc:     linux-kselftest@...r.kernel.org, shuah@...nel.org,
        linux-kernel@...r.kernel.org, linux-integrity@...r.kernel.org,
        linux-security-module@...r.kernel.org, PeterHuewe@....de,
        jgg@...pe.ca
Subject: Re: [PATCH v2 2/2] selftests/tpm2: Extend tests to cover partial
 reads

On Wed, Feb 13, 2019 at 08:27:44AM -0800, Tadeusz Struk wrote:
> On 2/13/19 7:13 AM, Jarkko Sakkinen wrote:
> > On Tue, 2019-02-12 at 15:42 -0800, Tadeusz Struk wrote:
> >> Three new tests added:
> >> 1. Send get random cmd, read header in 1st read, read the rest in second
> >>    read - expect success
> >> 2. Send get random cmd, read only part of the response, send another
> >>    get random command, read the response - expect success
> >> 3. Send get random cmd followed by another get random cmd, without
> >>    reading the first response - expect the second cmd to fail with -EBUSY
> >>
> >> Signed-off-by: Tadeusz Struk <tadeusz.struk@...el.com>
> > 
> > Getting still some garbage in the output:
> > 
> > $ sudo ./test_smoke.sh 
> > [sudo] password for jsakkine: 
> > test_read_partial_overwrite (tpm2_tests.SmokeTest)
> > Reads only part of the response and issue a new cmd ... ok
> > test_read_partial_resp (tpm2_tests.SmokeTest)
> > Reads random in two subsequent reads ... ok
> > test_seal_with_auth (tpm2_tests.SmokeTest) ... ok
> > test_seal_with_policy (tpm2_tests.SmokeTest) ... ok
> > test_seal_with_too_long_auth (tpm2_tests.SmokeTest) ... ok
> > test_send_two_cmds (tpm2_tests.SmokeTest)
> > Send two cmds without reading a response ... ok
> > test_too_short_cmd (tpm2_tests.SmokeTest) ... ok
> > test_unseal_with_wrong_auth (tpm2_tests.SmokeTest) ... ok
> > test_unseal_with_wrong_policy (tpm2_tests.SmokeTest) ... ok
> 
> Looks like python unittest prints out the docstrings:
> 
> +    def test_read_partial_resp(self):
> +        """Reads random in two subsequent reads"""
> 
> I can remove them if it makes more difficult to process the output.

Yeah, I mean it also outputs the function name, which is good enough
IMHO.

/Jarkko

Powered by blists - more mailing lists