Working to understand rights

Hi! I’m working hard to understand all new great features and developments inside XWiki, but I’m failing comically at some apparently simple places. For instance: can you help me I’m able to find these three entries if I search for Second entry:

image

Even though I explicitly denied view rights to XWikiGuest?

image

Thanks!

Hello Ricardo,

It seems that the message (*) Displayed when some entries require special rights to be viewed[...] is not clear enough as it’s supposed to tell you why you see these entries in the table :slight_smile:

The XWiki rights system is a complex system that caters for lots of use cases. As such, it’s a computed system and cannot be queried from the data store. It’s a current limitation of XWiki. This means that UIs like the LiveTable or LiveData need to filter out what they display after the query has been made to the data store. However, if they were not displaying a line for all entries, the pagination and total number of entries would be wrong. This is why N/A is used and why we have the legend that tries to explain it.

If you had view rights, then you wouldn’t see N/A but the actual data, so this proves your rights are working.

We need to find a solution for this in the future as it’s not great for a UI/UX POV. But it’s a difficult one and I doubt it’ll be fixed soon.

Hope it helps

2 Likes

It helps, indeed! But I need to read the message several times, think and play a bit to understand how to use it! Thanks, Vicent!

OK. In the meantime, I managed to get rid of N/A messages in the Attachments tab of Page Index. All of them were related to Help and Sandbox applications. I simply remove them.

Please, how could I find the origin of the N/A messages in the Index tab?

It is available online now.

Thanks!

I can use XWQL to investigate further and see which documents require special rights to be displayed. I will do that! Sorry for the noise. Thanks!

It’s not special rights, you just need view rights to view a page.

You cannot get rid of N/A (and it’s not a goal). You get N/A when the current user doesn’t have view rights on some docs. And it’s perfectly all right to have permissions on some docs (like docs that shouldn’t be seen by some users).

Thanks, Vincent.

Why? Let me explain what I want/need differently: if a user has no permission on a document (which is perfectly ok), no trace must be shown about that document in the search results (of any kind) or Page Index.

N/A results (I understand their origin) or weird numbers in results will give users reasons to ask why they get those results. I want to avoid that.

I can avoid issues with N/A by simply hiding the Page Index entry from the right column for those users. I now need to understand how to avoid, for instance, entries about comments or objects in results. If it is possible, and I’m sure it is because with XWiki, everything is possible! :slight_smile:

Currently, the XWiki I’m working with shows only two entries under the Navigation for a guest user. I want to hide even the Query thing ASAP.

All that I want as a result when a guest user searches is a list of three items as much: the page Team, my user profile, and the page Query.

Of course, there will be plenty of other XWiki pages and stuff! But those elements must be visible only for developers (only I so far) and some advanced users.

Could I be wrong, but I will try to introduce complexity very smoothly. I will fail if I try to start with a full set of XWiki features. Again. I’m approaching in a similar way with other tools (Shiny applications, for instance). However, sharing the development of Shiny applications requires infrastructure and skills that are hard to introduce in a highly diverse team. The Team page contains an extremely simple Groovy script many persons will be happy to improve!

I hope this makes sense for you. As always, big thanks!

This is not completely possible. The page reference is currently not something private in XWiki, and there’s no way to fully hide it. Said differently, what is controlled by rights is the page content and metadata, but not its reference.

I’m not sure what you mean by “hiding”. If you mean marking a document as hidden, then a user can decide to show hidden pages. Ofc, if you mean, just hide from the guest user, then since that user doesn’t have a profile, there’s currently no way for a guest to show hidden pages AFAIK so that could work for this special use case of guest.

Thanks

Ah! This is new in my understanding about how XWiki works. Thanks!

Yes, I marked Page index as hidden. As you said, it will work for this particular case. I will play further with the customization of the drawer once I understand how XWiki updates affect the changes I’m doing. If a guest knows and enter the reference of that pages, login will be required. Even in the case of a registered user choosing to see hidden pages by intention, it won’t be an issue: in this case, there will be a reason for going ahead with a more detailed explanation about XWiki foundations and behaviour.

Now, I’ve to keep working with the search results: I’m not able yet to fully understand and predict them!

Note that it also means that any user you create will not see these pages either since they’re hidden. They’ll need to activate “view hidden pages” to view them and then they’ll see all the other hidden pages they’re not supposed to view…

1 Like

Note that if you fear that the page reference might contain confidential information, you could use the random page naming strategy to avoid that.

Thanks, Michael. Good point!

Currently, my only concern is providing users with a straightforward starting point to enjoy XWiki! No worries about confidential information so far! I think I reached that point: just a couple of pages being served by a 15.10.4 XWiki instance. I will ask about the planned next steps in a new thread.

1 Like