# How to investigate permission issues (navigation panel not loading)

**URL:** <https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668>\
**Category:** Help / Discuss\
**Created:** [June 13, 2023, 11:48am UTC](https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668 "2023-06-13T11:48:59Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![watery](https://forum.xwiki.org/user_avatar/forum.xwiki.org/watery/32/4228_2.png) [@watery](https://forum.xwiki.org/u/watery)\
**Post date:** [June 13, 2023, 11:48am UTC](https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668/1 "2023-06-13T11:48:59Z")

</div>

Xwiki version: 14.10.5

I have a user whose nav panel looks like this:

![immagine](https://forum.xwiki.org/uploads/default/original/2X/d/ddd3ec61d3b5da7c148cd2ce2d59269ddd9ca970.png)

On the particular issue of the navigation panel, I checked:

> [@Navigation Panel not loading](https://forum.xwiki.org/t/navigation-panel-not-loading/7031):
>
> Hi everyone, I don’t know what is wrong with my wiki but the navigation tree isn’t loading for non admin users. I already changed the rights of the panel to make it visible to AllWikiUsers. That’s what I’m getting: Please help 2020-06-15T04:00:00Z (UTC)

but I see no DocumentTree among the requests.

All the web requests end in 200, except for:  
`http://<host>:8080/xwiki/bin/view/Main/$escapetool.xml($ssxHref)` =\> 404

The XWiki page is, as correctly guesses, denied to anybody - I set very strict permissions on this wiki because it is meant to contain information to be shared among several actors in our company.

If I give to the user group this user belongs to the _View_ on Xwiki page in _Page & Children_ the navigation panel gets populated, but with a bit too much entries:

![immagine](https://forum.xwiki.org/uploads/default/original/2X/5/5f2e65bb59dff28fb95ee7e0990ddc075fab43c4.png)

The first two entries are the pages this user should see; I can accept the Xwiki Syntax Guide, but not the user profiles pages.

If I, instead, set the same permissions permission only in _Page_, the Navigation Panel doesn’t load at all (so it is back like in the first screenshot)

Other threads either had no replies beside the opening post, or led to nothing.

Expanding on the Home page for the target user:

 ![immagine](https://forum.xwiki.org/uploads/default/original/2X/b/b0cabbac405ef2da83479035942e98622777d43f.png)

The _home_ icon in the breadcrums and the menu label on the right are both missing, so maybe this gives you an hint on what am I missing.

Beside this question, is there a proper procedure / utility to follow to check these permission issues?

---

<div class="post-metadata">

**Author:** ![watery](https://forum.xwiki.org/user_avatar/forum.xwiki.org/watery/32/4228_2.png) [@watery](https://forum.xwiki.org/u/watery)\
**Post date:** [June 13, 2023, 11:57am UTC](https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668/2 "2023-06-13T11:57:14Z")

</div>

A little more information on our setup.

These are the relevant groups we have:

Several users fall into the _Admin_ group and have full control on the wiki.  
A bunch of others (like the one because of whom I started this thread) falls into _Employees_ and start with no permissions at all.

![immagine](https://forum.xwiki.org/uploads/default/original/2X/1/1cc889d97826042d19b86dc075fb8a9cfafb14dc.png)

This is the target page (as an admin sees it):

![immagine](https://forum.xwiki.org/uploads/default/original/2X/3/3ce54d99ee33d873e4a192cb3b929c50d283c114.png)

and these are the permissions actually set:

![immagine](https://forum.xwiki.org/uploads/default/original/2X/a/a59d7a1a1343528a0ec60f86b3fc04e48e7b3b90.png)

My user correctly sees the page content and that page child page:

![immagine](https://forum.xwiki.org/uploads/default/original/2X/8/81b9182548243ebe6ca7582965f8e7e7346a71ca.png)

---

<div class="post-metadata">

**Author:** ![watery](https://forum.xwiki.org/user_avatar/forum.xwiki.org/watery/32/4228_2.png) [@watery](https://forum.xwiki.org/u/watery)\
**Post date:** [June 13, 2023, 12:13pm UTC](https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668/3 "2023-06-13T12:13:59Z")

</div>

I just spotted another strange thing.

This is the user profile page, opened from the user session. The page title isn’t rendered, but holds the LDAP username instead; though the _Created_ and _Last modified_ user names are correctly rendered.  
And the page is empty, although is this user page (but this may make sense given that no permission are given around).

![immagine](https://forum.xwiki.org/uploads/default/original/2X/2/2beb1e37e02f35909f2566f4522ac559109ccda3.png)

Strangely, there’s no “Loading…” in the navigation panel, here.

and the only request that ends in error is

`http://<host>:8080/xwiki/bin/view/XWiki/$escapetool.xml($ssxHref)` =\> 403 (instead of 404)

Oh, forgot to tell out XWiki version, I’m adding it to the first post.

---

<div class="post-metadata">

**Author:** ![watery](https://forum.xwiki.org/user_avatar/forum.xwiki.org/watery/32/4228_2.png) [@watery](https://forum.xwiki.org/u/watery)\
**Post date:** [June 16, 2023, 7:26am UTC](https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668/4 "2023-06-16T07:26:46Z")

</div>

Any suggestion? Even pointers to source files may help.

---

<div class="post-metadata">

**Author:** ![mflorea](https://forum.xwiki.org/user_avatar/forum.xwiki.org/mflorea/32/49_2.png) [@mflorea](https://forum.xwiki.org/u/mflorea)\
**Post date:** [June 16, 2023, 8:27am UTC](https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668/5 "2023-06-16T08:27:28Z")

</div>

> [@watery](#):
>
> but I see no DocumentTree among the requests.

Because the tree is now using a **POST** request to fetch its data (in order to avoid too long URL when excluded pages are part of the request). You should look for a POST request for the current page which has this in the request body:

```auto
sheet=XWiki.DocumentTree

```

You need to give view right to these two pages: `XWiki.DocumentTree` and `XWiki.DocumentTreeMacros`.

Hope this helps,  
Marius

---

<div class="post-metadata">

**Author:** ![watery](https://forum.xwiki.org/user_avatar/forum.xwiki.org/watery/32/4228_2.png) [@watery](https://forum.xwiki.org/u/watery)\
**Post date:** [June 16, 2023, 2:18pm UTC](https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668/6 "2023-06-16T14:18:07Z")

</div>

> [@mflorea](#):
>
> Because the tree is now using a **POST** request […]

Ha, thanks.

> [@mflorea](#):
>
> You should look for a POST request for the current page which has this in the request body:
> 
> ```auto
> sheet=XWiki.DocumentTree
> 
> ```

Found it, though I’m not sure about the result.

This the url called:  
`http:/<host>:8080/xwiki/bin/get/Commission***/GETPremiVP/WebHome?`

The request body:  
`outputSyntax=plain&sheet=XWiki.DocumentTree&showAttachments=false&showTranslations=false&limit=100&data=children&id=%23`

The response is `200` and the body looks like a plaintext version of the page content, here’s an excerpt:

```auto
API GET ***redacted*** (database DB2 SAP)

CAMPO API	CAMPO DATABASE

data_ora_elab	

JOB_COUNTER

num_riga	

RECORD_COUNTER

```

(you may see the page in a previously posted screenshot).

> [@mflorea](#):
>
> You need to give view right to these two pages: `XWiki.DocumentTree` and `XWiki.DocumentTreeMacros`.

If this is the page you meant, I can only administer its parent:

 ![immagine](https://forum.xwiki.org/uploads/default/original/2X/f/f77ef14edf91a1514024b1951b44e5129f1212b0.png)

The same goes for the other page `XWiki.DocumentTreeMacros`, I arrive here:

![immagine](https://forum.xwiki.org/uploads/default/original/2X/5/5bd900b9feca8c9724d8c5f62fec9cbda3479b9f.png)

and if I change the rights I’m back with what I posted in my first post: the navigation panel shows too many pages - even other users profile pages become viewable.

---

<div class="post-metadata">

**Author:** ![watery](https://forum.xwiki.org/user_avatar/forum.xwiki.org/watery/32/4228_2.png) [@watery](https://forum.xwiki.org/u/watery)\
**Post date:** [June 16, 2023, 2:46pm UTC](https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668/7 "2023-06-16T14:46:11Z")

</div>

Wait, if I search `XWiki.DocumentTree` in _Page Index_, a _Rights_ link is offered:

![immagine](https://forum.xwiki.org/uploads/default/original/2X/3/3a329e65b653bc84c1ee193b1bfb45cf2dea7cc9.png)

If I click it, I land on this page:

![immagine](https://forum.xwiki.org/uploads/default/original/2X/3/3c1688a9be418fbe880a2490d6f4d6e50f31db64.png)  
_(after confirming the warning that the page belongs to an extension or an application)_

Is this the page you were referring to?  
But, anyway, changing the rights in that table didn’t have any effect on the user navigation panel ☹

---

<div class="post-metadata">

**Author:** ![mflorea](https://forum.xwiki.org/user_avatar/forum.xwiki.org/mflorea/32/49_2.png) [@mflorea](https://forum.xwiki.org/u/mflorea)\
**Post date:** [June 19, 2023, 6:44am UTC](https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668/8 "2023-06-19T06:44:54Z")

</div>

> [@watery](#):
>
> The response is `200` and the body looks like a plaintext version of the page content,

That’s normal because it’s a request for the current page with a **sheet** that the current user doesn’t have view right on so it falls back on displaying the current page.

> [@watery](#):
>
> If this is the page you meant, I can only administer its parent:

It’s a **terminal** page, so you need to look in the Edit drop down menu.

> [@watery](#):
>
> Is this the page you were referring to?

This is one of the pages I mentioned. The other is `XWiki.DocumentTreeMacros`.

> [@watery](#):
>
> But, anyway, changing the rights in that table didn’t have any effect on the user navigation panel ☹

Have you also give view rights for the second page I mentioned?

---

<div class="post-metadata">

**Author:** ![watery](https://forum.xwiki.org/user_avatar/forum.xwiki.org/watery/32/4228_2.png) [@watery](https://forum.xwiki.org/u/watery)\
**Post date:** [June 19, 2023, 11:47am UTC](https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668/9 "2023-06-19T11:47:11Z")

</div>

> [@mflorea](#):
>
> It’s a **terminal** page, so you need to look in the Edit drop down menu.

Ah, I didn’t look there. May I propose to move it to the other dropdown menu or has it already been discussed in the past?

> [@mflorea](#):
>
> Have you also give view rights for the second page I mentioned?

Oops, I hadn’t.

Now I had given the _View_ permission to both and the menu is populated as expected 🥳

![immagine](https://forum.xwiki.org/uploads/default/original/2X/9/9560ecab7e4ce2cc7d4337bcd7e5e9442628847b.png)

Before editing, a warning stated that I was changing a page belonging to an extension (or to XWiki I don’t recall ATM): will I loose the changes in access rights when I update XWiki?

---

<div class="post-metadata">

**Author:** ![mflorea](https://forum.xwiki.org/user_avatar/forum.xwiki.org/mflorea/32/49_2.png) [@mflorea](https://forum.xwiki.org/u/mflorea)\
**Post date:** [June 19, 2023, 4:58pm UTC](https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668/10 "2023-06-19T16:58:00Z")

</div>

> [@watery](#):
>
> Before editing, a warning stated that I was changing a page belonging to an extension (or to XWiki I don’t recall ATM): will I loose the changes in access rights when I update XWiki?

There should be a merge normally, so your access rights settings should be kept AFAIK.

---

<div class="post-metadata">

**Author:** ![watery](https://forum.xwiki.org/user_avatar/forum.xwiki.org/watery/32/4228_2.png) [@watery](https://forum.xwiki.org/u/watery)\
**Post date:** [June 19, 2023, 8:48pm UTC](https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668/11 "2023-06-19T20:48:47Z")

</div>

Great, thank you.

Now back to the main topic of the thread: how would I discover these kind of permission requirements? Since I have a group with no permissions, I’ll surely step into other issues.

Is there some log, some admin settings that could help me find why a certain page isn’t viewable to a user, or are the sources the only way to learn this?

---

<div class="post-metadata">

**Author:** ![Simpel](https://forum.xwiki.org/user_avatar/forum.xwiki.org/simpel/32/3655_2.png) [@Simpel](https://forum.xwiki.org/u/Simpel)\
**Post date:** [June 20, 2023, 3:25pm UTC](https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668/12 "2023-06-20T15:25:15Z")

</div>

Hi.

I made two snippets to investigate page access problems.

The first one will show you all rights set in any way. But it list them only for that wiki where this script is running: [https://snippets.xwiki.org/xwiki/bin/view/Extension/List%20all%20rights%20(XWikiRights%20and%20XWikiGlobalRights)/](https://snippets.xwiki.org/xwiki/bin/view/Extension/List%20all%20rights%20%28XWikiRights%20and%20XWikiGlobalRights%29/).

If you want to check the effective rights of all users and groups for a specific page then I use this: [https://snippets.xwiki.org/xwiki/bin/view/Extension/Check%20user%20and%20group%20rights%20for%20a%20specific%20page/](https://snippets.xwiki.org/xwiki/bin/view/Extension/Check%20user%20and%20group%20rights%20for%20a%20specific%20page/) Here you can define a sub wiki if you want. This one can take some time if you have many users/groups.

Simpel

PS: And the rule is: if you set an explicit view right to someone (user/group) all others with no explicit allowance wouldn’t see it. That’s what the first snippet is useful to check this.

---

<div class="post-metadata">

**Author:** ![watery](https://forum.xwiki.org/user_avatar/forum.xwiki.org/watery/32/4228_2.png) [@watery](https://forum.xwiki.org/u/watery)\
**Post date:** [June 20, 2023, 10:47pm UTC](https://forum.xwiki.org/t/how-to-investigate-permission-issues-navigation-panel-not-loading/12668/13 "2023-06-20T22:47:31Z")

</div>

Thank you, will check them ASAP.
