Add installation script
Improve permission handling with fallback to global permissions

The global permission belonging to `user.canViewCategory` is `user.packagebase.canViewPackage`.