Skip to content

Releases: jcombs-pointblue/LDIFUtils

v1.0.1

23 Apr 23:18

Choose a tag to compare

Maintenance release — LDIF parsing correctness fixes, base64 DN support, UTF-8 I/O. Fully compatible with v1.0.0 on the command-line surface.

Fixed

  • Folded/wrapped attribute values are now handled correctly. StripAttributes no longer leaks continuation lines of stripped attributes, and LDIFAttributeExtractor / LDIFAttr2DirAttrCompare no longer truncate wrapped values at the fold. (Previously, all three used parts[1].trim().isEmpty() as a proxy for "will be continued" — wrong per RFC 2849, which identifies continuations by the next line starting with a space.)
  • Base64-encoded DNs (dn:: <base64>) are now decoded. DnTransformer round-trips them correctly (decode, rewrite path, re-encode). The comparators and directory-compare tool key off and search against the decoded DN.
  • LDIFAttributeComparator correctness:
    • Records with the attribute absent in both files are no longer reported as differing.
    • The previously-unreachable continued-DN branch is replaced with a working inDN state flag, so DNs that wrap across lines are parsed correctly.
    • Multi-valued attributes are compared as unordered sets (LDAP attribute values have no inherent order). Same fix applied in LDIFRecordComparator.
  • UTF-8 I/O everywhere. All readers/writers use StandardCharsets.UTF_8 instead of the JVM's platform-default charset, so non-ASCII LDIF content round-trips correctly regardless of the host.
  • LDIFAttr2DirAttrCompare resource hygiene. DirContext and NamingEnumeration instances are now closed in finally blocks. The one-shot endsWith(baseDN) continued-DN heuristic is replaced with proper RFC-2849 continuation handling.
  • LDIFAttributeExtractor usage line had the wrong class name.
  • DummyTrustManager placeholder copyright replaced.

Running

java -cp ldifutils.jar com.pointblue.ldifutil.<UtilityName> [arguments]

Requires Java 8 or higher. See the README for per-utility usage.

v1.0.0

23 Apr 22:52

Choose a tag to compare

First tagged release of LDIFUtils — a collection of command-line Java utilities for processing, comparing, and manipulating LDIF files.

Included utilities

  • StripAttributes — remove specified attributes from an LDIF
  • LDIFRecordComparator — list DNs of records that differ between two LDIFs
  • LDIFAttributeExtractor — extract a specific attribute across all entries
  • LDIFAttributeComparator — compare one (or all) attribute(s) across two LDIFs
  • LDIFAttr2DirAttrCompare — compare an LDIF attribute against a live LDAP directory (trusts all TLS certs, so ldaps:// with a self-signed cert works)
  • DnTransformer — rewrite the DN path of every entry while preserving the leftmost RDN

Running

java -cp ldifutils.jar com.pointblue.ldifutil.<UtilityName> [arguments]

Requires Java 8 or higher. See the README for per-utility usage.