Implementing set Permissions

still WIP