Connecting Tech Pros Worldwide Forums | Help | Site Map

domnode hash

Newbie
 
Join Date: Apr 2009
Posts: 4
#1: Apr 9 '09
given a domnode, how to calcuate the hash of this domnode by using the xerces c++

Moderator
 
Join Date: Mar 2006
Posts: 1,103
#2: Apr 14 '09

re: domnode hash


What is your hash function? OR do you want to know what would be a good hash function in this case?
I would consider using the generate-id() function, and then hashing that string.
Newbie
 
Join Date: Apr 2009
Posts: 4
#3: Apr 23 '09

re: domnode hash


I use the SHA1 to hash the domnode. is there any reference on how to generate the hash for the domnode?

I check the DSIGSignature source code on how to generate the digest value. the code is a bit messy and In order to use it, i have to change the content of the domnode ( insert some kind of ID ), which is not desired..can any one help ?
Moderator
 
Join Date: Mar 2006
Posts: 1,103
#4: Apr 24 '09

re: domnode hash


When you're parsing the nodes, are you keeping track of the positions of each node? eg like:
/rootnode/layer1node(5)/layer2node(4)/layer3node(1)
Reply