Reference/link pages with its children across wikis

Hi,

is there a possibility to reference specific pages and their children in other wikis? I want to create a “virtual subwiki”, which only shows some pages (and their children) from some other subwikis and lets users edit them in this virtual environment. This would have the advantage of easier permission management, since you only have to set them once for the wiki and not for every subpage underneath.

Example:

Subwiki A:
Page A1
Subpage A1.1
Subpage A1.2
Page A2
Subpage A2.1

I want some users to have access to Page A1 and its children but not to Page A2 and its children. Setting this up would require giving users access to Subwiki A (otherwise navigation and a few other system pages would be broken) and restrict their access manually to Page A2 and children. This is very cumbersome to set up, especially for a larger amount of users, a problem which would be solvable through a “virtual wiki”, which only displays Pages A1 and its children and not A2 and children.

There are two macros I am aware of which can “link” or display pages (Display and Include), but both of them are only showing the specified page and not its children.

Is there a possibility to do this somehow?

Thanks in advance!

Hello @Qua8zoh6,

no, such a “permissions feature” doesn’t exist as a standard feature of XWiki, ready to use out of the box, especially since you’d also need editing. For view only you can use display and include and make some scripts to include the children, but for editing this woult require some other layer of custom code, etc.

Maybe others have coded similar bypasses of standard rights system and they can share their experience…

However, these remarks

and

hint that you may not be using XWiki’s permissions system optimally, as:

  • XWiki’s authorization system uses inheritance: you can set the rights at the parent level and have them inherited to all children pages, so you shouldn’t have a need to repeat the access configuration on all subpages. Inheriting rights set at the wiki / subwiki level works exactly the same.
  • The rights inheritance system also works with an “exception” mechanism: you can inherit for all children except for one of the children for which you add some specific rules, so if you have similar access righs for most of your content, you can set those up once and inherit them, and only add specific rules for the exceptions.
  • XWiki’s authorization system uses groups: you can group multiple users in a group and then you just give rights to that group and you don’t need to repeat all the rights to all the users everywhere.

See Access Rights (XWiki.org) and Security Module (XWiki.org) for more information.

Hope this helps,
Anca

We do have quite a lot of departments with a subwiki for each. These subwikis do contain some spaces. From time to time (once every two weeks, maybe) it happens, that one department collaborates with people from other departments on some content in their spaces.

As described in Ho to grant access for a global user to a subwiki space? setting the permissions for this use case is cumbersome and complicated, since we have to grant access to the whole wiki, some spaces and deny it for others, all for one user.

Now, what I may do is either:

  • allow access to only the (sub)page or space, then permissions are easy but everything is broken as the user, although being a user in the global wiki, has no access to the system parts of the subwiki (like page tree, editor, style and so on) or
  • painfully (and manually) disable the users access to any other page in the subwiki and update the permissions every time someone creates a new space in that subwiki.
    Both options are not very tempting.