fixed handling of permissions page in python 3