From: Eric Wong Date: Fri, 17 Sep 2021 12:12:30 +0000 (-0500) Subject: script/lei: umask(077) before execve X-Git-Tag: v1.7.0~350 X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;ds=sidebyside;h=3ba7362f0bf1bef8ddc76cd311576d9348a94fe0;p=public-inbox.git script/lei: umask(077) before execve While my MUA also runs umask(077) unconditionally, not all MUAs do. Additionally, pagers may support writing its buffer to disk, so ensure anything else we spawn has umask(077). --- diff --git a/script/lei b/script/lei index 2d84487a..591013e3 100755 --- a/script/lei +++ b/script/lei @@ -53,6 +53,7 @@ my $exec_cmd = sub { } my %env = map { split(/=/, $_, 2) } splice(@argv, $argc); @ENV{keys %env} = values %env; + umask 077; exec(@argv); warn "exec: @argv: $!\n"; POSIX::_exit(1);