(PUP-1255) Fix assumed default file mode to 0644

When a file is created with content, the assumed default mode should be 0644,
but this wasn't being explicitly set.  The secure file replacement (in
Puppet::Util.replace_file) was instead defaulting to a file mode of 0600.
The assumed default mode is now explicitly set when calling replace_file.

The code path for file creation without content continues to set a umask of
0022 if no mode is specified on the resource, so new files are implicitly
created with a mode of 0644.
(PUP-1255) Don't use POSIX defaults on Windows

If the POSIX default mode of 0644 is used when creating files on windows the
SYSTEM ACE is lost on files that are not meant to have thier mode managed. This
updates the replace_file method to understand that a nil default mode really
means to use the platform dependent default.
Merge pull request #2203 from kylog/issue/master/pup-1255-incorrect-default-permissions

Issue/master/pup 1255 incorrect default permissions