Socket
Book a DemoInstallSign in
Socket

github.com/azratul/ldap-client-go

Package Overview
Dependencies
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

github.com/azratul/ldap-client-go

Source
Go Modules
Version
v0.0.0-20191223000954-f0966dd60ff4
Version published
Created
Source

ldap-client-go

LDAP client to connect and retrieve information for a user.

Doesn't support TLS

Usage

package main

import (
    "github.com/azratul/ldap-client-go"
)

func main() {
    client := &ldap.Client{
        BaseDN:             "dc=subdomain,dc=domain,dc=cl",
        Host:               "subdomain.domain.cl",
        Port:               389,
        BindUser:           "cn=admin,cn=Users",
        BindPass:           "password",
        SkipTLS:            true,
    }

    defer client.Close()

    client.Connect()

    client.Search("(&(sAMAccountName=USER))", []string{"dn", "cn", "givenName", "distinguishedName", "name", "userPrincipalName"})
}

FAQs

Package last updated on 23 Dec 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts