I am not sure what are you signing in this example. The result of the reference eveluation is an empty string (document consist of one <dsig:Signature> node and you use enveloped transform). I guess the code was aborted before it get chance to verify digest. Aleksey