Solved

CryptoImportPublicKeyInfo

Posted on 2000-05-09
2
143 Views
Last Modified: 2010-04-02
I'm tyring to import a public key for encrypting a string.  The problem is this is the most neglected area as far as sample code.  My current code fails, but I'm not sure that my code is 100% accurate.  Anyone have any sample code with importing a public key?
0
Comment
Question by:MUpchu777
  • 2
2 Comments
 
LVL 6

Expert Comment

by:Talmash
ID: 2799931
hi ,

I'll try 2 ways helping you :

1st of all : what code do you want to implement ? RSA , DES ??


1. I sent your ask to a friend working with public/private codes over all sort of systems your username , maybe he'll answer you .


2. try my suggestion :

2.1 read the file that include the desired code .
2.2 the code should be in a specific area/field at the file , so , the program could isolate the bits of the code from other headers/tails who-ever-knows that open/close the data-file which sent by other to you .
2.3 after you gave a parameter the value of the code for example :
      (n='100110011001000101011..'
2.4 you should do (for example RSA code)


(encrypted data)=[(word_data)^x mod n]

x=private key
n=public key

2.5 if its not RSA , replace 2.4 with the proper function .

2.6 for decoding , use cryptography books , or ask me .

Talmash
0
 
LVL 6

Accepted Solution

by:
Talmash earned 100 total points
ID: 2799945
hi ,

I'll try 2 ways helping you :

1st of all : what code do you want to implement ? RSA , DES ??


1. I sent your ask to a friend working with public/private codes over all sort of systems your username , maybe he'll answer you .

2. try my suggestion :
2.1 read the file that include the desired code .
2.2 the code should be in a specific area/field at the file , so , the program could isolate the bits of the code from other headers/tails who-ever-knows that open/close the data-file which sent by other to you .
2.3 after you gave a parameter the value of the code for example :
       (n='100110011001000101011..'
2.4 you should do (for example RSA code)

(encrypted data)=[(word_data)^x mod n]
 x=private key
 n=public key
2.5 if its not RSA , replace 2.4 with the proper function .
2.6 for decoding , use cryptography books , or ask me .

                          Talmash
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

In days of old, returning something by value from a function in C++ was necessarily avoided because it would, invariably, involve one or even two copies of the object being created and potentially costly calls to a copy-constructor and destructor. A…
This article shows you how to optimize memory allocations in C++ using placement new. Applicable especially to usecases dealing with creation of large number of objects. A brief on problem: Lets take example problem for simplicity: - I have a G…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now