I have to verify some asn.1 (der) structure, which has been signed using X.509 Certificate (SHA1withRSA).
Problem is that this structure is not directly signed but it contains signature inside in some node. It makes me unable to verify this using java.security.Signature.verify().
Any suggestions how can I do that in Java?
What you need to do is to use the BouncyCastle's ASN library, extract the signed object from the inner node and then verify it with the Signature object. The BC class library is very comprehensive in its ability to deal with ASN.1 structures: http://bouncycastle.org/docs/docs1.6/index.html.