Using XWiki as an OpenID Connect provider for your other applications
If you want other applications to sign users in with accounts you already manage in XWiki, the xwiki-contrib OpenID Connect project can turn XWiki into an OpenID Connect provider. It supports XWiki 14.10.2 and later and is licensed under LGPL 2.1. The integration method is OpenID Connect, so any client application that speaks OIDC can be registered against the wiki. Whether this fits better than a dedicated identity provider depends on how many applications need sign-in, how much lifecycle and policy control you need over those accounts, and whether your wiki is already the authoritative user store. Confirm the version compatibility of the extension against your exact XWiki line before you commit, since it is only supported from 14.10.2 onward.
The extension is built from four components. The provider exposes the OIDC endpoints that relying applications call. The authenticator lets XWiki users log in against an external OIDC provider, which is the opposite direction and a separate decision. The token authenticator lets XWiki accept tokens issued by a provider when API calls arrive. The consent component records and presents the approval step where a user agrees to share profile data with a client application. Plan the consent behavior explicitly, because a relying application's permission requests and your consent screen wording are what auditors and users will look at. Check with the project's documentation which scopes and claims the provider releases by default.
Before go-live, decide which XWiki group or account attributes map to claims your applications need, and who can register clients. Test token expiry, logout behavior and the redirect URIs you allow, since misconfigured redirects are a common source of account exposure. Note that a wiki is also a place where users edit content and extensions, so the administrators who manage the provider and the people who manage wiki content should be separated where your policy requires it. Ask the extension maintainers and your own security team to confirm the supported flows, the hardening options and how upgrades affect the provider before you rely on it for sign-in to other systems.
When XWiki as a provider makes sense and when a dedicated IdP is the better choice
XWiki as an OpenID Connect provider fits best when the wiki already holds the users and only a few applications need sign-in. The factors below show where that stays sensible and where a dedicated identity provider deserves a closer look before you commit.
Where the user population lives
If most of the people who need sign-in already have XWiki accounts, and the other applications are used mainly by that same group, XWiki can be a reasonable source of identity. If your staff, contractors and partners sit in directories or HR systems the wiki does not reflect, the wiki becomes a copy of identity data you must keep in sync. Confirm which system is the authoritative source for joiners, movers and leavers before you decide.
Number of client applications
The provider component serves each client application through its own registration, redirect URIs and token settings. Two or three internal tools are a manageable set to maintain on the wiki. Once the estate grows to many applications with different scopes and owners, the registration and review work usually belongs in a product built for that purpose, such as Keycloak, authentik or Zitadel, which are alternatives to evaluate rather than drop-in equivalents.
Need for federation and brokering
Check whether you need to accept logins from external identity providers, or to act as a broker between several of them. The xwiki-contrib project covers the provider role and the authenticator that logs users in against an external OpenID Connect provider. If you expect SAML partners, LDAP user federation or multiple upstream identity sources, confirm in writing what the extension supports and compare it with a dedicated IdP's protocol and federation coverage.
OIDC extension repositoryMFA and lifecycle controls
Multi-factor policies, session controls, account disablement and access reviews are usually handled by the identity layer, not by the wiki's own login screen. Ask which MFA methods your policy requires and whether the wiki can enforce them for every client. If the answer depends on a second system anyway, the wiki is adding a component to your access path rather than removing one, and that cost should appear in the design.
Admin tooling and audit visibility
Your administrators need to see who holds a token, which client received it, and when an account was changed or revoked. Dedicated IdPs ship admin consoles and audit features built for this work, and some are documented with metrics and logging guidance. Before choosing the wiki for this role, have the security team list the reports and audit events they need, then test whether the wiki's administration can produce them in your environment.
Ownership of the wiki and its upgrades
The provider role puts the wiki on the critical path for sign-in to other systems, so an upgrade, outage or misconfiguration of XWiki affects every client. If the wiki team owns content but not operational identity, the split of responsibility will be unclear during an incident. Agree who patches, who tests redirect URIs and who can rotate signing keys before any other application depends on it.
How an application login flows through XWiki as the provider
The flow starts when a user opens a relying application and is redirected to XWiki's authorization endpoint in the browser. XWiki authenticates the user and shows a consent step for the requesting client, then returns a short-lived authorization code through the browser. The relying application's back end exchanges that code directly with XWiki for tokens, which is the hand-off to check: the code exchange must happen server to server, and the client secret must never reach the browser.
Login hand-offs between a relying application and XWiki as the OpenID Connect provider.
What you need before configuring the XWiki OIDC provider
The OpenID Connect provider runs inside XWiki, so the wiki's version, deployment model, TLS setup and hostname become the foundation for every application that will sign in against it. Settle these four decisions and the admin access before any extension work starts, because changing a hostname or certificate later affects every registered relying application.
XWiki version at or above 14.10.2
The xwiki-contrib OpenID Connect project supports XWiki 14.10.2 and later, so that is the floor for this design. Choose a line deliberately: the stable line (18.8.0), the long term support line (17.10.14) or the intermediate LTS line (18.4.7). Stable gets new features sooner, while LTS lines receive a longer maintenance window that suits an identity service. Confirm extension compatibility with your chosen line in the project repository before work starts.
OIDC project repositorySupported deployment model
Run XWiki either from the official Docker images, which come in MySQL, PostgreSQL and MariaDB variants on Tomcat, or as a self-managed Tomcat installation with the database you choose. Identity traffic is sensitive, so the database and the wiki should sit in the same controlled network zone with backups and patching defined. Confirm which database variant your operations team already supports before building.
Docker image docsHTTPS with a trusted certificate
OpenID Connect relies on browser redirects and token exchanges that must run over HTTPS. Every relying application has to trust the certificate chain for the XWiki hostname, including internal certificate authorities if your organization uses them. Check the certificate lifetime, renewal owner and the trust store used by each relying application's runtime, because a certificate that one application rejects will break sign-in for that application only.
Stable public hostname and redirect URIs
The issuer address and the redirect URIs registered by each client are compared exactly during login. Pick a permanent hostname for the identity role, such as a dedicated name rather than a personal or temporary one, and write down the redirect URI pattern for each application before configuration. Changing the hostname later means re-registering every client and re-issuing trust, so treat this as a design decision, not a detail.
Admin account for extension installation
Installing and configuring the extension requires a wiki administrator account with rights to add extensions and edit wiki-wide configuration. Keep this account separate from day-to-day editor accounts, assign it to named people, and record who holds it. The same admin rights can change which users and groups receive tokens, so access to it is part of the identity control set.
Configuring XWiki as an OIDC provider step by step
This sequence takes a test XWiki instance from a fresh install of the xwiki-contrib OpenID Connect extension to a verified login by one relying application, with each step ending in a check you can repeat before anything reaches production.
Install the OIDC extension on a test instance
Start with a test XWiki instance that matches the version you plan to run in production. The xwiki-contrib OpenID Connect project supports XWiki 14.10.2 and later, so confirm your version against the project's documentation before installing. Install the provider components on that instance, keep the test instance off the public internet, and restart it as the installation requires. The step is done when the extension appears in the installed extensions list and the wiki starts cleanly with no errors in the logs.
Configure provider settings and signing keys
Set the issuer URL to the exact public HTTPS address users and applications will reach, because relying applications compare it against the issuer value in tokens. Generate or import the key pair used to sign tokens and record where the private key is stored and who can read it. Confirm with your security team how the keys will be backed up and rotated. The check is that the discovery document loads from the well-known OpenID configuration path and lists the issuer, authorization, token and JWKS endpoints you expect.
Register each relying application as a client
For every application that will sign in through XWiki, create a client entry with a client identifier, a client secret stored in your secrets manager, and the exact redirect URIs the application uses. Limit scopes to the claims the application needs, such as profile and email, and avoid granting broad scopes by default. Record the owner of each client so later reviews can remove unused entries. The check is a test authorization request for each client that returns to its redirect URI with a code and no error.
Set the consent behavior
Decide, per client, whether users see a consent screen. Internal first-party applications may not need one, while third-party or broadly scoped clients usually should show what data they receive. Configure the consent component so the screen appears on the first authorization for a user and client pair, then does not reappear on later sign-ins unless the scopes change. Confirm the behavior with a user who has not yet consented to that client, and check that a second sign-in skips the screen.
Enable the token authenticator for API use
Turn on the token authenticator so that API clients can present an access token issued by XWiki instead of a browser session. Limit which clients may use token-based access, and confirm that tokens expire within the lifetime your policy allows. Test one API call with a valid token, one with an expired token and one with a token from a client that is not authorized, and confirm that only the first succeeds. Keep the test tokens out of logs and shared documents.
Test a full login and token exchange
Sign in through a test relying application from a clean browser session. Confirm that the redirect reaches XWiki, the user authenticates, consent appears only if it should, and the application receives an authorization code that it exchanges for tokens. Decode the ID token and check the issuer, audience, subject and expiry claims. Repeat the test with a user who is not permitted to use the client, and record the result. The sequence is complete when every relying application passes the same test and the results are documented for your security review.
How XWiki user profile fields map to OIDC claims
This table compares each OpenID Connect claim a relying application may request with the XWiki user property or group design that usually supplies it. Read it as a checklist: confirm each row against what every relying application expects before you publish the provider configuration, because the mapping is only as good as the data behind it.
| Claim | Typical XWiki source | What to confirm |
|---|---|---|
| sub (subject) | A stable identifier for the XWiki user, such as the user's document reference rather than a display name | Subject must not change when a user is renamed or moved. Test a rename on a non-production instance and confirm relying apps still match the same account. |
| The user's email property in the XWiki profile | Whether relying apps require verified email. XWiki profile emails are user-editable unless you restrict them, so confirm who can change them. | |
| name, given_name, family_name | First name, last name and the combined display name in the user profile | Whether apps use name for display only or for matching accounts. Profiles left blank will send empty values. |
| preferred_username | The XWiki login name | Whether relying apps treat this as a unique key. Login names are not always suitable as long-term identifiers. |
| groups (custom claim) | Membership in XWiki groups, which must be designed for access before they are exported | Group claims depend on how XWiki groups are organized. Nested or legacy groups may need flattening, and each relying app must accept the group names you send. |
| Custom claims | Additional profile properties or attributes added through configuration | Each custom claim needs a named consumer. Remove claims no relying application reads, and confirm personal data in them is justified. |
How consent and token components change what each application can see
The consent component decides what each client application is allowed to see about a user, and it is the control you will revisit most often once XWiki is the identity provider. Each client should be registered with only the scopes and user claims it needs, and the consent record shows what a given user agreed to share with that client. Confirm in your chosen xwiki-contrib OpenID Connect version whether consent is prompted to users, auto-approved for trusted internal clients, or both, and whether an administrator can review or revoke stored consent from the interface. Treat any internal application that receives a broad scope as a decision to document, not a default to accept.
The token authenticator validates the tokens that clients present when they call XWiki or other protected services, so it is the point where token lifetimes and scope limits take effect in practice. Lifetimes for access tokens, refresh tokens and ID tokens are the settings that determine how long a stolen or forgotten session stays usable. Do not assume the default values shipped with the extension. Read the configuration for each token type in the release you deploy, set shorter lifetimes for privileged clients, and test that an expired token is rejected by a client you control.
Revocation behavior needs its own test plan. Confirm whether revoking consent, disabling a user, or ending a session invalidates tokens already issued, or only prevents new ones, and document the gap that remains until a token expires. Run that test against each client before go-live, record the results, and repeat the check after every XWiki or extension upgrade, because behavior in these components can change between versions. The outcome of this review should be a per-client table of scopes, lifetimes and revocation results that your security team can sign off.
Hardening the XWiki provider before other applications depend on it
Once XWiki issues tokens for other applications, a weak signing key, a loose redirect URI or an unmonitored consent screen affects every client that trusts it. The cards below cover the controls to set and verify before the first client goes live. Confirm each control against the xwiki-contrib OpenID Connect project documentation for your XWiki version, since the supplied facts do not describe its configuration options in detail.
Signing key lifecycle
The provider signs the tokens that every client accepts, so the signing key is the most sensitive item in the design. Decide where the private key is generated and stored, who can read it, and how it is replaced. Plan a rotation window in which clients can fetch the new public key before the old one is retired. Ask the project how the key is loaded at startup and whether rotation requires a restart. Test a rotation in a staging instance before relying on it.
Exact redirect URI matching
An open redirect URI lets an attacker send an authorization code to a host they control. Register each client with the full callback URL, including scheme, host, port and path, and avoid wildcards and shared callback paths. Review the list whenever a client is added or its hostname changes. Confirm with the project whether exact string matching is enforced for every flow the extension supports, and test a near-miss URI to see whether it is rejected.
HTTPS-only endpoints
Authorization, token, userinfo and discovery endpoints carry credentials and tokens, so they must be served only over TLS. Terminate TLS with certificates you manage, redirect plain HTTP to HTTPS, and confirm that the discovery document advertises HTTPS URLs. Clients should be configured to reject non-HTTPS issuers. Check how the wiki's reverse proxy forwards the original scheme, because a mismatch can cause issuer and redirect errors that tempt teams to weaken the check.
Administrator access to provider settings
Anyone who can edit the provider configuration can add a client, change a redirect URI or swap a key. Limit administration to a named group, separate it from general editing rights, and review that group on a schedule. Confirm which XWiki rights control the provider configuration pages and whether they can be granted through a group rather than to individual users. Record who changed a client registration and when.
MFA for provider administrators
Administrator accounts can change what every relying application trusts, so they warrant stronger sign-in than ordinary editors. Check whether the authentication setup you chose supports a second factor for XWiki users, or whether you need to front the admin path with an external identity layer that enforces MFA. Confirm this with the project documentation and your own tests, since the supplied facts do not cover XWiki's MFA options.
Login and consent audit trail
Logs of logins, token issuance and consent decisions show which applications received access and when. Decide what each event must record, such as user, client, scopes and timestamp, and where those logs are shipped and retained. Confirm which events the extension writes to the XWiki log and whether they can be forwarded to a central store. Test that a denied consent and a failed login both leave a record.
Separating the provider from wiki editing
Running the provider on the same instance that hosts day-to-day wiki editing couples its availability and upgrade schedule to content work. Consider a dedicated XWiki instance for the provider, with a restricted set of extensions and a smaller editing population. Weigh this against the cost of a second deployment and the added network path. Confirm with the project whether the provider can run in a separate instance without the wiki content it does not need.
Common failures when XWiki issues tokens to other apps
This table lists the failures teams most often hit when XWiki acts as the OpenID Connect provider, with the likely cause and first fix for each. Read it while testing a relying application, since most failures show up as a login loop, a rejected token or an empty group list rather than a clear error.
| Failure | Likely cause | Fix |
|---|---|---|
| Redirect URI mismatch | The redirect URI registered for the client in XWiki differs from the callback the application sends, often by scheme, host, port or trailing slash. | Copy the exact callback URL from the application configuration into the client registration, then test with a fresh browser session. |
| Discovery URL unreachable | The application calls the provider's well-known configuration endpoint, but the reverse proxy exposes XWiki under a different external host or blocks the path. | Set the public base URL in XWiki to the external address, allow the discovery path through the proxy, and confirm it returns a valid issuer from inside the application network. |
| Issuer mismatch in tokens | The issuer value in tokens reflects an internal hostname or HTTP scheme, so the relying application rejects it against its configured issuer. | Align the external URL seen by XWiki with the issuer the application expects, including scheme and port, and retest token validation. |
| Clock skew rejects tokens | Application and XWiki hosts disagree on time, so tokens appear issued in the future or already expired. | Run time synchronization on every host, confirm the offset between servers, and allow only the small tolerance your application validator permits. |
| Missing consent records | The user has not granted consent for the client, or consent was stored for a different client or scope set, so the authorization step repeats or fails. | Check the consent entries for the affected user and client, confirm the requested scopes match what was approved, and re-run consent after changing scopes. |
| Group claims empty | Group membership in XWiki does not map to the claim the application reads, or groups are nested or named in a way the claim mapping does not expose. | Review how group names are emitted, keep groups flat and named for their purpose, and confirm the claim appears in a test token before changing the application. |
| Session or logout mismatch | The XWiki session and the application session end at different times, so a user stays signed in to one side or is sent back to a login loop after logout. | Define logout behavior for each relying application, test single logout and local logout separately, and confirm cookie domain and lifetime settings on both sides. |
| Client secret or authentication method mismatch | The application sends a client authentication method or secret that does not match the client registration after a rotation or copy error. | Rotate the secret through a controlled change, store it in the application secret store, and confirm the authentication method on both sides. |
Testing the provider and keeping it running after go-live
Test the provider against a written plan before any client application goes live, and treat each case as a pass or fail with an expected result. Run a successful login for every registered client, confirming that the ID token carries the claims that client expects and that the user lands back on the application. Then run a denied consent: sign in as a user, decline the consent screen the xwiki-contrib OIDC consent component presents, and confirm the client receives an error and no token. Run a failed login with a wrong redirect URI, which the provider should reject. Also remove a user from a group that drives access in a client, then sign in again and confirm the application no longer grants the old rights. Finally, test expired and revoked tokens: let an access token expire, check that the client refreshes or re-authenticates as designed, and confirm that a revoked session or token stops working at the client. Record the XWiki version, extension version and client configuration used for each run, so a failure can be traced later.
Plan for XWiki upgrades as changes to the login path, not routine maintenance. Because every client depends on the provider, an upgrade of XWiki or the OIDC extension can break sign-in for all of them at once. Before upgrading, confirm the target XWiki version is supported by the extension's current release, since the project states support from XWiki 14.10.2 onward, and read the release notes for both. Test the upgrade in a staging instance that mirrors production's clients, redirect URIs and consent settings, then repeat the full test plan above. Keep a rollback path, including a database backup taken before the change. Ask whether the chosen XWiki line has a planned end of support, since moving between lines changes the Java and Tomcat requirements and may require a new extension release.
Operate the provider with monitoring and ownership, because login failures often surface first as user tickets. Watch the XWiki and Tomcat logs for authentication errors and track failed token requests per client. Keep a register of registered clients, their redirect URIs and secrets, and assign an owner for each so that stale or unexpected clients are removed. Schedule the test plan to rerun after every XWiki, Java, Tomcat or extension change and after any change to group structure that affects access. Confirm with your own security team how client secret rotation and certificate or TLS changes are tested, since the provider sits in the authentication path for every application that trusts it.
Questions teams ask before using XWiki as their identity provider
Should we replace our dedicated identity provider with XWiki?
In most organizations, no. XWiki is a wiki and knowledge base first, and the xwiki-contrib OpenID Connect extension lets it act as a provider for other applications, but that role is an addition to its main job rather than a replacement for a purpose-built identity platform. It can make sense when the set of applications that need login is small, when the user base is already managed in XWiki, and when the team accepts that XWiki upgrades will also affect login. If you already run a dedicated identity provider such as Keycloak, the usual choice is to keep identity there and connect XWiki to it as a client. Confirm the requirement for federation, multi-factor policy, lifecycle and audit before deciding.
What drives the effort and cost of an OpenID Connect provider setup?
The main drivers are scope, the number of clients, testing and hardening. Scope covers which applications will log in against XWiki, which user attributes and group claims each one needs, and whether logout and token lifetimes must follow a policy. Each client adds registration, redirect URI and claim work, and each needs its own test. Testing covers login, consent, token refresh and failure paths. Hardening covers HTTPS, secret handling, token settings and how XWiki is kept patched. Costs are paid for design, configuration, testing and handover. Setup is usually one-time, while upgrades, monitoring and support recur. Ask for a quote that lists each client, the test cases and the hardening items separately.
How long does a pilot take to run?
The duration depends on the scope written into the engagement, so no fixed figure applies here. A pilot with one or two clients, a single test environment and existing user data will be shorter than a pilot that covers many applications, several environments and group mapping. Time is also set by how quickly your team provides answers on claims, redirect URIs and certificates. DeployOpen agrees scope, deliverables and timelines in writing before work starts, so ask for the timeline as part of the written scope and check which dependencies on your side it assumes.
What does our internal team need to provide?
Plan for four groups of input. Administrators need access to the XWiki instance, its server and the chosen database so changes can be deployed and rolled back. DNS entries must resolve the public names used in issuer and redirect URLs, and certificates must be valid for those names, since OpenID Connect flows depend on HTTPS. Application owners must state which client applications will log in, their redirect URIs, required claims and who may use each one. Security or compliance staff should approve the token, consent and logout settings. Ask the provider to list these inputs in the written scope so gaps are found before the build starts.
Can we set this up ourselves?
Yes, if your team has experience with XWiki administration, OpenID Connect concepts and the target applications. The extension is open source under the LGPL 2.1 license and supports XWiki 14.10.2 and later, so you can install and configure it with your own staff. The harder part is verification: confirming consent behavior, token contents, logout, failure handling and upgrade compatibility across each client. Teams often do the first client themselves and then decide whether the rest needs outside help. Check the extension's documentation for your XWiki version before starting, and confirm that your staff can keep it patched once it is live.
Does XWiki SAS support cover this extension?
Confirm this directly with XWiki SAS before you buy. XWiki SAS offers on-premises professional support, installation and configuration help, and training, and it lists consulting at 1200 EUR per day for customers on a Business or Enterprise support plan. Support plans and their scope are described on its pricing page, but the pages supplied for this topic do not state whether the OpenID Connect provider extension is covered by standard support. Ask XWiki SAS in writing which extensions and versions it supports, what response it commits to, and whether consulting is billed separately from support.
What should we check before going live as a provider?
Check four things first. Confirm the XWiki version against the extension's stated minimum and test every client flow on that exact combination. Verify that consent screens show what you intend and that tokens carry only the claims each application needs. Confirm HTTPS on all public names and that client secrets are stored outside plain configuration. Finally, agree an upgrade path, since a change to XWiki or the extension can alter login for every connected application. Record these checks as evidence so that your security and compliance reviewers can see how the provider was configured and tested.
How DeployOpen scopes and delivers an XWiki OIDC provider
DeployOpen starts this work with a written scope agreed before any build begins. For an XWiki OpenID Connect provider built on the xwiki-contrib OIDC project, the scope names each relying application that will sign in against XWiki, the clients registered for each one, the claims every client receives (such as subject, email, name and group membership), which clients require a consent screen and which trust one another without it, and the hardening controls for the provider itself. Fixed-scope work of this kind lets the client's security, identity and application teams review those decisions on paper, before anything is installed, and it gives both sides a clear boundary for what the quote covers.
Delivery happens in infrastructure the client controls, whether that is their cloud accounts, data center or an air-gapped network. Because the provider sits in front of other applications, the most important part of delivery is testing with the client's real relying applications, not only with a test client. DeployOpen plans that testing against the scoped clients, checks token contents, consent behavior, logout and the handling of expired or revoked sessions, and records the results so the client's compliance team has evidence. Confirm early which XWiki version and which extension release your environment will run, since the xwiki-contrib project's supported XWiki versions determine what can be tested.

