From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Mike Kupfer Newsgroups: gmane.emacs.bugs,gmane.emacs.orgmode Subject: bug#68687: Org mode code evaluation (was: bug#68687: [PATCH] Use text/org media type) Date: Tue, 30 Jan 2024 09:12:49 -0800 Message-ID: <28314.1706634769@alto> References: <6d94fff4-4d30-4121-bfd1-f267cb5b637c@gmail.com> <8734uqpvgn.fsf@tec.tecosaur.net> <49fa47c0-522a-46d7-ba0d-6e688aa26a8e@gmail.com> <74b83cf9-cd7e-429a-bd9d-0af964e1ddc5@gmail.com> <8634uh5rrq.fsf@gnu.org> <87mssn81dw.fsf@localhost> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7046"; mail-complaints-to="usenet@ciao.gmane.io" Cc: rms@gnu.org, 68687@debbugs.gnu.org, emacs-orgmode@gnu.org, stefankangas@gmail.com, Eli Zaretskii , manikulin@gmail.com To: Ihor Radchenko Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Jan 30 18:14:26 2024 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 1rUrgo-0001eW-Cw for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 30 Jan 2024 18:14:26 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rUrgL-0006ER-LH; Tue, 30 Jan 2024 12:13:57 -0500 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 1rUrgH-0006CA-S5 for bug-gnu-emacs@gnu.org; Tue, 30 Jan 2024 12:13:53 -0500 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 1rUrgH-000485-Jw for bug-gnu-emacs@gnu.org; Tue, 30 Jan 2024 12:13:53 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rUrgQ-00055z-6g for bug-gnu-emacs@gnu.org; Tue, 30 Jan 2024 12:14:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Mike Kupfer Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 30 Jan 2024 17:14:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68687 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 68687-submit@debbugs.gnu.org id=B68687.170663480019528 (code B ref 68687); Tue, 30 Jan 2024 17:14:02 +0000 Original-Received: (at 68687) by debbugs.gnu.org; 30 Jan 2024 17:13:20 +0000 Original-Received: from localhost ([127.0.0.1]:36611 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rUrfk-00054u-Id for submit@debbugs.gnu.org; Tue, 30 Jan 2024 12:13:20 -0500 Original-Received: from shell1.rawbw.com ([198.144.192.42]:13033 ident=root) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rUrfj-00054m-CF for 68687@debbugs.gnu.org; Tue, 30 Jan 2024 12:13:19 -0500 Original-Received: from alto (135-180-173-181.dsl.dynamic.sonic.net [135.180.173.181] (may be forged)) (authenticated bits=0) by shell1.rawbw.com (8.15.1/8.15.1) with ESMTPSA id 40UHCnM3003342 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Tue, 30 Jan 2024 09:12:55 -0800 (PST) (envelope-from kupfer@rawbw.com) X-Authentication-Warning: shell1.rawbw.com: Host 135-180-173-181.dsl.dynamic.sonic.net [135.180.173.181] (may be forged) claimed to be alto In-reply-to: <87mssn81dw.fsf@localhost> Comments: In-reply-to Ihor Radchenko message dated "Tue, 30 Jan 2024 12:13:47 +0000." X-Mailer: MH-E 8.6+git; nmh 1.7.1; Emacs 29.1.90 Content-ID: <28313.1706634769.1@alto> 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:279191 gmane.emacs.orgmode:159464 Archived-At: Ihor Radchenko wrote: > Max is referring to various security issues with evaluating code inside > Org mode buffers. They are known, but not relevant to Org text being > displayed in email MUA - Org never evaluates any code automatically > without user explicitly asking for it. And in MUA, Org mode is simply > used to apply faces. No other interaction with the displayed text/org > mime part is allowed. I can believe that Org text snippets are safe in an email MUA. But in the general case, I don't think Org mode is quite as safe as you implied. The last I heard, conversion from Org mode to another format (e.g., plain text or HTML) can result in code evaluation, without the user authorizing it (see https://debbugs.gnu.org/cgi/bugreport.cgi?bug=48676). I would not expect random users to understand that format conversion is a potentially risky operation. mike From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id cHtTIMAjumVjBwEA62LTzQ:P1 (envelope-from ) for ; Wed, 31 Jan 2024 11:41:04 +0100 Received: from aspmx1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1.migadu.com with LMTPS id cHtTIMAjumVjBwEA62LTzQ (envelope-from ) for ; Wed, 31 Jan 2024 11:41:04 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=fail reason="SPF not aligned (relaxed), No valid DKIM" header.from=rawbw.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1706697664; a=rsa-sha256; cv=none; b=YuXFuUGVo1QDFIaUoOb8vL7IS+CFLBDN1sMO3FiiaczDcvsA3C213XJ/1XPgCriS9NBrs/ PxVO5/IyAoVqTNmc7XImmhNcUBTbyvdB29AuHiuzMIxu8lgFb49UQqTEPxj165ZEoTSI0j IkXVkL4woz8A0LkkkTWWt2JmMCtc4gqvTsNg4oL15hzPndNdZChaAM+QN/RZpb51JxCSD6 N5q7wIRXA1qGsB0p8dJq+jdSpJdMguR5fAabV6B5TOJrlByr7eyaoMHQpVUPcNGiQyFZJe HvNyebObW9gzZk79MY1ToM5T++nPsv8Ghkh32y7chkqBjKsCecFPFQ1G0TL9Eg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=fail reason="SPF not aligned (relaxed), No valid DKIM" header.from=rawbw.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1706697664; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post; bh=UopNVfIiY2KWzTzaK9G1Wgnj6CJcz592i1yNsjd4+n8=; b=ccjD5NXI0hNB5q93u9f9d9NMueTl8wAOijJW8NvFV3t1TIvfkK0hSHWmKgRFfP8GSYv2OY mRK7mGXkIwJtFEJGJNQOql0ILjtyRFe7pVrPKtDxojyLEvHVUbPMMAFJoInzPdqEx+XF2r nFcLNVjaVGnLdcLLoQFoME4/y4EMlYMUZBGk5TlAhDj77nZoCppNWo2DeoliKdv2V693QB c0dlsFLWZUuFl5iwOFjs4Op8ze++PKKgF34uPcdQNNC/eFwAmUg1A065OA3A3ZR0M5oyqa PkPMDSNZSco5n+ON4oJdOlyVrtse0DWZAIExl7isCv6Qcj5gt0JDUnB2eXwaCw== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id D2071762EB for ; Wed, 31 Jan 2024 11:41:03 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rV80k-0007Yk-NS; Wed, 31 Jan 2024 05:40:08 -0500 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 1rUrfe-0005V9-SN for emacs-orgmode@gnu.org; Tue, 30 Jan 2024 12:13:14 -0500 Received: from shell1.rawbw.com ([198.144.192.42]) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rUrfc-0003yu-BM; Tue, 30 Jan 2024 12:13:13 -0500 Received: from alto (135-180-173-181.dsl.dynamic.sonic.net [135.180.173.181] (may be forged)) (authenticated bits=0) by shell1.rawbw.com (8.15.1/8.15.1) with ESMTPSA id 40UHCnM3003342 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Tue, 30 Jan 2024 09:12:55 -0800 (PST) (envelope-from kupfer@rawbw.com) X-Authentication-Warning: shell1.rawbw.com: Host 135-180-173-181.dsl.dynamic.sonic.net [135.180.173.181] (may be forged) claimed to be alto From: Mike Kupfer To: Ihor Radchenko cc: rms@gnu.org, 68687@debbugs.gnu.org, Eli Zaretskii , emacs-orgmode@gnu.org, manikulin@gmail.com, stefankangas@gmail.com Subject: Org mode code evaluation (was: bug#68687: [PATCH] Use text/org media type) In-reply-to: <87mssn81dw.fsf@localhost> References: <6d94fff4-4d30-4121-bfd1-f267cb5b637c@gmail.com> <8734uqpvgn.fsf@tec.tecosaur.net> <49fa47c0-522a-46d7-ba0d-6e688aa26a8e@gmail.com> <74b83cf9-cd7e-429a-bd9d-0af964e1ddc5@gmail.com> <8634uh5rrq.fsf@gnu.org> <87mssn81dw.fsf@localhost> Comments: In-reply-to Ihor Radchenko message dated "Tue, 30 Jan 2024 12:13:47 +0000." X-Mailer: MH-E 8.6+git; nmh 1.7.1; Emacs 29.1.90 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <28313.1706634769.1@alto> Date: Tue, 30 Jan 2024 09:12:49 -0800 Message-ID: <28314.1706634769@alto> Received-SPF: pass client-ip=198.144.192.42; envelope-from=kupfer@rawbw.com; helo=shell1.rawbw.com X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Wed, 31 Jan 2024 05:40:03 -0500 X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Scanner: mx10.migadu.com X-Spam-Score: -3.07 X-Migadu-Queue-Id: D2071762EB X-Migadu-Spam-Score: -3.07 X-TUID: 0iekNLmuMx1w Ihor Radchenko wrote: > Max is referring to various security issues with evaluating code inside > Org mode buffers. They are known, but not relevant to Org text being > displayed in email MUA - Org never evaluates any code automatically > without user explicitly asking for it. And in MUA, Org mode is simply > used to apply faces. No other interaction with the displayed text/org > mime part is allowed. I can believe that Org text snippets are safe in an email MUA. But in the general case, I don't think Org mode is quite as safe as you implied. The last I heard, conversion from Org mode to another format (e.g., plain text or HTML) can result in code evaluation, without the user authorizing it (see https://debbugs.gnu.org/cgi/bugreport.cgi?bug=48676). I would not expect random users to understand that format conversion is a potentially risky operation. mike