Create file with proper permissions

 - 0600 permissions
 - Write error when failing to read from file