(Deprecated) IXMLParser3 Interface


[Deprecated. Do not use. Superseded by SAX2 API/MSXML 3.0]


This interface is only available for MSXML 3.0 starting with SP5 and above.

This interface is added to set a property ("max-attributes-per-element") that can be used to limit number of attributes per element.

interface IXMLParser3 : IXMLParser2  
    HRESULT SetProperty(  
        [in] const WCHAR* pwcName,  
        [in] VARIANT value);  
    HRESULT GetProperty(  
        [in] const WCHAR* pwcName,  
        [out,retval] VARIANT* value);  

The IXMLParser3 interface inherits directly from the IXMLParser2 interface. Its only difference is the addition of the "max-attributes-per-element" which has a default negative value of -1 to indicate that an unlimited number of attributes will be allowed for an XML element.

The following is an example C++ snippet that shows you can set this property in code:

("max-attributes-per-element" , value )  
                     /* value is a VARIANT containing a LONG */  

This property was added to protect MSXML 3.0 against denial of service attacks.

Note that if a maximum value is specified with this property, it does not include default attributes that are obtained from a DTD or schemas.