From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Max Nikulin Newsgroups: gmane.emacs.bugs Subject: bug#66390: `man' allows to inject arbitrary shell code Date: Tue, 10 Oct 2023 17:54:59 +0700 Message-ID: <262ed9fe-b92b-489d-b1f0-5202bfdb088b@gmail.com> References: <83wmvyzir2.fsf@gnu.org> <585dcaf0-358e-4a9d-84d1-6fd9c2c8aec5@gmail.com> <83v8bizf9r.fsf@gnu.org> <1865abb8-16cd-4570-9a8a-87cf9430583d@gmail.com> <875y3iigua.fsf@gmx.de> <83o7hazap7.fsf@gnu.org> <87mswugyoq.fsf@gmx.de> <83jzryz6op.fsf@gnu.org> <87a5sugwcx.fsf@gmx.de> <83h6n2z3tr.fsf@gnu.org> <831qe5znrz.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="37433"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla Thunderbird Cc: 66390@debbugs.gnu.org, michael.albinus@gmx.de To: lux , Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Oct 10 12:55:58 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1qqAP8-0009SY-5b for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 10 Oct 2023 12:55:58 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qqAOs-0007OM-Rn; Tue, 10 Oct 2023 06:55:42 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qqAOr-0007O9-Ov for bug-gnu-emacs@gnu.org; Tue, 10 Oct 2023 06:55:41 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qqAOr-0000uX-G8 for bug-gnu-emacs@gnu.org; Tue, 10 Oct 2023 06:55:41 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qqAPC-0007oQ-Bx for bug-gnu-emacs@gnu.org; Tue, 10 Oct 2023 06:56:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Max Nikulin Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 10 Oct 2023 10:56:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 66390 X-GNU-PR-Package: emacs Original-Received: via spool by 66390-submit@debbugs.gnu.org id=B66390.169693533629992 (code B ref 66390); Tue, 10 Oct 2023 10:56:02 +0000 Original-Received: (at 66390) by debbugs.gnu.org; 10 Oct 2023 10:55:36 +0000 Original-Received: from localhost ([127.0.0.1]:34096 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qqAOl-0007ng-Oo for submit@debbugs.gnu.org; Tue, 10 Oct 2023 06:55:36 -0400 Original-Received: from mail-lf1-x12b.google.com ([2a00:1450:4864:20::12b]:49263) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qqAOf-0007nI-MA for 66390@debbugs.gnu.org; Tue, 10 Oct 2023 06:55:34 -0400 Original-Received: by mail-lf1-x12b.google.com with SMTP id 2adb3069b0e04-5031ccf004cso6662492e87.2 for <66390@debbugs.gnu.org>; Tue, 10 Oct 2023 03:55:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1696935302; x=1697540102; darn=debbugs.gnu.org; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :sender:from:to:cc:subject:date:message-id:reply-to; bh=FJJaXyC4OWBBnDWiy6UC91VT6EUe9V1m7XBxCe2NPyY=; b=S7mDM5axmNvCieChS28MzvHcMk3LKCAsKR6/mgtadH0OZrIVAdrjadXhhE3giNUpyX 0Fe8PXpDbc8yMuoIrtLP6v8IS0t2fVlUCf/dI1goEUZr2L8LBv09ZXHKSfdSRjZdpGGE ceMqplZEcS+FK3uJtL7/UDeTs1Ot96K3EkxZdqVEo9t4E+M78ipay8b1vdy6qx8gHvPg VAepBhw52fWs78pHcT/qbfysIppVHOuLbzGm/di6711eOPLmiNkPWCfa3DOculgs9nC9 7Ns5ETwD1PN6P0W9OUBWpBuIAwAwqGM8XLc/I3AtVXwh0QZJTT9AXfn30Nk0CGOFh+GE gzkQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696935302; x=1697540102; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :sender:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=FJJaXyC4OWBBnDWiy6UC91VT6EUe9V1m7XBxCe2NPyY=; b=ZLRiLcJI2rMN37uiktlsibkEoJuhBFGnylxZMqWDF3yos5upDK+ybhBbYGjSle5yEK NQEV3z28XNpHI18M1KtYxfRKPR2NOPhrwqPah0/FYF5Xu8ccWprZVm8/I7/SZkedu0cm HtDIazKg+YyGxzNxs8ALqKHFkcSjFq67BPMc0wL094uOpXyGDcuVyCaIlxiDkr2oHo06 moR1C3DZUPRk/8H612+6o6BkWG8PXbwFPU6JPzNiiU1/4fdfTacFU/2et8pQHDqSiQGR 2xgyYcl59SNpK/MoneCya4/MQwTpO6pZ98ePcFDz4i2Pq+uy1X+uTXV+AYBc87eYUCbx 2dlQ== X-Gm-Message-State: AOJu0Ywy4MZawftAoB1O5idg9oopExjbe6W7FtiEl3zbf3NpFb6zDUJ7 VIno5f16wmmuRhKWT77yFDE= X-Google-Smtp-Source: AGHT+IE9S9W182Miw98sN2ZyLPQ8NMooM5zy/+2FrzT5Jb9HMUL8YjimOSetjPT3Yva3yGPwVN00KQ== X-Received: by 2002:a19:5e10:0:b0:4f9:5519:78b8 with SMTP id s16-20020a195e10000000b004f9551978b8mr12147469lfb.63.1696935301920; Tue, 10 Oct 2023 03:55:01 -0700 (PDT) Original-Received: from [192.168.0.101] (nat-0-0.nsk.sibset.net. [5.44.169.188]) by smtp.googlemail.com with ESMTPSA id j13-20020ac253ad000000b00504211d2a7bsm1749758lfh.297.2023.10.10.03.55.00 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 10 Oct 2023 03:55:01 -0700 (PDT) Content-Language: en-US, ru-RU In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:272192 Archived-At: On 09/10/2023 23:30, lux wrote: > > Here's my patch and the test cases. Thank you for your attempt to fix the issue. Unfortunately the proposed patch breaks the following case M-x man RET -k man RET That is why I wrote that each word should escaped independently. I am unsure if (man "-k man") should be supported as call with argument.