EldoS | Feel safer!

Software components for data protection, secure storage and transfer

How to add <CommitmentTypeIndication> in the signature output?

Also by EldoS: CallbackProcess
A component to control process creation and termination in Windows and .NET applications.
#30374
Posted: 08/15/2014 05:58:23
by Venkat S (Basic support level)
Joined: 08/14/2014
Posts: 9

hi,
My requirement is:
Code
            <xades:SignedDataObjectProperties>
               <xades:DataObjectFormat ObjectReference="#xmldsig-ref0">
               ....
               </xades:DataObjectFormat>
               <xades:DataObjectFormat ObjectReference="#xmldsig-ref1">
                  ....
               </xades:DataObjectFormat>
               <xades:CommitmentTypeIndication>
                  <xades:CommitmentTypeId>
                     <xades:Identifier>abc</xades:Identifier>
                  </xades:CommitmentTypeId>
                  <xades:ObjectReference>xmldsig-ref0</xades:ObjectReference>
               </xades:CommitmentTypeIndication>
               <xades:CommitmentTypeIndication>
                  <xades:CommitmentTypeId>
                     <xades:Identifier>def</xades:Identifier>
                  </xades:CommitmentTypeId>
                  <xades:ObjectReference>xmldsig-ref1</xades:ObjectReference>
               </xades:CommitmentTypeIndication>
            </xades:SignedDataObjectProperties>


I am able to get the <DataObjectFormat> but not the <CommitmentTypeIndication>. I can see there's a API:
Code
XAdESSigner.QualifyingProperties.SignedProperties.SignedDataObjectProperties.CommitmentTypeIndications
but dont know how to populate this. Knowledgebase couldn't help either.

Thanks.
#30375
Posted: 08/15/2014 06:43:00
by Dmytro Bogatskyy (EldoS Corp.)

Thank you for contacting us.

CommitmentTypeIndications property is a list, so you need to create TElXMLCommitmentTypeIndication objects and add it.
For example:
Code
XAdESSigner.Generate();  // Generate XAdES structure, the code below should be added after this method
...
TElXMLCommitmentTypeIndication Item = new TElXMLCommitmentTypeIndication(XAdESSigner.XAdESVersion);
Item.CommitmentTypeId.Identifier = "abc";
Item.ObjectReference.Add("xmldsig-ref0");
XAdESSigner.QualifyingProperties.SignedProperties.SignedDataObjectProperties.CommitmentTypeIndications.Add(Item);

Reply

Statistics

Topic viewed 537 times

Number of guests: 1, registered members: 0, in total hidden: 0




|

Back to top

As of July 15, 2016 EldoS Corporation will operate as a division of /n software inc. For more information, please read the announcement.

Got it!