[{"id":1768825,"web_url":"http://patchwork.ozlabs.org/comment/1768825/","msgid":"<195f5fb4-d3d8-b90a-cf15-fc65a8147099@wwwdotorg.org>","list_archive_url":null,"date":"2017-09-14T20:28:35","subject":"Re: [U-Boot] [PATCH 8/8] test/py: vboot: Remove stderr redirect\n\tfrom openssl command","submitter":{"id":12517,"url":"http://patchwork.ozlabs.org/api/people/12517/","name":"Stephen Warren","email":"swarren@wwwdotorg.org"},"content":"On 09/14/2017 02:06 PM, Paul Burton wrote:\n> The openssl command specified in test_with_algo() ultimately ends up\n> being run by RunAndLog::run(), which uses it to construct a Popen object\n> with the default shell=False. The stderr redirect in the command is\n> therefore simply passed to openssl as an argument. With at least openssl\n> 1.1.0f this causes openssl, and therefore test_vboot, to fail with:\n> \n>    genpkey: Use -help for summary.\n>    Exit code: 1\n> \n> Any stderr output ought to be captured & stored in the RunAndLog\n> object's output field and returned from run() via run_and_log() to\n> test_with_algo() which then ignores it anyway, so we can drop the\n> shell-like redirection with no ill effects. With this fix test_vboot now\n> passes for me.\n\n> diff --git a/test/py/tests/test_vboot.py b/test/py/tests/test_vboot.py\n\n>       util.run_and_log(cons, 'openssl genpkey -algorithm RSA -out %sdev.key '\n>                        '-pkeyopt rsa_keygen_bits:2048 '\n> -                     '-pkeyopt rsa_keygen_pubexp:%d '\n> -                     '2>/dev/null'  % (tmpdir, public_exponent))\n> +                     '-pkeyopt rsa_keygen_pubexp:%d'\n> +                     % (tmpdir, public_exponent))\n\nNit: Operators are usually placed at the end of a line rather than at \nthe start of the next:\n\n > +                     '-pkeyopt rsa_keygen_pubexp:%d' %\n > +                     (tmpdir, public_exponent))\n\n... but again not a big deal.\n\nI could have sworn I checked this code ran on Python 3 when I first \nwrote it. Some of the issues you've fixed were clearly introduced since \nthen, but not all. Perhaps I'm remembering some other project where I \nused test.py instead. Anyway, the series,\n\nReviewed-by: Stephen Warren <swarren@nvidia.com>","headers":{"Return-Path":"<u-boot-bounces@lists.denx.de>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@bilbo.ozlabs.org","Authentication-Results":"ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=lists.denx.de\n\t(client-ip=81.169.180.215; helo=lists.denx.de;\n\tenvelope-from=u-boot-bounces@lists.denx.de;\n\treceiver=<UNKNOWN>)","Received":["from lists.denx.de (dione.denx.de [81.169.180.215])\n\tby ozlabs.org (Postfix) with ESMTP id 3xtVVQ3VbRz9s7h\n\tfor <incoming@patchwork.ozlabs.org>;\n\tFri, 15 Sep 2017 06:28:46 +1000 (AEST)","by lists.denx.de (Postfix, from userid 105)\n\tid 2F79DC21E68; Thu, 14 Sep 2017 20:28:41 +0000 (UTC)","from lists.denx.de (localhost [IPv6:::1])\n\tby lists.denx.de (Postfix) with ESMTP id 77971C21D7A;\n\tThu, 14 Sep 2017 20:28:39 +0000 (UTC)","by lists.denx.de (Postfix, from userid 105)\n\tid 4180EC21D5B; Thu, 14 Sep 2017 20:28:38 +0000 (UTC)","from avon.wwwdotorg.org (avon.wwwdotorg.org [104.237.132.123])\n\tby lists.denx.de (Postfix) with ESMTPS id D676BC21C6D\n\tfor <u-boot@lists.denx.de>; Thu, 14 Sep 2017 20:28:37 +0000 (UTC)","from [10.20.204.51] (thunderhill.nvidia.com [216.228.112.22])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128\n\tbits)) (No client certificate requested)\n\tby avon.wwwdotorg.org (Postfix) with ESMTPSA id 72E141C02C7;\n\tThu, 14 Sep 2017 14:28:36 -0600 (MDT)"],"X-Spam-Checker-Version":"SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de","X-Spam-Level":"","X-Spam-Status":"No, score=0.0 required=5.0 tests=none autolearn=unavailable\n\tautolearn_force=no version=3.4.0","X-Virus-Status":"Clean","X-Virus-Scanned":"clamav-milter 0.99.2 at avon.wwwdotorg.org","To":"Paul Burton <paul.burton@imgtec.com>","References":"<20170914200634.17818-1-paul.burton@imgtec.com>\n\t<20170914200634.17818-9-paul.burton@imgtec.com>","From":"Stephen Warren <swarren@wwwdotorg.org>","Message-ID":"<195f5fb4-d3d8-b90a-cf15-fc65a8147099@wwwdotorg.org>","Date":"Thu, 14 Sep 2017 14:28:35 -0600","User-Agent":"Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101\n\tThunderbird/52.2.1","MIME-Version":"1.0","In-Reply-To":"<20170914200634.17818-9-paul.burton@imgtec.com>","Content-Language":"en-GB","Cc":"u-boot@lists.denx.de, Stephen Warren <swarren@nvidia.com>","Subject":"Re: [U-Boot] [PATCH 8/8] test/py: vboot: Remove stderr redirect\n\tfrom openssl command","X-BeenThere":"u-boot@lists.denx.de","X-Mailman-Version":"2.1.18","Precedence":"list","List-Id":"U-Boot discussion <u-boot.lists.denx.de>","List-Unsubscribe":"<https://lists.denx.de/options/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=unsubscribe>","List-Archive":"<http://lists.denx.de/pipermail/u-boot/>","List-Post":"<mailto:u-boot@lists.denx.de>","List-Help":"<mailto:u-boot-request@lists.denx.de?subject=help>","List-Subscribe":"<https://lists.denx.de/listinfo/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=subscribe>","Content-Transfer-Encoding":"base64","Content-Type":"text/plain; charset=\"utf-8\"; Format=\"flowed\"","Errors-To":"u-boot-bounces@lists.denx.de","Sender":"\"U-Boot\" <u-boot-bounces@lists.denx.de>"}},{"id":1768852,"web_url":"http://patchwork.ozlabs.org/comment/1768852/","msgid":"<1815941.NR9A1lERRC@np-p-burton>","list_archive_url":null,"date":"2017-09-14T21:37:29","subject":"Re: [U-Boot] [PATCH 8/8] test/py: vboot: Remove stderr redirect\n\tfrom openssl command","submitter":{"id":33698,"url":"http://patchwork.ozlabs.org/api/people/33698/","name":"Paul Burton","email":"paul.burton@imgtec.com"},"content":"Hi Stephen,\n\nOn Thursday, 14 September 2017 13:28:35 PDT Stephen Warren wrote:\n> I could have sworn I checked this code ran on Python 3 when I first\n> wrote it. Some of the issues you've fixed were clearly introduced since\n> then, but not all. Perhaps I'm remembering some other project where I\n> used test.py instead. Anyway, the series,\n> \n> Reviewed-by: Stephen Warren <swarren@nvidia.com>\n\nThanks for the speedy review. I've addressed the nits you raised & submitted \nv2 with your Reviewed-by.\n\nThanks,\n    Paul","headers":{"Return-Path":"<u-boot-bounces@lists.denx.de>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@bilbo.ozlabs.org","Authentication-Results":"ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=lists.denx.de\n\t(client-ip=81.169.180.215; helo=lists.denx.de;\n\tenvelope-from=u-boot-bounces@lists.denx.de;\n\treceiver=<UNKNOWN>)","Received":["from lists.denx.de (dione.denx.de [81.169.180.215])\n\tby ozlabs.org (Postfix) with ESMTP id 3xtX4m4DQSz9s7B\n\tfor <incoming@patchwork.ozlabs.org>;\n\tFri, 15 Sep 2017 07:40:08 +1000 (AEST)","by lists.denx.de (Postfix, from userid 105)\n\tid 43497C21F10; Thu, 14 Sep 2017 21:38:53 +0000 (UTC)","from lists.denx.de (localhost [IPv6:::1])\n\tby lists.denx.de (Postfix) with ESMTP id 67B5EC21F20;\n\tThu, 14 Sep 2017 21:38:36 +0000 (UTC)","by lists.denx.de (Postfix, from userid 105)\n\tid 3CA0EC21F26; Thu, 14 Sep 2017 21:37:32 +0000 (UTC)","from mailapp01.imgtec.com (mailapp01.imgtec.com [195.59.15.196])\n\tby lists.denx.de (Postfix) with ESMTP id 62E6CC21F2B\n\tfor <u-boot@lists.denx.de>; Thu, 14 Sep 2017 21:37:32 +0000 (UTC)","from HHMAIL01.hh.imgtec.org (unknown [10.100.10.19])\n\tby Forcepoint Email with ESMTPS id D633ED52991C4;\n\tThu, 14 Sep 2017 22:37:26 +0100 (IST)","from BAMAIL02.ba.imgtec.org (10.20.40.28) by HHMAIL01.hh.imgtec.org\n\t(10.100.10.19) with Microsoft SMTP Server (TLS) id 14.3.294.0;\n\tThu, 14 Sep 2017 22:37:31 +0100","from np-p-burton.localnet (10.20.1.88) by bamail02.ba.imgtec.org\n\t(10.20.40.28) with Microsoft SMTP Server (TLS) id 14.3.266.1;\n\tThu, 14 Sep 2017 14:37:29 -0700"],"X-Spam-Checker-Version":"SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de","X-Spam-Level":"","X-Spam-Status":"No, score=0.0 required=5.0 tests=RCVD_IN_DNSWL_NONE\n\tautolearn=unavailable autolearn_force=no version=3.4.0","From":"Paul Burton <paul.burton@imgtec.com>","To":"Stephen Warren <swarren@wwwdotorg.org>","Date":"Thu, 14 Sep 2017 14:37:29 -0700","Message-ID":"<1815941.NR9A1lERRC@np-p-burton>","Organization":"Imagination Technologies","In-Reply-To":"<195f5fb4-d3d8-b90a-cf15-fc65a8147099@wwwdotorg.org>","References":"<20170914200634.17818-1-paul.burton@imgtec.com>\n\t<20170914200634.17818-9-paul.burton@imgtec.com>\n\t<195f5fb4-d3d8-b90a-cf15-fc65a8147099@wwwdotorg.org>","MIME-Version":"1.0","X-Originating-IP":"[10.20.1.88]","Cc":"u-boot@lists.denx.de, Stephen Warren <swarren@nvidia.com>","Subject":"Re: [U-Boot] [PATCH 8/8] test/py: vboot: Remove stderr redirect\n\tfrom openssl command","X-BeenThere":"u-boot@lists.denx.de","X-Mailman-Version":"2.1.18","Precedence":"list","List-Id":"U-Boot discussion <u-boot.lists.denx.de>","List-Unsubscribe":"<https://lists.denx.de/options/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=unsubscribe>","List-Archive":"<http://lists.denx.de/pipermail/u-boot/>","List-Post":"<mailto:u-boot@lists.denx.de>","List-Help":"<mailto:u-boot-request@lists.denx.de?subject=help>","List-Subscribe":"<https://lists.denx.de/listinfo/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=subscribe>","Content-Type":"multipart/mixed;\n\tboundary=\"===============3870943258107184068==\"","Errors-To":"u-boot-bounces@lists.denx.de","Sender":"\"U-Boot\" <u-boot-bounces@lists.denx.de>"}}]