lovele0107 / signatures-conformance-checker

7 stars 0 forks source link

XAdES : SPDocSpecification signature policy qualifier is not supported #17

Open bsanchezb opened 3 years ago

bsanchezb commented 3 years ago

Hello Juan Carlos,

When I validate a signature containing a xades141:SPDocSpecification qualifier, the following error is returned:

Children order and number DO NOT MATCH 
specificationSpecification: (xadesv132:SPURI \|\| xadesv132:SPUserNotice)+
Elements found: xadesv141:SPDocSpecification
Error indication (^ appears at the end of the last correct child): ^xadesv141:SPDocSpecification

This particular qualifier has been introduced in EN 319 132-1 (maybe earlier, but nevertheless it was not there in old versions), however the relative XAdESCC still does not support it.

The SPDocSpecification shall identify the technical specification that defines the syntax used for producing the signature policy document. The SPDocSpecification shall be defined as in XML Schema file "XAdES01903v141-201601.xsd", whose location is detailed in clause C.2, and is copied below for information.

<xsd:element name="SPDocSpecification" type="xades:ObjectIdentifierType"/> 

Moreover, I think the problem is more global, because XAdESCC restricts other qualifiers, except the SPURI and SPUserNotice, when from the specification and schema it is clear that any custom qualifier should be allowed:

<xsd:complexType name="SigPolicyQualifiersListType">
   <xsd:sequence>
       <xsd:element name="SigPolicyQualifier" type="AnyType" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Could you please add a support for other qualifiers?

Best regards, Aleksandr.

bsanchezb commented 3 years ago

The file from the test (archived)

sigPolicy-with-SPDocSpecification.zip

jccruellas commented 3 years ago

Thanks for this ALeksandr, I have a number of issues to close and indeed this one is added to the pile. I am now fixing some issues on PAdESCC

Regards Juan Carlos.