CB-5416 - Adding support for auto-managing permissions

r?