Just for the record, I have NextCloud successfully integrated with Gluu via *OpenID Connect*.
Gluu Version: 4.2.3.Final
NextCloud Version: 20.0.12
OpenID Connect user backend Plugin Version: 1.1.0
====
I have the following setup in my environment:
![](https://i.ibb.co/rfs7LVG/ocub3.png)
1. Users are provisioned into MS Active Directory (AD)
2. Gluu has cache refresh configured that sync users from AD
3. NextCloud has LDAP/AD Integration configured that sync users from same AD
4. ***sAMAccountName*** is the common attribute used
In Gluu, change `openidSubAttribute` (JSON Configuration > OxAuth Configuration) to **uid**
![](https://i.ibb.co/qrJyXVC/ocub4.png)
In NextCloud LDAP/AD Integration, navigate to *Expert* - *Override UUID detection*, add **sAMAccountName** to `UUID Attribute for Users`.
![](https://i.ibb.co/K6qtxHP/ocub2.png)
In NextCloud OpenID Connect user backend, ensure `Use unique user id` is disabled. Otherwise, new NextCloud user will be created whenever an existing user logs in to NextCloud via OpenID Connect.
![](https://i.ibb.co/9bch0wT/ocub1.png)