unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Kangas <stefankangas@gmail.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: lx@shellcodes.org, Ihor Radchenko <yantar92@posteo.net>,
	66390@debbugs.gnu.org, schwab@linux-m68k.org,
	michael.albinus@gmx.de, manikulin@gmail.com
Subject: bug#66390: `man' allows to inject arbitrary shell code
Date: Wed, 10 Jan 2024 13:21:09 -0800	[thread overview]
Message-ID: <CADwFkmnTMsOM+z0x8FGPGguMtoD9hLrNt9YfbaJ08KPNKW3EbQ@mail.gmail.com> (raw)
In-Reply-To: <83h6mksaqp.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 21 Oct 2023 10:19:58 +0300")

tags 66390 + security
close 66390 30.1
thanks

Eli Zaretskii <eliz@gnu.org> writes:

>> From: Stefan Kangas <stefankangas@gmail.com>
>>
>> I lost track of this discussion a little bit, but I think we should
>> try to have this fixed in Emacs 29.2.
>
> If we have a reliable solution (a hard-to-satisfy condition, see
> below), yes.
>
>> Is the below patch acceptable?
>
> I'm not sure it is reliable enough.  man.el is an extremely tricky
> package wrt the weird file names it must support (because many man
> pages have weird names and include characters that are not normally
> found in file names).  In particular, who can guarantee that ';' will
> not be part of some man page some day? it's a valid file-name
> character on Posix hosts, isn't it?
>
> So I would be happier with installing this on master instead.
> Distros which consider this a serious vulnerability can always
> cherry-pick the change in their Emacs 29 distributions.

OK, I've now installed the change on master (820f0793f0b).  I'm tagging
the bug "security" to make it easier to find for distro maintainers.

Ihor, I'm copying in you as well, in case you want to add a workaround
for this security-relevant bug to Org mode as well.  AFAIU, org mode
man:// links are vulnerable to a shell injection vulnerability in all
released versions of Emacs, and will continue to be so for users until
they upgrade to 30.1.  See this bug for details.  (Bug#66390)

I'm closing the bug with this message.





  parent reply	other threads:[~2024-01-10 21:21 UTC|newest]

Thread overview: 47+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-07 12:47 bug#66390: `man' allows to inject arbitrary shell code Maxim Nikulin
2023-10-07 13:04 ` Eli Zaretskii
2023-10-07 14:12   ` Max Nikulin
2023-10-07 14:19     ` Eli Zaretskii
2023-10-07 14:29       ` Max Nikulin
2023-10-07 15:10         ` Eli Zaretskii
2023-10-07 15:37         ` Michael Albinus
2023-10-07 15:58           ` Eli Zaretskii
2023-10-07 16:55             ` Michael Albinus
2023-10-07 17:24               ` Eli Zaretskii
2023-10-07 17:45                 ` Michael Albinus
2023-10-07 18:26                   ` Eli Zaretskii
2023-10-08  3:37                     ` Max Nikulin
2023-10-08  5:28                       ` Eli Zaretskii
2023-10-09 15:12                         ` Max Nikulin
2023-10-09 15:52                           ` Eli Zaretskii
2023-10-09 16:30                         ` lux
2023-10-09 16:48                           ` Eli Zaretskii
2023-10-09 17:07                             ` Ihor Radchenko
2023-10-09 17:20                             ` Andreas Schwab
2023-10-10  2:47                             ` lux
2023-10-10  7:43                             ` Stefan Kangas
2023-10-10 12:11                               ` Eli Zaretskii
2023-10-10 12:25                                 ` Stefan Kangas
2023-10-10 11:09                             ` Max Nikulin
2023-10-10 10:54                           ` Max Nikulin
2023-10-10 14:30                             ` lux
2023-10-10 16:21                               ` Andreas Schwab
2023-10-11  3:08                                 ` lux
2023-10-11 10:46                                   ` Max Nikulin
2023-10-20 21:00                                   ` Stefan Kangas
2023-10-21  7:19                                     ` Eli Zaretskii
2023-10-21  7:35                                       ` Andreas Schwab
2023-10-21  7:45                                         ` Eli Zaretskii
2023-10-21  9:19                                           ` Stefan Kangas
2024-01-10 21:21                                       ` Stefan Kangas [this message]
2024-01-11 12:07                                         ` Ihor Radchenko
2024-01-11 14:34                                           ` Max Nikulin
2024-01-11 15:07                                             ` Ihor Radchenko
2024-01-11 15:28                                               ` Eli Zaretskii
2024-01-11 15:37                                                 ` Ihor Radchenko
2023-10-09  2:36                     ` Richard Stallman
2023-10-09 11:04                       ` Eli Zaretskii
2023-10-10 11:56                         ` Richard Stallman
2023-10-11 10:56                           ` Max Nikulin
2023-10-08  3:42                 ` Maxim Nikulin
2023-10-08  5:20                   ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CADwFkmnTMsOM+z0x8FGPGguMtoD9hLrNt9YfbaJ08KPNKW3EbQ@mail.gmail.com \
    --to=stefankangas@gmail.com \
    --cc=66390@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=lx@shellcodes.org \
    --cc=manikulin@gmail.com \
    --cc=michael.albinus@gmx.de \
    --cc=schwab@linux-m68k.org \
    --cc=yantar92@posteo.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).