backport of CHEF-4662 to 10-stable

- insecure Tempfile perms fixes