Skip to content
KitploitKITPLOIT
ToolsExploitsBlog
Log in
Submit
ToolsExploitsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

FeedsContactPrivacy© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
nextcloud-ldap-put-isadmin — Nextcloud 35.0.0 — delegated Users admin can PUT-edit an LDAP-promoted admin that PATCH correctly refuses | Kitploit
Tools/GitHubGitHub/abraxas/nextcloud-ldap-put-isadmin
Authentication & AuthorizationPrivilege EscalationVulnerability AnalysisWeb Application ExploitationWeb SecurityPenetration TestingLabs & Practice
GitHub

Most Popular

View all →

Discover the most used tools by our community.

Explore all tools

Browse our collection of tools

View all tools →
Share
abraxas/nextcloud-ldap-put-isadmin

nextcloud-ldap-put-isadmin

Nextcloud 35.0.0 — delegated Users admin can PUT-edit an LDAP-promoted admin that PATCH correctly refuses

View Repository
815 days agoNot yet reviewed

Abraxas Labs - nextcloud-ldap-put-isadmin

abraxaslabs.tech  ·  github.com/abraxas  ·  @abraxas_null  ·  [email protected]  ·  nextcloud-ldap-put-isadmin

nextcloud-ldap-put-isadmin

Nextcloud Server 35.0.0 - Nextcloud GmbH

PUT /cloud/users/{id} lets a delegated Users admin edit a target unless that target is in the local group admin. PATCH on the same path correctly uses isAdmin(). LDAP-promoted admins are isAdmin()===true and often not in that local group.

A bad actor with the helpdesk-style Users job can disable, quota-lock, or delete a real LDAP-promoted instance admin. The newer PATCH API correctly refuses. The older PUT path does not.

IDno CVE yet
CWECWE-863
CVSSHigh: 7.2 CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H (delegated Users admin, not instance admin)
ProductNextcloud Server
Affected35.0.0 (da02f41) official nextcloud:35.0.0-apache plus user_ldap
Authdelegated Users admin vs LDAP-promoted admin
LicenseGNU Affero GPL v3.0
Lab127.0.0.1 only

What an attacker can do

On an LDAP site, you promoted an LDAP group to instance admin (occ ldap:promote-group). Those people are real admins (isAdmin()===true) but they may not sit in the local Nextcloud group named admin.

You also gave someone the Users settings job (helpdesk). They are not a full instance admin.

That helpdesk user can:

  • Change quota on the LDAP-promoted admin (lab: PUT 200, PATCH 403)
  • Disable or delete that admin (same isInGroup gate on enable/disable/delete/wipe)
  • Reset password if the LDAP backend allows canChangePassword() (often false; do not depend on it)

They cannot do this to someone who is actually in the local admin group. They cannot do this on a site with no LDAP-promoted admins. The safer PATCH API already knows the difference.


How I found it

Provisioning has two editors for the same user. UsersController::editUser is PUT. editUserMultiField is PATCH. Same file. Adjacent methods. Two different answers to "is this person an admin."

PUT checks isInGroup($target, 'admin'). PATCH checks isAdmin($target). Manager::isAdmin() asks LDAP IIsAdmin then the local group. occ ldap:promote-group makes an LDAP group instance-admin without putting those uids in the local admin group.

I stood up official nextcloud:35.0.0-apache plus osixia/openldap:1.5.0. LDAP user ldapadmin in promoted group ncadmins: isAdmin()===true, not in local admin. Local helpdesk is delegated Users, not instance admin.

I sent PATCH first. It is the newer route. I expected PUT to match it. PATCH {"quota":"1 GB"} returned 403. PUT key=quota&value=1 GB returned 200. GET then showed quota 1073741824.


Lab

cd lab
./run.sh

Target only http://127.0.0.1:18342 (OpenLDAP on compose DNS ldap:389).

SUCCESS NEXTCLOUD-LDAP-PUT-ISADMIN who=delegated-users-admin target=ldapadmin put=200 patch=403 NEXTCLOUD-LDAP-PUT-ISADMIN-WITNESS
  • lab/docker-compose.yml
  • lab/Dockerfile
  • lab/run.sh
  • lab/ldap/50-seed.ldif
  • lab/fixture.php

The fix

Use isAdmin($target) on PUT/disable/delete/wipe the same way PATCH already does.


References

  • github.com/nextcloud/server tag v35.0.0
  • LDAP promote: occ ldap:promote-group (PR #41650)
  • Abraxas Labs: abraxaslabs.tech · github.com/abraxas · @abraxas_null

License

GNU Affero GPL v3.0. See LICENSE. Loopback lab only. No warranty.

Download Tool