Fix various permissions.