From: Eric Wong Date: 2011-11-19T17:32:25+09:00 Subject: [ruby-core:41155] Re: IO.copy_stream creates files with restrictive permissions Tanaka Akira wrote: > 2011/11/9 Eric Wong : > > I'm not sure if this is a bug or intended as spec. > > > > I noticed when a file name argument is passed to the IO.copy_stream, the > > newly-created destination file has 0600 perms and is not respecting my > > normal umask (0022). > > Sometimes the convention, 0666 by default, causes security problem: > It causes world writable files if users forget to set correct umask. Thank you for your response. I still prefer 0666 personally, but I respect your/matz's decision and will remember to chmod :> Is there a plan to change File.open(path, "w") to be consistent with IO.copy_stream behavior in Ruby 2.0?