Skip to main content
Glama
jlaska

RedHatLDAP-MCP

by jlaska

RedHat LDAP MCP Server

Test Suite Lint

A specialized Model Context Protocol (MCP) server designed for corporate LDAP directories, with optimizations for Red Hat's LDAP environment and other OpenLDAP-based corporate systems.

๐ŸŽฏ Purpose

This MCP server provides read-only access to corporate LDAP directories, enabling AI assistants to:

  • Search for people and organizational information

  • Navigate corporate hierarchies and reporting structures

  • Access contact information and organizational data

  • Export directory information for business use

Related MCP server: mcp-activedirectory

๐Ÿš€ Features

Corporate LDAP Optimized

  • Anonymous bind support for read-only corporate directories

  • Red Hat LDAP integration with rhatPerson schema support

  • Schema auto-detection for different LDAP environments

  • Corporate hierarchy tools for org charts and reporting structures

Read-Only & Secure

  • No modification operations - purely informational

  • Corporate firewall friendly - optimized for enterprise networks

  • Flexible authentication - anonymous, simple, and SASL support planned

AI Assistant Ready

  • MCP protocol compliance for Claude, Cursor, and other AI tools

  • Structured responses with consistent JSON formatting

  • Rich search capabilities across multiple person attributes

  • Export functionality for contact lists and org charts

๐Ÿ”ง Available MCP Tools

  • search_people - Search for people by name, email, uid, department

  • get_person_details - Get detailed information about a specific person

Organization Charts

  • get_organization_chart - Build hierarchical org charts from any manager

  • find_manager_chain - Get the complete management chain for any person

Groups & Teams

  • search_groups - Search for groups and teams

  • get_person_groups - Find all groups a person belongs to

  • get_group_members - List all members of a specific group

Locations & Offices

  • find_locations - Discover office locations and people counts

  • get_people_at_location - Find all colleagues at a specific office

Utilities

  • test_connection - Test LDAP connectivity and configuration

๐Ÿ› ๏ธ Installation

# Clone the repository
git clone https://github.com/jlaska/RedHatLDAP-MCP.git
cd RedHatLDAP-MCP

# Create virtual environment and install
uv venv
uv pip install -e ".[dev]"

โš™๏ธ Configuration

Create a configuration file (e.g., config/redhat-ldap.json):

{
  "ldap": {
    "server": "ldap://ldap.corp.redhat.com",
    "base_dn": "dc=redhat,dc=com",
    "auth_method": "anonymous",
    "timeout": 30
  },
  "schema": {
    "person_object_class": "rhatPerson",
    "person_search_base": "ou=users,dc=redhat,dc=com",
    "group_search_base": "ou=adhoc,ou=managedGroups,dc=redhat,dc=com",
    "corporate_attributes": [
      "rhatJobTitle", "rhatCostCenter", "rhatLocation",
      "rhatBio", "manager", "rhatGeo"
    ]
  },
  "logging": {
    "level": "INFO",
    "format": "%(asctime)s - %(name)s - %(levelname)s - %(message)s"
  }
}

๐Ÿš€ Usage

For the easiest setup with Claude CLI, use the included wrapper script:

# Add to Claude CLI (from project directory)
claude mcp add redhat-ldap /absolute/path/to/RedHatLDAP-MCP/scripts/run_mcp_server.sh

# Verify connection
claude mcp list

# Use in Claude CLI conversations
claude chat
> What's John Doe's mobile number?

The wrapper script automatically configures the environment and uses the local configuration.

Stdio Mode (for other MCP clients)

REDHAT_LDAP_CONFIG="config/redhat-ldap.json" uv run python -m redhat_ldap_mcp.server

HTTP Mode (for testing/development)

REDHAT_LDAP_CONFIG="config/redhat-ldap.json" uv run python -m redhat_ldap_mcp.server_http --host 0.0.0.0 --port 8813

๐Ÿ”ง MCP Client Configuration

Claude CLI

claude mcp add redhat-ldap "scripts/run_mcp_server.sh" -e REDHAT_LDAP_CONFIG=$PWD/config/redhat-ldap.json

๐Ÿ“š Available Tools

  • search_people - Find people by name, email, uid, or other attributes

  • get_person_details - Get detailed information about a specific person

  • get_organization_chart - Generate hierarchical org charts from any manager

  • find_manager_chain - Get the complete management chain for any person

  • search_groups - Search for groups and teams

  • get_person_groups - Find all groups a person belongs to

  • get_group_members - List all members of a specific group

  • find_locations - Discover office locations and people counts

  • get_people_at_location - Find all colleagues at a specific office

  • test_connection - Test LDAP connectivity and configuration

๐Ÿงช Development

# Run tests
pytest

# Format code
black src/ tests/

# Lint code
ruff check src/ tests/

# Type checking
mypy src/

๐Ÿ“„ License

MIT License - see LICENSE file for details.

๐Ÿค Contributing

  1. Fork the repository

  2. Create a feature branch

  3. Make your changes

  4. Add tests if applicable

  5. Run the test suite

  6. Submit a pull request

๐Ÿ™ Acknowledgments

A
license - permissive license
-
quality - not tested
D
maintenance

Maintenance

โ€“Maintainers
โ€“Response time
โ€“Release cycle
โ€“Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    -
    quality
    C
    maintenance
    Enables AI assistants to access and search Google Contacts through per-user OAuth authentication on serverless AWS Lambda. Provides read-only access to personal contacts with zero data storage and real-time API queries.
    81
    2
    MIT
  • F
    license
    A
    quality
    C
    maintenance
    Provides AI assistants with unified access to on-prem Active Directory via LDAP and Azure AD / Entra ID through the Microsoft Graph API. It enables comprehensive management and search of users, groups, computers, and cloud devices using 18 specialized tools.
    18
  • A
    license
    -
    quality
    D
    maintenance
    Enables managing employee records by providing tools to list directories, retrieve detailed profiles, and search for staff by department. It integrates with Claude Desktop to allow users to interact with employee data through natural language commands.
    MIT
  • F
    license
    -
    quality
    D
    maintenance
    Exposes internal employee directories and project management systems to AI models through standardized tools and resources. It enables AI assistants to search for team members, query project statuses, and explore organizational hierarchies with secure role-based access control.

View all related MCP servers

Related MCP Connectors

  • Search companies, enrich contacts, and reveal emails and phones from your AI agent.

  • Give AI agents the LinkedIn tools to find, qualify, engage, and follow up with prospects.

  • Search your knowledge bases from any AI assistant using hybrid RAG.

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/jlaska/RedHatLDAP-MCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server