[xmlsec] detached encrypted key

Varun Sekhri varunsekhri at yahoo.co.uk
Fri Oct 29 12:09:39 PDT 2004


Hello Aleksey,
Please look at the xml file again.
1) Our cases are different. I encrypted a symmetric
key
using a public key in the EncryptedKey Element. So
after decryption what i get is key value(it is not
text they are some octets). I read the code of
xmlsec1.2.6.  in function xmlSecEncCtxDecrypt, in both
cases 
of "content"  and "element" xmlSecReplaceNodeBuffer is
there.
 ( which might be correct too) . I get parser error.

( Reading the code and comments i can say that
xmlSecEncCtxDecrypt was written so that the node
passed in the function will be EncryptedData elment
not EncryptedKey)

2) If i tell the parser about those Ids on my own,
then when the xmlsec will read the EncryptedKey or 
EncryptedData for decryption, it will also try to
register them, libxml2 would or should flash an error
in that case.

thanks and regards
nitin
 --- Aleksey Sanin <aleksey at aleksey.com> wrote: 
> 
> > My questions are
> > 1. When i try to decrypt the encrypted data
> element, 
> > in the key info element, the xmlsec tries to
> evaluate
> > the Xpointer expression for the URI attribute of 
> > RetreivalMethod element and fails as "EK" is not
> > registered yet.
> Yes. You have to tell the parser that this is an ID
> attribute.
> 
> 
> > 
> > 2. When I try to decrypt the encrypted key
> element, 
> > xmlsec tries to replace the encrypted key element,
> by 
> > calling xmlSecReplaceNodeBuffer, even though the
> Type
> > attribute says "content". I got the internal
> parser
> > error. ( there is no well formed xml data, it is
> key,
> > so supposedly fails).
> Which version of xmlsec are you using?
> 
> Aleksey
> 
> 
> 
> _______________________________________________
> xmlsec mailing list
> xmlsec at aleksey.com
> http://www.aleksey.com/mailman/listinfo/xmlsec
>  


	
	
		
___________________________________________________________ALL-NEW Yahoo! Messenger - all new features - even more fun! http://uk.messenger.yahoo.com


More information about the xmlsec mailing list