]> git.sur5r.net Git - openldap/commitdiff
ITS#2961 check for NULL authcDN
authorHoward Chu <hyc@openldap.org>
Tue, 2 Mar 2004 18:37:49 +0000 (18:37 +0000)
committerHoward Chu <hyc@openldap.org>
Tue, 2 Mar 2004 18:37:49 +0000 (18:37 +0000)
servers/slapd/sasl.c

index 6ebb5d1cf6e2efce4ed0bc272e32fc262bd16503..61d9234a1d22c155ba3795669f7c7793d1a56010 100644 (file)
@@ -897,6 +897,12 @@ slap_sasl_authorize(
        /* Skip PROP_CONN */
        prop_getnames( props, slap_propnames+1, auxvals );
        
+       /* Should not happen */
+       if ( !auxvals[0].values ) {
+               sasl_seterror( sconn, 0, "invalid authcid" );
+               return SASL_NOAUTHZ;
+       }
+
        AC_MEMCPY( &authcDN, auxvals[0].values[0], sizeof(authcDN) );
 
        /* Nothing to do if no authzID was given */