Greenbone Vulnerability Management Libraries 22.32.0
ldaputils.c File Reference

LDAP-connect Authentication module. More...

#include "ldaputils.h"
Include dependency graph for ldaputils.c:

Go to the source code of this file.

Functions

int ldap_enable_debug ()
 Dummy function for enabling LDAP debugging for manager.
ldap_auth_info_t ldap_auth_info_new (const gchar *ldap_host, const gchar *auth_dn, gboolean allow_plaintext)
 Dummy function for manager.
ldap_auth_info_t ldap_auth_info_new_2 (const gchar *ldap_host, const gchar *auth_dn, gboolean allow_plaintext, gboolean ldaps_only)
 Dummy function for manager.
int ldap_connect_authenticate (const gchar *username, const gchar *password, void *ldap_auth_info, const gchar *cacert)
 Dummy function for Manager.
void ldap_auth_info_free (ldap_auth_info_t info)
 Dummy function for Manager.

Detailed Description

LDAP-connect Authentication module.

Definition in file ldaputils.c.

Function Documentation

◆ ldap_auth_info_free()

void ldap_auth_info_free ( ldap_auth_info_t info)

Dummy function for Manager.

Parameters
infoldap_auth_schema_t to free, can be NULL.

Definition at line 713 of file ldaputils.c.

714{
715 (void) info;
716}

◆ ldap_auth_info_new()

ldap_auth_info_t ldap_auth_info_new ( const gchar * ldap_host,
const gchar * auth_dn,
gboolean allow_plaintext )

Dummy function for manager.

Parameters
ldap_hostHost to authenticate against. Might not be NULL, but empty.
auth_dnDN where the actual user name is to be inserted at "%s", e.g. uid=s,cn=users. Might not be NULL, but empty, has to contain a single s.
allow_plaintextIf FALSE, require StartTLS initialization to succeed.
Returns
NULL.

Definition at line 651 of file ldaputils.c.

653{
654 (void) ldap_host;
655 (void) auth_dn;
656 (void) allow_plaintext;
657 return NULL;
658}

◆ ldap_auth_info_new_2()

ldap_auth_info_t ldap_auth_info_new_2 ( const gchar * ldap_host,
const gchar * auth_dn,
gboolean allow_plaintext,
gboolean ldaps_only )

Dummy function for manager.

Parameters
ldap_hostHost to authenticate against. Might not be NULL, but empty.
auth_dnDN where the actual user name is to be inserted at "%s", e.g. uid=s,cn=users. Might not be NULL, but empty, has to contain a single s.
allow_plaintextIf FALSE, require StartTLS initialization to succeed.
ldaps_onlyWhether to try LDAPS only.
Returns
NULL.

Definition at line 675 of file ldaputils.c.

677{
678 (void) ldap_host;
679 (void) auth_dn;
680 (void) allow_plaintext;
681 (void) ldaps_only;
682 return NULL;
683}

◆ ldap_connect_authenticate()

int ldap_connect_authenticate ( const gchar * username,
const gchar * password,
void * ldap_auth_info,
const gchar * cacert )

Dummy function for Manager.

Parameters
ldap_auth_infoSchema and address to use.
usernameUsername to authenticate.
passwordPassword to use.
cacertCA Certificate for LDAP_OPT_X_TLS_CACERTFILE, or NULL.
Returns
-1.

Definition at line 696 of file ldaputils.c.

699{
700 (void) username;
701 (void) password;
702 (void) ldap_auth_info;
703 (void) cacert;
704 return -1;
705}
Schema (dn) and info to use for a basic ldap authentication.
Definition ldaputils.h:26

◆ ldap_enable_debug()

int ldap_enable_debug ( void )

Dummy function for enabling LDAP debugging for manager.

Returns
Always -1 for failure.

Definition at line 631 of file ldaputils.c.

632{
633 g_warning ("%s: GVM-libs compiled without LDAP", __func__);
634 return -1;
635}