Repository navigation
allow creating ldap on existing linked domain - #13945
DaanHoogland wants to merge 4 commits into
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## 4.20 #13945 +/- ##
============================================
+ Coverage 16.44% 16.46% +0.02%
- Complexity 13686 13708 +22
============================================
Files 5669 5669
Lines 501683 501690 +7
Branches 60944 60944
============================================
+ Hits 82480 82583 +103
+ Misses 409965 409853 -112
- Partials 9238 9254 +16
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
|
@blueorangutan package |
|
@DaanHoogland a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress. |
|
Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ el10 ✖️ debian ✔️ suse15. SL-JID 18985 |
|
@blueorangutan test |
|
@DaanHoogland a [SL] Trillian-Jenkins test job (ol8 mgmt + kvm-ol8) has been kicked to run smoke tests |
|
[SF] Trillian test result (tid-16828)
|
kiranchavala
left a comment
There was a problem hiding this comment.
LGTM Tested manually
Before fix
root@Cloudstack-423:/home/ubuntu# cmk ldap createaccount username=jithin account=arch-team-acct accounttype=0 domainid=73025da2-280a-4bed-9ca8-7a94904347d1
🙈 Error: (HTTP 534, error code 9999) No LDAP user exists with the username of jithin
After fix , able to create account in the domain
cmk link accounttoldap domainid=607ebf06-7d78-4a9c-9a85-864c6f5d882a account=qa-team-acct accounttype=0 type=GROUP ldapdomain="cn=qa-team,ou=Telco-Bng,dc=example,dc=in
cmk link accounttoldap domainid=607ebf06-7d78-4a9c-9a85-864c6f5d882a account=qa-team-acct accounttype=0 type=GROUP ldapdomain="cn=qa-team,ou=Telco-Bng,dc=example,dc=in"
cmk ldap createaccount username=jithin account=arch-team-acct accounttype=0 domainid=607ebf06-7d78-4a9c-9a85-864c6f5d882a
There was a problem hiding this comment.
Warning
Copilot couldn't run its full agentic review because it didn't start before the timeout. Make sure your repository has a runner available, or add a copilot-code-review.yml file specifying one with the runs-on attribute. See the docs for more details.
Pull request overview
Adds regression coverage and adjusts LDAP user search behavior so that creating/looking up a single user isn’t blocked by pre-linked LDAP groups in the same domain, while keeping group scoping for browsing/importing.
Changes:
- Updated LDAP user search filter generation to optionally restrict results to already-linked groups (domain trust maps).
- Adjusted
getUserto search without linked-group scoping, whilesearchUsers/browsing remains scoped. - Added unit tests covering filter scoping behavior and paged-results cookie handling.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| plugins/user-authenticators/ldap/src/main/java/org/apache/cloudstack/ldap/OpenLdapUserManagerImpl.java | Adds a “restrict to linked groups” toggle in search filter generation and refactors paged-results cookie extraction. |
| plugins/user-authenticators/ldap/src/test/java/org/apache/cloudstack/ldap/OpenLdapUserManagerImplTest.java | New regression tests validating the new scoping behavior and paging loop behavior. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
00e3223 to
93d32e2
Compare
|



allow creating ldap accounts after linking accounts to the same the domain
Description
This PR...
Fixes: #8732
Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Bug Severity
Screenshots (if appropriate):
How Has This Been Tested?
How did you try to break this feature and the system with this change?