| arkady55 2004-04-07, 8:42 am |
| Hi,
I have faced a new problem related to generation of digital signature
on Microsoft .NET platform and it's verification on Java platform.
I create a digital signature in my C# (Microsoft ASP.NET) application.
The public/private keys are generated by another C# application and it
saves the key parameters to the appropriate XML files.
In my Java application I create the PublicKey object using the
parameters P, G, Q, Y of the public key, that I get from the public
key XML, generated by my C# application.
I try to verify the digital signature in my Java program.
But I get the "Invalid encoding for signature" exception when I call
the verify() method of the Signature object.
I have succeed to create & verify the signature in the Java program
using the private/public keys parameters, generated by C#
application.
I have also succeed to generate and verify the digital signature in my
C# applications, using the private/public keys parameters saved in XML
file.
I use the "DSA with SHA1" algorithm.
I apply the base64 encoding (in C# app) / decoding (in Java app) to
the signature.
I have compared the base64 encoded Signature, Signature as byte
array, message & message digest(which I sign) on both sides (C# &
Java).
All appropriate values are identical.
Do you have any idea about this???
Regards,
Arkady
|