From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.1 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from primenet.com.au (ns1.primenet.com.au [203.24.36.2]) by inbox.vuxu.org (OpenSMTPD) with ESMTP id 3d65ab08 for ; Tue, 21 May 2019 15:43:49 +0000 (UTC) Received: (qmail 1098 invoked by alias); 21 May 2019 15:43:37 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: List-Unsubscribe: X-Seq: 44346 Received: (qmail 11852 invoked by uid 1010); 21 May 2019 15:43:37 -0000 X-Qmail-Scanner-Diagnostics: from mailout1.w1.samsung.com by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.101.2/25454. spamassassin: 3.4.2. Clear:RC:0(210.118.77.11):SA:0(-7.0/5.0):. Processed in 2.953887 secs); 21 May 2019 15:43:37 -0000 X-Envelope-From: p.stephenson@samsung.com X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | Received-SPF: pass (ns1.primenet.com.au: SPF record at _spf.samsung.com designates 210.118.77.11 as permitted sender) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout1.w1.samsung.com 20190521154258euoutp015a2ed5159f869d2c8efbc734311d4747~gvRcmWNlr2183121831euoutp01L DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1558453378; bh=8gXgPB/LeAWZjZyrzVvH2UT+QrBfbgVqhAopO7EMwMc=; h=Subject:From:To:Date:In-Reply-To:References:From; b=E9zaHRm9qWLh414ibsomCKUVc2nyw8V/ZmJ4/DOFTaYI1VAd7XKo+sAEfj6mhvnG+ Orn/Cfc85CP37IDfXzh4iImOwrwy9owQVLnKs72l8/MUosOvHaMbFcTTSCJzdYJTAa 9LiTKPiHgZYvh2NyNAb6V0hwcY5MPbud3Jm3uc54= X-AuditID: cbfec7f5-b75ff700000010e5-07-5ce41c816b6e Message-ID: <1558453375.4997.10.camel@samsung.com> Subject: Re: Zsh - Multiple DoS Vulnerabilities From: Peter Stephenson To: Date: Tue, 21 May 2019 16:42:55 +0100 In-Reply-To: <8241-1558449827.736091@IynH.PVDp.gkHU> X-Mailer: Evolution 3.18.5.2-0ubuntu3.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrHIsWRmVeSWpSXmKPExsWy7djPc7qNMk9iDK795bE42PyQyYHRY9XB D0wBjFFcNimpOZllqUX6dglcGZ2Hb7AX7GOvaNx3kKmB8Q9rFyMnh4SAicT8nROBbC4OIYEV jBL3pi4HSwgJ9DFJtOzPhbB7mSTm/vCGadgzr4cJomE5o8SDWe+ZIRygouMPd0CNOsMo8eTf Q3YI5wKjxIzj/ewg/bwCRhK7959mA7GFBfQljixaBRZnEzCUmLppNiOILSIgKXGt+TSYzSKg KtEw5QnYTZxAuxet3ckMcYeGxIabx5ggZgpKnJz5hAXEZhaQl2jeOhvsJAmBx2wSG1dCJCQE XCQOzDjOCGELS7w6voUdwpaR+L9zPhNEQzujxJpJr9khnB5GiU1H70B1WEv03b4IZHMArdCU WL9LHyLsKPH80j+wsIQAn8SNt4IQR/BJTNo2nRkizCvR0SYEUa0msaNpK1S1jMTTNQoTGJVm IflgFpIPZiGsWsDIvIpRPLW0ODc9tdg4L7Vcrzgxt7g0L10vOT93EyMwFZz+d/zrDsZ9f5IO MQpwMCrx8Fo8fBwjxJpYVlyZe4hRgoNZSYT39KlHMUK8KYmVValF+fFFpTmpxYcYpTlYlMR5 qxkeRAsJpCeWpGanphakFsFkmTg4pRoYbR33GWqYuyU7auf4Gf+T3jSLt31Pa8/0fonpIda7 z8y7tVrxV+iCfaskqlYoMZy2e/Hiy+rlKXxJLllGv15bTHpstsXlcEX7zLhzVgEtF1XiTkju iJiwvZRtEeMHd+sy/+d3FPf/Fhdsml544tFnrSMzmi8u+1vqvOvDtUUrRALzmY+z31vfoMRS nJFoqMVcVJwIAHYcG2ABAwAA X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFmpmkeLIzCtJLcpLzFFi42I5/e/4Xd0GmScxBqcOi1scbH7I5MDoserg B6YAxig9m6L80pJUhYz84hJbpWhDCyM9Q0sLPSMTSz1DY/NYKyNTJX07m5TUnMyy1CJ9uwS9 jM7DN9gL9rFXNO47yNTA+Ie1i5GTQ0LARGLPvB6mLkYuDiGBpYwScx5OY4JIyEh8uvKRHcIW lvhzrYsNoqibSeLJxQPsEM4ZRon1708wQjgXGCUOr/wM1s4rYCSxe/9pNhBbWEBf4siiVWCj 2AQMJaZums0IYosISEpcaz4NZrMIqEo0THkCdhMn0E2L1u5khhi6gUni37V5YIOYBTQlWrf/ hrpJQ2LDzWNQywQlTs58wgJRIy/RvHU28wRGoVlIWmYhKZuFpGwBI/MqRpHU0uLc9NxiI73i xNzi0rx0veT83E2MwAjYduznlh2MXe+CDzEKcDAq8fA+uPc4Rog1say4MvcQowQHs5II7+lT j2KEeFMSK6tSi/Lji0pzUosPMZoCfTSRWUo0OR8YnXkl8YamhuYWlobmxubGZhZK4rwdAgdj hATSE0tSs1NTC1KLYPqYODilGhhZUjsPazb0CkYLn/51g+cqy0F/Aa5bGQLnKi46Wln67vcq 5tQ6vuq88cxChdDdjAWLLwhfeRV6o8nksuW7+Ro7bskt33SN/enWQ0t8Dzc67X+/8Hx08ebA XT8qWW39z9kWuXzX3i1j1vUuyFjb92aDX5rWAaeILT6JH5eIiCnXz/as+he+c48SS3FGoqEW c1FxIgCZ2N73lgIAAA== X-CMS-MailID: 20190521154256eucas1p1f0816d2467abd8bf4a0c31058af2983a X-Msg-Generator: CA Content-Type: text/plain; charset="utf-8" X-RootMTR: 20190521154256eucas1p1f0816d2467abd8bf4a0c31058af2983a X-EPHeader: CA CMS-TYPE: 201P X-CMS-RootMailID: 20190521154256eucas1p1f0816d2467abd8bf4a0c31058af2983a References: <21436-1557865831.121649@2P7I.HAU9.QsaG> <889eb5518ad0f98899ba24c2f3e95a87f7cc3df6.camel@ntlworld.com> <8241-1558449827.736091@IynH.PVDp.gkHU> On Tue, 2019-05-21 at 16:43 +0200, Oliver Kiddle wrote: > The following patch is one approach to fixing the last of these bugs. >  > There may be a cleaner approach relying on the WC_SUBLIST_END tags, > probably involving removing this whole block which is looking ahead to > the next wordcode rather than leaving it for the next iteration of the > big loop. But that would be a much bigger change with a greater chance > of breaking things. OK, so this takes account of the fact that "!" on its own (no following command line) is allowed and just means negate the status.  That certainly seems a reasonable way to go. I was wondering whether this actually shouldn't be a special case in the parser, but it's not obvious what to do there --- there actually is nothing following the "!" and pretending there is something isn't a great fix.  Telling the wordcode handler it can work this way is probably a better idea. Cheers pws