Closed Bug 59616 Opened 24 years ago Closed 6 years ago

v4.1, Coding error in LDAPSchemaElement.java, line 427

Categories

(Directory :: LDAP Java SDK, defect, P3)

x86
Windows 2000
defect

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: joes, Assigned: erhyuan)

Details

ldapjdk.jar 4.1
LDAPSchemaElement.java, function  parseValue( String raw ), line 407

Siemens DirX LDAP-directory delivers MUST and MAY attribute lists WITHOUT 
whitespaces i.e "MAY (1.2.3.4 $ 2.3.4.5)".

I think there is a coding error in line 407 (LDAPSchemaElement.java). Last 
character of last attributetype will be cut off --> "2.3.4." instead 
of "2.3.4.5"
Proposed fix beginning with line 427:
------------------------------
                    
                    // Nov-10-00: Joe Schneider, Terrasoft Software GmbH
                    // joes@terrasoft.de
                    // OLD: val = new String( ch, ind, last-ind-1 );
                    while ( ch[--last] == ' ' );
                    val = new String( ch, ind, last-ind + 1 );

------------------------------
Summary: v4.1, Coding error in LDAPSchemaElement.java, line 407 → v4.1, Coding error in LDAPSchemaElement.java, line 427
Thanks for the report and proposed fix.  Reassigning to Miodrag (Java LDAP SDK
lead).
Assignee: mcs → miodrag
Correction to proposal:

                    // Nov-10-00: Joe Schneider, Terrasoft Software GmbH
                    // joes@terrasoft.de
                    // OLD: val = new String( ch, ind, last-ind-1 );
                    int lastchar=last;
                    while ( ch[--lastchar] == ' ' );
                    val = new String( ch, ind, lastchar-ind+1 );
Changed status to assigned
Status: NEW → ASSIGNED
Reassign LDAP JDK bugs owned by Miodrag (miodrag@formerly-netscape.com.tld) to
E-Y (erhyuan@pacbell.net)
Assignee: miodrag → erhyuan
Status: ASSIGNED → NEW
Not activity for at least 6 years, closing.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.