[xmlsec] How to encrypt only some Subnodes?

Martin Salo Martin.Salo at gmx.net
Thu Aug 2 06:09:29 PDT 2007


Hello Mailinglist,

I'm analysing encrypt2.c.
In the beginning of function encrypt_file() were the encryption nodes created. It seems that function xmlSecTmplEncDataCreate() creates an EncryptedData node on the root, followed by some other functions that creates CipherValue and KeyInfo. But what can I do if I only want to encrypt 2 or 3 subnodes and not the whole document?

If I look through the section xmltree, I see functions like xmlSecFindNode(). In this way I can go through the xml document to find the nodes I want to encrypt. But how can I add the encryption nodes on this position? (Function xmlSecTmplEncDataCreate() doese not offer a parameter xmlNodePtr_TargetNode to specify the place where the encryption should start.)


Regards

Martin
-- 
Ist Ihr Browser Vista-kompatibel? Jetzt die neuesten 
Browser-Versionen downloaden: http://www.gmx.net/de/go/browser



More information about the xmlsec mailing list