geemus/netrc — pull request #23 by smblott-github (2014-10-08 11:16:08+00:00)
Title: Be less restrictive on netrc permissions

My `.netrc` permission bits are `0400`, which shouldn't be a problem. However, the test below fails. It seems to be too restrictive.

def self.check_permissions(path)
perm = File.stat(path).mode & 0777
if perm != 0600 && !(WINDOWS) && !(Netrc.config[:allow_permissive_netrc_file])
raise Error, "Permission bits for '#{path}' should be 0600, but are "+perm.to_s(8)
end
end

All that's really required is `.netrc` is not world/group accessible.