Modified permissions system

I've added a default permissions setting for files; it defaults to
read-only permissions for everything. I have no idea why I didn't
implement this sooner.