Added filesystem permission handling