Thread: RSA Encryption Algorithm help

  1. #1
    Registered User
    Join Date
    Apr 2005

    RSA Encryption Algorithm help

    does anyone know how i would encrypt a message using the RSA algorithm.. and them successfully decrypt it to where it is the same message??

    For example... i want to send Bob an encrypted message...

    1) Convert all character values to integer values
    2) Should I keep integer values separate? or together to make it more secret
    3) Run integer values through algorithm
    4) Decrypt message

    <1> A red cat
    'A'= 65
    ' '= 32
    'r' = 114
    'e' = 101
    'd' = 100
    ' '= 32
    'c'= 99
    'a'= 97
    't= 116

    <2> 65 32 114 101 100 32 99 97 116

    <3> Encrypts to 123 34 13 532 243 12 43 76 56

    <4> Decrypt back to orginal values

    How in the world is the person decrypting the values going to transfer the integer values back to the character values if they are all jumbled together??

  2. #2
    Registered User
    Join Date
    Apr 2008
    u can have them spaced by something like -

    or learn how to do trees and put them all into 1s and 0s

    edit: i think this is how it could work with all of them jumbled

    do something where it cuts the decrypted message number by number, then checks it for the values.
    for example

    it would start by cutting it to 1; checks; nothing;
    cuts it into 12; checks; nothing;
    cuts it into 123; checks; match; store the letter into a string; cut the encrypted message;

    Start the loop again.
    Last edited by Furbiesandbeans; 04-27-2008 at 02:02 AM.

  3. #3
    Banned master5001's Avatar
    Join Date
    Aug 2001
    Visalia, CA, USA
    In fact I do. I even have a library I wrote to handle those pesky 100+ digit numbers. But since I already am aware of the fact that you know how to do it (at least on theoretical level) I will just give you a tutorial instead.

    Just do as you've been doing and stick to smaller numbers to get started.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. RSA algorithm implementations and corresponding bin sizes
    By rohit99 in forum C++ Programming
    Replies: 1
    Last Post: 04-03-2008, 08:53 AM
  2. RSA encryption with 1024 bit keys
    By bennyandthejets in forum C++ Programming
    Replies: 23
    Last Post: 09-18-2005, 08:14 AM
  3. Binary Search Trees Part III
    By Prelude in forum A Brief History of
    Replies: 16
    Last Post: 10-02-2004, 03:00 PM
  4. abt encryption algorithm
    By purIn in forum C Programming
    Replies: 9
    Last Post: 12-22-2003, 10:16 PM
  5. RSA Encryption
    By minesweeper in forum Tech Board
    Replies: 6
    Last Post: 08-30-2003, 01:48 PM