Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Ruby > Decryption in ruby

Thread Tools

Decryption in ruby

Vetrivel Vetrivel
Posts: n/a
I have a decryption doutes in ruby.

A person encrypts the data in c# language using
RSACryptoServiceProvider class.
Example RSA decryption in c# Language

Deryption Algorithm in C#

public static string DecryptData(string data2Decrypt)
byte[] getpassword = Convert.FromBase64String(data2Decrypt);
StreamReader reader = new StreamReader(@"C:\Keys\privatekey.xml");
string publicPrivateKeyXML = reader.ReadToEnd();
//read ciphertext, decrypt it to plaintext
byte[] plain = rsa.Decrypt(getpassword, false);
return System.Text.Encoding.UTF8.GetString(plain);

How to do c# Decryption in ruby.
Posted via

Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem with decryption Showjumper ASP .Net 4 01-27-2006 10:40 PM
Problem with decryption Showjumper ASP .Net 2 01-23-2006 06:29 PM
NCrypto Encryption & Decryption ASP .Net 2 05-03-2005 01:14 AM
Forms Authentication Fails Between ASP.NET 1.0 and 1.1 Applications (Cookie Decryption Fails) John Saunders ASP .Net 1 11-18-2003 03:25 PM
database connection string encryption and decryption Srinivasa Reddy K Ganji ASP .Net 1 07-18-2003 11:30 AM