ldif-duplicate-attrs(1)

πŸ“¦
this version Β· 2 versions
, in debian bookworm, debian trixie, opensuse-leap 16.0, ubuntu jammy, ubuntu noble, ubuntu questing

πŸ’… ldif-duplicate-attrs β€” the hxtools girlie

okay bestie, so this is a page from hxtools, and it's called ldif-duplicate-attrs(1). Let me tell you everything about it, no gatekeeping πŸ’–


✨ Name ✨

ldif-duplicate-attrs β€” check for multi-value attributes in LDIF file πŸ¦‹

like, it's the vibe-check tool for your LDIF, fr fr.


🌸 Usage 🌸

procalldiff [-C] <foo.ldif >report.txt

(yeah it literally says procalldiff in there, I don't make the rules, I just report them πŸ’€)

🚨 IMPORTANT bestie: the input must not contain linewraps. Do use with
{slapcat|ldapsearch} -o ldif-wrap=no ...

so turn the wrapping OFF, periodt. πŸ™ˆ


πŸŽ€ Description πŸŽ€

So what it does is: it reads an LDIF file from standard input and checks for the presence of multivalued attributes of all the DNs. πŸ‘‘

Whitelisted attribute names get excluded from the problem report β€” they're the good ones, they get a pass. ✨

Then it outputs a statistic sorted by severity to standard output. It's giving report card energy. πŸ“Š


πŸ‘‘ Options πŸ‘‘

  • -C β€” Force color output. Useful when piping into less -R. (By default, color is only emitted when stdout is a tty.) 🌈

so if you're piping and you want the pretty colors anyway, that's your girl.


πŸ”₯ Example output πŸ”₯

      11   cn=67eoG,ou=Muenchen,o=Deutschland
           uid(3) cn(2) fullName(2) mail(2) sn(2)
      10   cn=Hoff,ou=Muenchen,o=Deutschland
           homeCity(2) homePostalAddress(2) homeZipCode(2) l(2)
           telephoneNumber(2)

Let me decode this for you bestie 🧚:

The DN cn=67eoG has had three values for the "uid" attribute, two for "cn", and so on β€” for a total badness score of 11. 😭 iconic levels of chaos ngl.

The entire output is sorted by:

  1. Overall, DNs are sorted by descending score.
  2. For a particular DN, attributes are sorted by descending score.
  3. If two attributes have the same score, sort occurs lexicographically ascending.

so worst offenders first, then within a DN, worst attribute first, and ties get alphabetical. slay. πŸ’…


πŸ’œ See also πŸ’œ

hxtools(7)


and that's the whole thing, bestie 🫢 β€” this page came from hxtools, dated 2015-04-01, and it's ldif-duplicate-attrs(1) to the very end. go check your attributes, they might be duplicating, no cap. βœ¨πŸ’–πŸŽ€

πŸ“¦ where this page comes from