From: Bart Schaefer <schaefer@brasslantern.com>
To: zsh workers <zsh-workers@zsh.org>
Subject: Re: Insecure tempfile creation
Date: Mon, 22 Dec 2014 18:07:18 -0800 [thread overview]
Message-ID: <141222180718.ZM7093@torch.brasslantern.com> (raw)
In-Reply-To: <CAHYJk3SuwsxGG22+xEV7D9vh_zFOMSrXXCh_Xvg8P_DqxSAfMg@mail.gmail.com>
On Dec 22, 11:01pm, Mikael Magnusson wrote:
}
} Your first patch is not the best version of that solution;
}
} +() {
} + ${=${VISUAL:-${EDITOR:-vi}}} $1
} + BUFFER="$(<$1)"
} +} =(print -R "$PREBUFFER$BUFFER")
Even that isn't the best formulation, =(<<<"$PREBUFFER$BUFFER") would
avoid forking the print.
} I don't know what the exec </dev/tty is for, but it can be added back
} if it's needed. I've used this patch for two years and never noticed
} any problems though.
Widgets run with stdin closed, so if the chosen editor doesn't open the
tty or one of the other std*s directly, it breaks without </dev/tty.
next prev parent reply other threads:[~2014-12-23 2:06 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-22 20:36 Daniel Shahaf
2014-12-22 22:01 ` Mikael Magnusson
2014-12-23 2:07 ` Bart Schaefer [this message]
2014-12-28 6:30 ` Bart Schaefer
2014-12-28 7:44 ` [PATCH] " Bart Schaefer
2014-12-28 8:41 ` Bart Schaefer
2014-12-29 0:49 ` Daniel Shahaf
2014-12-29 4:01 ` Bart Schaefer
2015-01-07 22:03 ` Daniel Shahaf
2015-01-08 6:22 ` Bart Schaefer
2015-01-08 6:48 ` Danek Duvall
2015-01-08 8:08 ` Bart Schaefer
2015-01-08 14:10 ` Daniel Shahaf
2015-01-08 14:24 ` Peter Stephenson
2015-01-08 16:35 ` Ray Andrews
2015-01-08 17:40 ` Peter Stephenson
2015-01-09 2:51 ` Mikael Magnusson
2015-01-09 9:02 ` Peter Stephenson
2015-01-09 12:51 ` Peter Stephenson
2015-01-09 13:35 ` Peter Stephenson
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=141222180718.ZM7093@torch.brasslantern.com \
--to=schaefer@brasslantern.com \
--cc=zsh-workers@zsh.org \
/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.vuxu.org/mirror/zsh/
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 NNTP newsgroup(s).