cvs: pear /Net_LDAP2/LDAP2 LDIF.php
| From: | Benedikt Hallinger | Date: | Tue, 07 Apr 2009 07:06:15 +0000 |
| Subject: | cvs: pear /Net_LDAP2/LDAP2 LDIF.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-55894@lists.php.net to get a copy of this message | ||
beni Tue Apr 7 07:06:15 2009 UTC
Modified files:
/pear/Net_LDAP2/LDAP2 LDIF.php
Log:
* Bugfix in LDIF encoding: Checking of unsafe characters inside string was partly wrong
http://cvs.php.net/viewvc.cgi/pear/Net_LDAP2/LDAP2/LDIF.php?r1=1.5&r2=1.6&diff_format=u
Index: pear/Net_LDAP2/LDAP2/LDIF.php
diff -u pear/Net_LDAP2/LDAP2/LDIF.php:1.5 pear/Net_LDAP2/LDAP2/LDIF.php:1.6
--- pear/Net_LDAP2/LDAP2/LDIF.php:1.5 Tue Apr 7 05:29:18 2009
+++ pear/Net_LDAP2/LDAP2/LDIF.php Tue Apr 7 07:06:15 2009
@@ -42,7 +42,7 @@
* @package Net_LDAP2
* @author Benedikt Hallinger <beni@php.net>
* @license http://www.gnu.org/copyleft/lesser.html LGPL
-* @version CVS: $Id: LDIF.php,v 1.5 2009/04/07 05:29:18 beni Exp $
+* @version CVS: $Id: LDIF.php,v 1.6 2009/04/07 07:06:15 beni Exp $
* @link http://pear.php.net/package/Net_LDAP22/
* @see http://www.ietf.org/rfc/rfc2849.txt
* @todo Error handling should be PEARified
@@ -739,7 +739,7 @@
// Test for illegal content char
for ($i = 0; $i < strlen($attr_value); $i++) {
$char = substr($attr_value, $i, 1);
- if (ord($char) >= 127 || in_array($init_ord, $unsafe)) {
+ if (ord($char) >= 127 || in_array($char, $unsafe)) {
$base64 = true;
}
}