Parts of Admin UI not working after removing admin rights from old Wiki-Admin

Hello XWiki community I need help with our instance.

Here is some basic information about our running XWIKI instance

  • XWiki Version: 18.1.0
  • Database: Postgres
  • Deployment Type: Docker Container

How I detected the problem:

When creating a new XWIKI entry from a template, i was unable to copy+paste images to the new entry, there i got an error that the server response was invalid, displaying that user hasn’t enough rights to execute the velocity macro, because he isn’t supposed to be an Wiki-Admin anymore.

The problem is when i give the user back the admin rights everything works as intended. But as soon as i remove them, certain pages of the admin ui and copy-paste/uploaded elements(images) to the entries don’t work anymore.

The error message in the admin UI is:

  • The user that edited the page the last time hasn’t the rights to edit it anymore

The error when copy+pasting or uploading image is:

  • The macro Velocity couldn’t execute because the user doesn’t have right to execute the macro

Did anyone encounter this or a similar issue before? If yes, how where you able to fix it?

Thanks for the help in advance :+1:

Hello, I don’t fully understand your use case but if you had a user who installed pages as admin (with script rights or even PR) and then you remove those rights from this author then the pages created by that author will loose permissions and may not be able to execute scripts anymore (requires script rights for ex).

I can think of the following to try to fix the problem but it’s a bit hackish:

We have an issue for pages installed by a user through the extension manager: Loading... (but it’s not implemented yet).

Simplest in your case could be to give back the rights to that user and then mark it as inactive and create another user.

There is an equivalent extension to replace a user on all pages: https://extensions.xwiki.org/xwiki/bin/view/Extension/Change%20Content%20Author

1 Like

@MichaelHamann @vmassol

Thanks for your fast replies, I will try your recommendations and keep you updated.