This returns permissions as hash.