Skip to main content

LDAP LDIF to JSON

Project description

ldifj

This Python script parses LDAP Data Interchange Format (LDIF) files, allows for the extraction of entries and, optionally, metadata.

🛠 Installation

Install the required modules with pip(x):

pip install ldifj
# the cool kids use pipx nowadays:
pipx install ldifj

🚀 Usage

usage: ldif [-h] [--metadata] [FILE]

positional arguments:
  FILE         LDIF file to parse, set to '-' to read from stdin

optional arguments:
  -h, --help   show this help message and exit
  --metadata, -m
               Include metadata

📝 Examples

To parse an LDIF file, run:

ldif example.ldif

ldif also accepts input from a pipe:

cat example.ldif | ldif

If you want to include the metadata in the returned JSON object:

ldif --metadata example.ldif

📜 License

GNU General Public License v3 (GPL-3).

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ldifj-0.1.1.tar.gz (40.8 kB view hashes)

Uploaded Source

Built Distribution

ldifj-0.1.1-py3-none-any.whl (27.6 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page