Fix chmod (restrict modes to 0755, 0644 on files and 0755 on folders).