Given just the right pair of private key and input bytes, RsaDigitalSignature.Sign doesn't consistently return a 256-byte array. This makes it impossible to rely upon when signature validation is being performed by another environment (e.g. a Node-based service).
This is a simple repro case using the attached RSA key. The returned length will always be 255 bytes.
```
RsaKey key = ...;
using (RsaDigitalSignature rsa = new RsaDigitalSignature(m_key))
{
byte[] buf = new byte[] { 125, 18, 109, 226, 203, 174, 37, 236 };
byte[] signedBytes = rsa.Sign(buf);
if (signedBytes.Length != 256) {
Console.WriteLine("Bad signature.");
}
}
```
This is a simple repro case using the attached RSA key. The returned length will always be 255 bytes.
```
RsaKey key = ...;
using (RsaDigitalSignature rsa = new RsaDigitalSignature(m_key))
{
byte[] buf = new byte[] { 125, 18, 109, 226, 203, 174, 37, 236 };
byte[] signedBytes = rsa.Sign(buf);
if (signedBytes.Length != 256) {
Console.WriteLine("Bad signature.");
}
}
```