|
[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Problems with refefinements of xmldsig-core-schema and xenc-schema
Title: Problems with refefinements of xmldsig-core-schema and xenc-schema Hello List, for our needs we need to constrain the official w3c signature and encryption schemas xdsig-core-schema.xsd and xenc-schema using the xml-schema-redefine mechanismen. Unfortunately doing this we obtain error-messages regarding of namecollisions of the complextypes defined in the original w3c-schemas and the refined schemas during the validation of the redefined schemas. Our proceding is as follows:
Redefine xmldsig-core-schema:
<!-- ### redefinitions ### -->
2. Starting with a valid xenc-schema.xsd we construct a schema named redefined-xenc.xsd listed below, which is also valid. Redefine xenc-schema:
<xsd:import namespace="http://www.w3.org/2000/09/xmldsig#" schemaLocation="file:///E:/SQC/w3c/xmldsig-core-schema.xsd"/> <xsd:redefine schemaLocation="file:///E:/SQC/w3c/xenc-schema.xsd"></xsd:redefine>
So our first questions is, why isn't it allowed to import the redefined xmldsig-core-schema.xsd in refefined-xenc.xsd.? 3. In the third step we construct a schema base.xsd which imports the redefined.sig.xsd and the redefined-xenc.xsd.
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="file:///E:/SQC/w3c/xml.xsd"/>
<xsd:import namespace="http://www.w3.org/2001/04/xmlenc#" schemaLocation="file:///E:/SQC/w3c/xenc-schema.xsd"/>-->
During validation we get 49 name-collission- error in our target-namespace.
name collision in <schema targetNamespace="http://www.test.de/2002/04/test" >. The following components are defined more than once: complexType http://www.w3.org/2000/09/xmldsig#:CanonicalizationMethodType [ located at file:///e:/sqc/w3c/xmldsig-core-schema.xsd ] complexType http://www.w3.org/2000/09/xmldsig#:CanonicalizationMethodType [ located at file:///e:/sqc/w3c/xmldsig-core-schema.xsd ] . Suggested action: Change the names to be unique We assume this is caused by the import statement of xdsig-core-schema.xsd in the xenc.schema.xsd.
Recapitulating we obtain the following error-messages during validation:
2.1. redefined-enc.xsd with import of redefined-sig.xsd ---> name collissions of the complextypes defined in redefined-sig and xmldsig-coreschema 2.2 redefined-enc.xsd with import of xdsig-core-schema.xsd ---> valid, but in this case there no use to redefine xmldsig-core-schema.xsd in our opinion 3.1 base.xsd with import of the xenc-schema and the xmldsig-core-schema.xsd --> valid, but no use for redefinements
Validation is done by the Schema Quality Checker from alphaworks. In order to analyse the errors we defined own schemas to model the situation.
With these schemas we obtain the same error-messages with respect of the name-collissions when imorting the redefineofschema1.xsd instead of schema1.xsd in redefineofschema2.xsd. But we get a correct validation when using the redefinements of schema 1 und 2 in another schema (schema3) with an own namespace in contrast to the situation with the signature/encryption.schemas.. Comprising we have the following questions:
Thank you for your help and best regards,
zipped_redefinements_of_sig_xenc.zip
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|
|||||||||

Cart








