[xmlsec] Problem signing xml

Aleksey Sanin aleksey at aleksey.com
Sat Oct 14 14:27:23 PDT 2017


You have a problem in the SignatureNode definition as indicated by the
error message.

Aleksey

On 10/14/17 6:02 AM, Balamurali Pandranki wrote:
> 
> Command : 
> 
> xmlsec1 --sign --pkcs12 Staging_Signature_PrivateKey.p12 --pwd public
> --output /Users/itsbalamurali/Workspace/out.xml
> /Users/itsbalamurali/Workspace/in.xml
> 
> XMLSEC1 VERSION: xmlsec1 1.2.20 (openssl)
> 
> XML trying to sign:
> 
> <?xmlversion='1.0'encoding='UTF-8'?>
> <Otpuid="999999990019"type="A"tid="public"lk="MEaMX8fkRa6PqsqK6wGMrEXcXFl_oXHA-YuknI2uf0gKgZ80HaZgG3A"ver="1.6"txn="WieW8ZTFp0"ac="public"sa="public">
> <Optsch="00"></Opts>
> <Signaturexmlns="http://www.w3.org/2000/09/xmldsig#">
> <SignedInfoxmlns="http://www.w3.org/2000/09/xmldsig#">
> <CanonicalizationMethodxmlns="http://www.w3.org/2000/09/xmldsig#"Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"></CanonicalizationMethod>
> <SignatureMethodxmlns="http://www.w3.org/2000/09/xmldsig#"Algorithm=""></SignatureMethod>
> <Referencexmlns="http://www.w3.org/2000/09/xmldsig#">
> <Transformsxmlns="http://www.w3.org/2000/09/xmldsig#">
> <Transformxmlns="http://www.w3.org/2000/09/xmldsig#"Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature"></Transform>
> <Transformxmlns="http://www.w3.org/2000/09/xmldsig#"Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"></Transform>
> </Transforms>
> <DigestMethodxmlns="http://www.w3.org/2000/09/xmldsig#"Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"></DigestMethod>
> <DigestValuexmlns="http://www.w3.org/2000/09/xmldsig#"></DigestValue>
> </Reference>
> </SignedInfo>
> <SignatureValuexmlns="http://www.w3.org/2000/09/xmldsig#"></SignatureValue>
> <KeyInfoxmlns="http://www.w3.org/2000/09/xmldsig#">
> <X509Dataxmlns="http://www.w3.org/2000/09/xmldsig#">
> <X509Certificatexmlns="http://www.w3.org/2000/09/xmldsig#"></X509Certificate>
> </X509Data>
> </KeyInfo>
> </Signature>
> </Otp>
> 
> Error:
> 
> func=xmlSecTransformNodeRead:file=transforms.c:line=1543:obj=unknown:subj=xmlSecTransformIdListFindByHref:error=1:xmlsec
> library function failed:href=
> func=xmlSecTransformCtxNodeRead:file=transforms.c:line=694:obj=unknown:subj=xmlSecTransformNodeRead:error=1:xmlsec
> library function failed:name=SignatureMethod
> func=xmlSecDSigCtxProcessSignedInfoNode:file=xmldsig.c:line=742:obj=unknown:subj=xmlSecTransformCtxNodeRead:error=1:xmlsec
> library function failed:node=SignatureMethod
> func=xmlSecDSigCtxProcessSignatureNode:file=xmldsig.c:line=547:obj=unknown:subj=xmlSecDSigCtxProcessSignedInfoNode:error=1:xmlsec
> library function failed:
> func=xmlSecDSigCtxSign:file=xmldsig.c:line=303:obj=unknown:subj=xmlSecDSigCtxSignatureProcessNode:error=1:xmlsec
> library function failed:
> Error: signature failed
> 
> 
> Thanks,
> *Balamurali Pandranki,*
> Phone: +91-9908640059,
> Work: murali at labwire.tech.
> 
> 
> _______________________________________________
> xmlsec mailing list
> xmlsec at aleksey.com
> http://www.aleksey.com/mailman/listinfo/xmlsec
> 


More information about the xmlsec mailing list