ldap-client-0.1.0: Pure Haskell LDAP Client Library

Safe HaskellNone
LanguageHaskell2010

Ldap.Client

Contents

Synopsis

Documentation

data Ldap Source

Instances

data Async a Source

Instances

with :: Host -> PortNumber -> (Ldap -> IO a) -> IO (Either LdapError a) Source

The entrypoint into LDAP.

Bind

bind :: Ldap -> Dn -> Password -> IO () Source

Perform the Bind operation synchronously. Raises ResponseError on failures.

Search

search :: Ldap -> Dn -> Mod Search -> Filter -> [Attr] -> IO [SearchEntry] Source

Perform the Search operation synchronously. Raises ResponseError on failures.

Search modifiers

data Mod a Source

Instances

Monoid (Mod a) Source 
Semigroup (Mod a) Source 

Modify

modify :: Ldap -> Dn -> [Operation] -> IO () Source

Perform the Modify operation synchronously. Raises ResponseError on failures.

data Operation Source

Type of modification being performed.

Constructors

Delete Attr [AttrValue]

Delete values from the attribute. Deletes the attribute if the list is empty or all current values are listed.

Add Attr [AttrValue]

Add values to the attribute, creating it if necessary.

Replace Attr [AttrValue]

Replace all existing values of the attribute with the new list. Deletes the attribute if the list is empty.

Add

add :: Ldap -> Dn -> AttrList NonEmpty -> IO () Source

Perform the Add operation synchronously. Raises ResponseError on failures.

Delete

delete :: Ldap -> Dn -> IO () Source

Perform the Delete operation synchronously. Raises ResponseError on failures.

ModifyDn

modifyDn :: Ldap -> Dn -> RelativeDn -> Bool -> Maybe Dn -> IO () Source

Perform the Modify DN operation synchronously. Raises ResponseError on failures.

Compare

compare :: Ldap -> Dn -> Attr -> AttrValue -> IO Bool Source

Perform the Compare operation synchronously. Raises ResponseError on failures.

Extended

extended :: Ldap -> Oid -> Maybe ByteString -> IO () Source

Perform the Extended operation synchronously. Raises ResponseError on failures.

Waiting for completion

Miscellanous

newtype Dn Source

Constructors

Dn Text 

Instances

newtype RelativeDn Source

Constructors

RelativeDn Text 

newtype Oid Source

Constructors

Oid Text 

Instances

type AttrList f = [(Attr, f AttrValue)] Source

newtype Attr Source

Constructors

Attr Text 

Re-exports

data NonEmpty a :: * -> *

Instances

Monad NonEmpty 
Functor NonEmpty 
MonadFix NonEmpty 
Applicative NonEmpty 
Foldable NonEmpty 
Traversable NonEmpty 
Generic1 NonEmpty 
MonadZip NonEmpty 
IsList (NonEmpty a) 
Eq a => Eq (NonEmpty a) 
Data a => Data (NonEmpty a) 
Ord a => Ord (NonEmpty a) 
Read a => Read (NonEmpty a) 
Show a => Show (NonEmpty a) 
Generic (NonEmpty a) 
NFData a => NFData (NonEmpty a) 
Hashable a => Hashable (NonEmpty a) 
ToAsn1 a => ToAsn1 (NonEmpty a) 
Semigroup (NonEmpty a) 
type Rep1 NonEmpty = D1 D1NonEmpty (C1 C1_0NonEmpty ((:*:) (S1 NoSelector Par1) (S1 NoSelector (Rec1 [])))) 
type Rep (NonEmpty a) = D1 D1NonEmpty (C1 C1_0NonEmpty ((:*:) (S1 NoSelector (Rec0 a)) (S1 NoSelector (Rec0 [a])))) 
type Item (NonEmpty a) = a