[klibc] [klibc:master] dash: builtin: Default to mktemp, not tempfile

klibc-bot for Andrej Shadura andrew.shadura at collabora.co.uk
Tue Apr 27 18:12:09 PDT 2021


Commit-ID:  aa2da3349dbaa2d3ba9d40cb07ea0e675f27592b
Gitweb:     http://git.kernel.org/?p=libs/klibc/klibc.git;a=commit;h=aa2da3349dbaa2d3ba9d40cb07ea0e675f27592b
Author:     Andrej Shadura <andrew.shadura at collabora.co.uk>
AuthorDate: Fri, 7 Sep 2018 10:34:11 +0200
Committer:  Ben Hutchings <ben at decadent.org.uk>
CommitDate: Tue, 27 Apr 2021 23:58:21 +0200

[klibc] dash: builtin: Default to mktemp, not tempfile

[ dash commit ad072645af04c31300c84d2840fcf1a8d48588ec ]

Don't use tempfile, as it currently runs tempnam(), which is insecure
and fails under pseudo(1).

Signed-off-by: Andrej Shadura <andrew.shadura at collabora.co.uk>
Signed-off-by: Herbert Xu <herbert at gondor.apana.org.au>
Signed-off-by: Ben Hutchings <ben at decadent.org.uk>

---
 usr/dash/mkbuiltins | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/usr/dash/mkbuiltins b/usr/dash/mkbuiltins
index 70308bd8..94b36b95 100644
--- a/usr/dash/mkbuiltins
+++ b/usr/dash/mkbuiltins
@@ -35,7 +35,7 @@
 #
 #	@(#)mkbuiltins	8.2 (Berkeley) 5/4/95
 
-tempfile=tempfile
+tempfile=mktemp
 if ! type tempfile > /dev/null 2>&1 && ! type mktemp > /dev/null 2>&1; then
 	_my_tempfile()
 	{


More information about the klibc mailing list