]> git.sur5r.net Git - openldap/commitdiff
base64 encode userPassword
authorKurt Zeilenga <kurt@openldap.org>
Thu, 5 Aug 1999 00:30:45 +0000 (00:30 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Thu, 5 Aug 1999 00:30:45 +0000 (00:30 +0000)
libraries/libldif/line64.c

index e186d253c6e9c7c5302d38e622b83880f7946c5e..aef935b755c5c9f76c14d5e68da9203607dcebb5 100644 (file)
@@ -393,10 +393,12 @@ ldif_sput(
 
        stop = (unsigned char *) (val + vlen);
 
-       if ( type == LDIF_PUT_VALUE &&
-               isgraph( val[0] ) && val[0] != ':' && val[0] != '<' &&
-               isgraph( val[vlen-1] ) )
-       {
+       if ( type == LDIF_PUT_VALUE
+               && isgraph( val[0] ) && val[0] != ':' && val[0] != '<'
+               && isgraph( val[vlen-1] )
+               && strcasecmp( name, "userPassword" ) != 0      /* encode userPassword */
+               && strcasecmp( name, "2.5.4.35" ) != 0          /* encode userPassword */
+       ) {
                int b64 = 0;
 
                for ( byte = (unsigned char *) val; byte < stop;