Macros | |
#define | DS_SASL_BEST_SSF (65535) |
Enumerations | |
enum | DSBindType { DSAnonymous = 0, DSSimple = 1, DSStrong = 2, DSSASL = 3 } |
Functions | |
DS_Status | DS_BindParams_New (DS_BindParams **params_p) |
Create a bind parameters structure. More... | |
void | DS_BindParams_Delete (DS_BindParams *params) |
Delete a bind parameters object. More... | |
DS_Status | DS_BindParams_Copy (const DS_BindParams *in, DS_BindParams **copy_p) |
Copy a DS_BindParams structure. More... | |
DS_Status | DS_BindParams_GetBindType (const DS_BindParams *params, DSBindType *bind_type) |
Get the bind type for this bind params. More... | |
DS_Status | DS_BindParams_SetIdentity (DS_BindParams *params, const DS_Identity *id) |
Set or clear the identity for this bind params. More... | |
DS_Status | DS_BindParams_SetCertificateServer (DS_BindParams *params, const char *ldap_host, long ldap_port, int check_crls) |
Set or clear the details for the LDAP server that holds certificates and/or CRLs. More... | |
DS_Status | DS_BindParams_GetIdentity (const DS_BindParams *params, const DS_Identity **id_p) |
identity for this bind params. More... | |
DS_Status | DS_BindParams_GetCertificateServer (const DS_BindParams *params, const char **ldap_host, long *ldap_port, int *check_crls) |
Get the details of the LDAP server used to locate certificates and/or CRLs. More... | |
DS_Status | DS_BindParams_SetAnonymous (DS_BindParams *params) |
Mark this set of bind parameters as being for an anonymous bind. More... | |
DS_Status | DS_BindParams_SetSimple (DS_BindParams *params, const DS_DN *bind_dn, const char *password) |
Mark this set of bind parameters as being for a simple bind. More... | |
DS_Status | DS_BindParams_SetStrong (DS_BindParams *params, const DS_Identity *id, const DS_DN *dsa_dn) |
Mark this set of bind parameters as being for a strong bind. More... | |
DS_Status | DS_BindParams_SetSASL (DS_BindParams *params, const char *sasl_mechs, const DS_SASLProps *sasl_props, const char *sasl_authentication, const char *sasl_secret) |
Mark this set of bind parameters as being for a SASL bind. It only makes sense to do SASL binds on an LDAP connection (not DAP) More... | |
DS_Status | DS_BindParams_SetSASLRealm (DS_BindParams *params, const char *sasl_realm) |
Set the SASL realm for this set of (SASL) bind parameters. It only makes sense to do this for an object which is for a SASL bind. More... | |
Detailed Description
Macro Definition Documentation
◆ DS_SASL_BEST_SSF
#define DS_SASL_BEST_SSF (65535) |
A constant which can be used to indicate that the "best available" security-strength factor should be used.
- Since
- DSAPI_VERSION 2041
Definition at line 61 of file dsapi_bindparams.h.
Enumeration Type Documentation
◆ DSBindType
enum DSBindType |
Values of the 'bind_type' field in a DS_BindParams structure.
Enumerator | |
---|---|
DSAnonymous | Anonymous bind. |
DSSimple | Simple bind. |
DSStrong | Strong bind. |
DSSASL | SASL bind. |
Definition at line 54 of file dsapi_bindparams.h.
Function Documentation
◆ DS_BindParams_New()
DS_Status DS_BindParams_New | ( | DS_BindParams ** | params_p | ) |
Create a bind parameters structure.
- Parameters
-
[out] params_p Returned handle or NULL on error
- Return values
-
DS_E_MOMEMORY An internal memory allocation failed DS_E_NOERROR A valid handle was returned
◆ DS_BindParams_Delete()
void DS_BindParams_Delete | ( | DS_BindParams * | params | ) |
Delete a bind parameters object.
- Parameters
-
params [in] Handle to delete. If this is NULL, no action is taken.
◆ DS_BindParams_Copy()
DS_Status DS_BindParams_Copy | ( | const DS_BindParams * | in, |
DS_BindParams ** | copy_p | ||
) |
Copy a DS_BindParams structure.
The caller is responsible for freeing the copied structure using DS_BindParams_Delete.
- Parameters
-
[in] in the DS_BindParams to copy [out] copy_p Pointer to returned copy.
- Return values
-
DS_E_BADPARAM in or copy_p was NULL DS_E_MOMEMORY An internal memory allocation failed DS_E_INTERNAL An internal error occurred DS_E_NOERROR A valid handle was returned
◆ DS_BindParams_GetBindType()
DS_Status DS_BindParams_GetBindType | ( | const DS_BindParams * | params, |
DSBindType * | bind_type | ||
) |
Get the bind type for this bind params.
- Parameters
-
[in] params bind parameters. [out] bind_type pointer to receive returned copy.
- Return values
-
DS_E_BADPARAM params or bind_type was NULL DS_E_NOERROR the information was returned.
◆ DS_BindParams_SetIdentity()
DS_Status DS_BindParams_SetIdentity | ( | DS_BindParams * | params, |
const DS_Identity * | id | ||
) |
Set or clear the identity for this bind params.
Any existing identity information for this DS_BindParams structure is discarded.
A copy of id will be made, which means that the caller may delete the original DS_Identity once this function has been called.
- Parameters
-
[in] params bind parameters to be updated. [in] id identity information. May be NULL to indicate that no identity is to be used with these bind parameters.
- Return values
-
DS_E_BADPARAM params was NULL DS_E_INTERNAL An internal error occurred DS_E_NOERROR the identity information was updated.
◆ DS_BindParams_SetCertificateServer()
DS_Status DS_BindParams_SetCertificateServer | ( | DS_BindParams * | params, |
const char * | ldap_host, | ||
long | ldap_port, | ||
int | check_crls | ||
) |
Set or clear the details for the LDAP server that holds certificates and/or CRLs.
Any existing server information for this DS_BindParams structure is discarded.
- Parameters
-
[in] params bind parameters to be updated. [in] ldap_host name of LDAP server. May be NULL to indicate that no LDAP server is to be used [in] ldap_port port number of LDAP server. A value of zero is taken to mean the default LDAP port (389). Ignored if ldap_host is NULL [in] check_crls non-zero to indicate that CRL checking is requested. Ignored if ldap_host is NULL
- Return values
-
DS_E_BADPARAM params was NULL DS_E_NOMEMORY a memory allocation failed DS_E_NOERROR the identity information was updated.
◆ DS_BindParams_GetIdentity()
DS_Status DS_BindParams_GetIdentity | ( | const DS_BindParams * | params, |
const DS_Identity ** | id_p | ||
) |
identity for this bind params.
- Parameters
-
[in] params bind parameters. [out] id_p pointer to receive returned reference. This must not be modified, but it may be copied with DS_Identity_Copy. If there is no identity associated with the bind parameters, then id_p will be set to NULL.
- Return values
-
DS_E_BADPARAM params or id_p was NULL DS_E_INTERNAL An internal error occurred DS_E_NOERROR the identity information was returned.
◆ DS_BindParams_GetCertificateServer()
DS_Status DS_BindParams_GetCertificateServer | ( | const DS_BindParams * | params, |
const char ** | ldap_host, | ||
long * | ldap_port, | ||
int * | check_crls | ||
) |
Get the details of the LDAP server used to locate certificates and/or CRLs.
- Parameters
-
[in] params bind parameters. [out] ldap_host pointer to receive returned reference. This is a read-only pointer. If no LDAP server is configured, then ldap_host will be set to NULL. [out] ldap_port port number of LDAP server. A value of zero will be returned if no LDAP server is configured. [out] check_crls non-zero to indicate that CRL checking is required. This parameter may be set to NULL if the caller does not need this information to be returned.
- Return values
-
DS_E_BADPARAM params or ldap_host or ldap_port was NULL DS_E_NOERROR the LDAP server information was returned.
◆ DS_BindParams_SetAnonymous()
DS_Status DS_BindParams_SetAnonymous | ( | DS_BindParams * | params | ) |
Mark this set of bind parameters as being for an anonymous bind.
- Parameters
-
[in] params bind parameters to be updated.
- Return values
-
DS_E_BADPARAM params was NULL DS_E_NOERROR the information was updated and the object is ready to be used to effect a simple bind.
◆ DS_BindParams_SetSimple()
DS_Status DS_BindParams_SetSimple | ( | DS_BindParams * | params, |
const DS_DN * | bind_dn, | ||
const char * | password | ||
) |
Mark this set of bind parameters as being for a simple bind.
- Parameters
-
[in] params bind parameters to be updated. [in] bind_dn DN to bind as [in] password password to use. This may be NULL to indicate a "name only" bind.
- Return values
-
DS_E_BADPARAM params or bindDN was NULL DS_E_MOMEMORY An internal memory allocation failed DS_E_NOERROR the information was updated and the object is ready to be used to effect a simple bind.
◆ DS_BindParams_SetStrong()
DS_Status DS_BindParams_SetStrong | ( | DS_BindParams * | params, |
const DS_Identity * | id, | ||
const DS_DN * | dsa_dn | ||
) |
Mark this set of bind parameters as being for a strong bind.
- Parameters
-
[in] params bind parameters to be updated. [in] id identity information. Must not be NULL; an identity is always required for a strong bind. [in] dsa_dn DN of DSA that is being bound to. This value is required for a DAP strong bind, but ignored for an LDAP strong bind (and so may be NULL)
- Return values
-
DS_E_BADPARAM params or id was NULL DS_E_MOMEMORY An internal memory allocation failed DS_E_NOERROR the information was updated and the object is ready to be used to effect a strong bind.
◆ DS_BindParams_SetSASL()
DS_Status DS_BindParams_SetSASL | ( | DS_BindParams * | params, |
const char * | sasl_mechs, | ||
const DS_SASLProps * | sasl_props, | ||
const char * | sasl_authentication, | ||
const char * | sasl_secret | ||
) |
Mark this set of bind parameters as being for a SASL bind. It only makes sense to do SASL binds on an LDAP connection (not DAP)
- Parameters
-
[in] params bind parameters to be updated. [in] sasl_mechs the SASL mechanism. Depending on mechanism, other parameters may be used [in] sasl_props an optional set of SASL properties to be associated with this bind. This parameter may be NULL. [in] sasl_authentication userid to authenticate with if required (e.g. "user@example.com") [in] sasl_secret SASL secret, or NULL if one is not required for the selected mechanism
- Return values
-
DS_E_BADPARAM params or sasl_mechs was NULL DS_E_MOMEMORY An internal memory allocation failed DS_E_NOERROR the information was updated and the object is ready to be used to effect a SASL bind.
- Since
- DSAPI_VERSION 2041
◆ DS_BindParams_SetSASLRealm()
DS_Status DS_BindParams_SetSASLRealm | ( | DS_BindParams * | params, |
const char * | sasl_realm | ||
) |
Set the SASL realm for this set of (SASL) bind parameters. It only makes sense to do this for an object which is for a SASL bind.
- Parameters
-
[in] params bind parameters to be updated. [in] sasl_realm the SASL realm. This may be NULL to clear any existing "mechanism" in the DS_BindParams structure.
- Return values
-
DS_E_BADPARAM params was NULL, or had not been initialized as a SASL bind type DS_E_MOMEMORY An internal memory allocation failed DS_E_NOERROR the information was updated with the specified realm.
- Since
- DSAPI_VERSION 2048