Hide “Forgot password” and “Forgot login” links on login page (XWiki 16.10.14, LDAP via xwiki.cfg)

Hello,

I am running XWiki 16.10.14 and my instance is successfully connected to my Active Directory.

LDAP authentication is configured directly in xwiki.cfg, using properties such as:

  • xwiki.authentication.ldap.server

  • xwiki.authentication.ldap.bind_DN

  • etc.

I am not using the LDAP authentication plugin.

Password recovery has already been disabled at configuration level using:

xwiki.authentication.passwordRecovery.enabled=false

Authentication works as expected, however on the login page I still see the following links:

  • “Forgot your password?”

  • “Forgot your login?”

In an LDAP-only context, these links are misleading and should not be displayed, since password management is handled exclusively by Active Directory.

I would like to completely hide these two links from the login page UI (not only disable the feature).

I already tried:

  • Custom CSS via Flamingo theme resources

  • Cache clearing and server restart

But the links are still displayed.

What is the recommended and supported way (in XWiki 16.10.x) to:

  • hide these links permanently

  • without modifying core files

  • and in a LDAP-only authentication setup?

Thank you in advance for your help.

Hi,
I am also having this question using SSO on XWiki 17.10.3. The “Change password” functionality for the user itself is also affected. I was already wondering if I needed to patch this out from the theme sooner or later. I am sure this is possible

Hi @Sebastien,

When working on the login page, keep in mind that before authentication happens the visitor is treated as an Unregistered user. If you’re using CSS to hide certain elements on that page, that CSS must also be accessible to Unregistered users.

So, if your styling is provided through an SSX object in a specific XWiki document, make sure that this document is viewable by Unregistered users. Otherwise, the CSS won’t load for them and the elements you want to hide will still be visible.

Hope it helps,
Alex