mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-24 00:29:35 -05:00
propagate flags to sasl-regexp functions (will need it later)
This commit is contained in:
parent
113727ba53
commit
42d7d6d743
3 changed files with 7 additions and 5 deletions
|
|
@ -989,7 +989,8 @@ LDAP_SLAPD_F (int) slap_parse_user LDAP_P((
|
|||
LDAP_SLAPD_F (void) slap_sasl2dn LDAP_P((
|
||||
Operation *op,
|
||||
struct berval *saslname,
|
||||
struct berval *dn ));
|
||||
struct berval *dn,
|
||||
int flags ));
|
||||
LDAP_SLAPD_F (int) slap_sasl_authorized LDAP_P((
|
||||
Operation *op,
|
||||
struct berval *authcid,
|
||||
|
|
|
|||
|
|
@ -1970,7 +1970,7 @@ int slap_sasl_getdn( Connection *conn, Operation *op, char *id, int len,
|
|||
}
|
||||
|
||||
/* Run thru regexp */
|
||||
slap_sasl2dn( op, dn, &dn2 );
|
||||
slap_sasl2dn( op, dn, &dn2, flags );
|
||||
if( dn2.bv_val ) {
|
||||
sl_free( dn->bv_val, op->o_tmpmemctx );
|
||||
*dn = dn2;
|
||||
|
|
|
|||
|
|
@ -492,7 +492,8 @@ static void slap_sasl_rx_exp(
|
|||
LDAP URI to find the matching LDAP entry, using the pattern matching
|
||||
strings given in the saslregexp config file directive(s) */
|
||||
|
||||
static int slap_sasl_regexp( struct berval *in, struct berval *out, void *ctx )
|
||||
static int slap_sasl_regexp( struct berval *in, struct berval *out,
|
||||
int flags, void *ctx )
|
||||
{
|
||||
char *saslname = in->bv_val;
|
||||
SaslRegexp_t *reg;
|
||||
|
|
@ -812,7 +813,7 @@ COMPLETE:
|
|||
* entry, return the DN of that one entry.
|
||||
*/
|
||||
void slap_sasl2dn( Operation *opx,
|
||||
struct berval *saslname, struct berval *sasldn )
|
||||
struct berval *saslname, struct berval *sasldn, int flags )
|
||||
{
|
||||
int rc;
|
||||
slap_callback cb = { NULL, sasl_sc_sasl2dn, NULL, NULL };
|
||||
|
|
@ -835,7 +836,7 @@ void slap_sasl2dn( Operation *opx,
|
|||
cb.sc_private = sasldn;
|
||||
|
||||
/* Convert the SASL name into a minimal URI */
|
||||
if( !slap_sasl_regexp( saslname, ®out, opx->o_tmpmemctx ) ) {
|
||||
if( !slap_sasl_regexp( saslname, ®out, flags, opx->o_tmpmemctx ) ) {
|
||||
goto FINISHED;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue