Skip to content

New Entry: always send RDN attribute in Add; AD rDNAttID naming (#24 parity) - #2

Merged
jcombs-pointblue merged 4 commits into
masterfrom
cursor/new-entry-rdn-add-payload-349a
Oct 30, 2026
Merged

jcombs-pointblue merged 4 commits into
masterfrom
cursor/new-entry-rdn-add-payload-349a

Conversation

@jcombs-pointblue

Copy link
Copy Markdown
Contributor

ArborJ parity fix for Arbor issue report #24 (a New Entry Add omitted a MAY RDN attribute such as cn for an AD group).

Changes

  • buildCreateAttributes always includes the trimmed RDN value, which wins over a disagreeing field. The Step 2 RDN field is read-only.
  • The DN is built with UnboundID RDN escaping, and the Add carries the raw value.
  • AD rDNAttID becomes the first naming choice (with SUP inheritance). Attribute names are validated as an RFC 4512 descr or a numeric OID.
  • The editable RDN combo reads its editor text first, so a typed-but-uncommitted attribute (e.g. ou) isn't lost to a stale selection.

Verification

  • mvn test: 136 pass.
  • Adversarial review clean (low risk) through the final commit.
  • Claude review: no correctness bugs; its medium finding (stale combo value) is fixed here.

Follow-ups (backlog): updateNamingAttributes overwriting a hand-typed attribute on class change; OID-vs-name MUST matching.

cursoragent and others added 4 commits October 30, 2026 14:03
NewEntryDialog.doCreate sent only MUST fields, so an AD group named
with cn (MAY via top) was added without cn and the server rejected it.
Always attach the RDN attribute=value unless a MUST field already has
it. SchemaService now reads classSchema rDNAttID alongside X-NDS_NAMING
so the naming combo lists it first.

Co-authored-by: Jerry Combs <jcombs@pointbluetech.com>
Treat the New Entry RDN field as the unescaped attribute value.
formatRDN uses UnboundID RDN (RFC 4514) so comma, plus, spaces,
hash, and backslash are escaped in the DN; buildCreateAttributes
sends the same raw text. Plus is a value character, not a
multi-valued RDN. A MUST field that disagrees with the RDN is
rejected, and namingEquals is now Objects.equals.

Co-authored-by: Jerry Combs <jcombs@pointbluetech.com>
validateStep1 trims the RDN text and writes it back so Create, the
DN, and the Add all use the same value (" Bob " → cn=Bob). The Step 2
MUST field for that attribute is read-only, matching Arbor, so the
conflict reject path is gone. The editable RDN attribute combo is
checked against an LDAP descr or numeric OID.

Co-authored-by: Jerry Combs <jcombs@pointbluetech.com>
JavaFX ComboBox.getValue() can lag typed text until Enter or focus
loss, so typing ou and clicking Next could still emit cn. Resolve
from the editor first, fall back to getValue, and use that one
value for validation, the DN, and the Add.

Co-authored-by: Jerry Combs <jcombs@pointbluetech.com>
@jcombs-pointblue
jcombs-pointblue merged commit 7353323 into master Oct 30, 2026
1 check passed
@jcombs-pointblue
jcombs-pointblue deleted the cursor/new-entry-rdn-add-payload-349a branch October 30, 2026 14:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants