fix bitwise helper, and implement editing permissions