~ttx/openldap/lucid-gssapi-495418

« back to all changes in this revision

Viewing changes to servers/slapd/sasl.c

  • Committer: Bazaar Package Importer
  • Author(s): Steve Langasek
  • Date: 2009-07-28 10:17:15 UTC
  • mto: (0.3.1 squeeze)
  • mto: This revision was merged to the branch mainline in revision 16.
  • Revision ID: james.westby@ubuntu.com-20090728101715-g0isvetelfeqm48k
Tags: upstream-2.4.17
ImportĀ upstreamĀ versionĀ 2.4.17

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* $OpenLDAP: pkg/ldap/servers/slapd/sasl.c,v 1.239.2.16 2009/01/22 00:01:03 kurt Exp $ */
 
1
/* $OpenLDAP: pkg/ldap/servers/slapd/sasl.c,v 1.239.2.17 2009/06/02 22:09:53 quanah Exp $ */
2
2
/* This work is part of OpenLDAP Software <http://www.openldap.org/>.
3
3
 *
4
4
 * Copyright 1998-2009 The OpenLDAP Foundation.
63
63
 
64
64
static struct berval ext_bv = BER_BVC( "EXTERNAL" );
65
65
 
 
66
char *slap_sasl_auxprops;
 
67
 
66
68
#ifdef HAVE_CYRUS_SASL
67
69
 
 
70
/* Just use our internal auxprop by default */
 
71
static int
 
72
slap_sasl_getopt(
 
73
        void *context,
 
74
        const char *plugin_name,
 
75
        const char *option,
 
76
        const char **result,
 
77
        unsigned *len)
 
78
{
 
79
        if ( strcmp( option, "auxprop_plugin" )) {
 
80
                return SASL_FAIL;
 
81
        }
 
82
        if ( slap_sasl_auxprops )
 
83
                *result = slap_sasl_auxprops;
 
84
        else
 
85
                *result = "slapd";
 
86
        return SASL_OK;
 
87
}
 
88
 
68
89
int
69
90
slap_sasl_log(
70
91
        void *context,
1078
1099
        int rc;
1079
1100
        static sasl_callback_t server_callbacks[] = {
1080
1101
                { SASL_CB_LOG, &slap_sasl_log, NULL },
 
1102
                { SASL_CB_GETOPT, &slap_sasl_getopt, NULL },
1081
1103
                { SASL_CB_LIST_END, NULL, NULL }
1082
1104
        };
1083
1105
#endif