new permissions algorithm and changes tracking