9bd53c2 Ticket #48492 - heap corruption at schema replication.

Authored and Committed by nhosoi 8 years ago
    Ticket #48492 - heap corruption at schema replication.
    
    Description: 389-ds-base-1.3.2 and newer uses openldap schema parser,
    which is more strict with the definition.  For instance, the older
    389-ds-base could have a schema such as SINTAX OID in single quotes,
    which is not acceptable on the newer version.  There was a bug to
    handle the error case that caused a crash.
    
    This patch adds
    1) the null reference check to attr_syntax_free (attrsyntax.c),
    2) a null init to the output arg in parse_at_str and parse_oc_str
       (schema.c) and
    3) an error logging to schema_berval_to_atlist & schema_berval_to_oclist
       (schema.c) for troubleshooting.
    
    https://fedorahosted.org/389/ticket/48492
    
    Reviewed by wibrown@redhat.com and mreynolds@redhat.com (Thank you, William and Mark!)
    
    (cherry picked from commit b5bfa2a0386e168ce2196a077169382ae53a94b4)
    
        
file modified
+15 -1