[xmlsec] Troubles using XMLSec with Smart Cards

Hårek Ryeng haarek.ryeng at welldiagnostics.com
Wed Jul 23 13:30:47 PDT 2003


I’m trying to sign an enveloped XML-document with XMLSec using a
SmartCard. 
In order to do so I’ve overloaded the default crypto engine with my own
( handling Smart Card communication).
 
To create the signature template:
xmlSecTmplSignatureCreate(doc, xmlSecTransformInclC14NId,
xmlSecTransformRsaSha1Id, NULL);
 
xmlSecTransformRsaSha1Id is thus the hashing algorithm for the signature
value calculation (behind the scenes in xmlSecDSigCtxSign () ). 
 
In the overloaded
RSA_private_encrypt(int len, const unsigned char *from,  unsigned char
*to, RSA *rsa, int padding)
 
Xmlsec asks to get 35 bytes encrypted (len=35). Normally this would be
no problem (even if it is much for a hash value), but my crypto engine
only handles up to 20 bytes/160 bits at the moment. The cause of the
limitation is outside of my source code, so it is out of my reach
(binary dynamic library)

 
Any suggestions on how to get xmlsec to ask for less bytes to be signed?
 
 
W | Hårek Ryeng, Senior System Developer
E | Well Diagnostics AS, Forskningsparken, 9291 Tromsø
L | Tel: +47 77 75 76 79 (70), Cell: +47 970 05 022, Fax: +47 77 75 76
99
L |  <http://www.welldiagnostics.com/> http://www.welldiagnostics.com/
<http://www.welldiagnostics.com/> 
 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.aleksey.com/pipermail/xmlsec/attachments/20030723/25f154d5/attachment.htm


More information about the xmlsec mailing list