fixup permissions