Thread: problems exporting key to file, importing in another program

  1. #1
    Registered User
    Join Date
    Oct 2002
    Posts
    69

    problems exporting key to file, importing in another program

    this attempt has been abandoned, looking at another, more elegant way of accomplishing my goal.
















    i am trying to use my keygen program to generate a public/private key pair and export that to a file, and then read that key pair into my encrypting program. the problem is at the call to CryptEncrypt (in the encrypt_data.cpp), it gives me an error of NTE_BAD_KEY, and doesn't encrypt anything. anybody know what i'm doing wrong to either get the key into the encrypting program or calling the CryptEncrypt function? or is it even still a problem with exporting the key to file from the keygen program?

    please see the attached files
    Last edited by talz13; 07-15-2004 at 08:56 AM. Reason: abandoned

  2. #2
    Registered User
    Join Date
    Nov 2001
    Posts
    1,348
    Did you develop the crypto class?

    Kuphryn

  3. #3
    Registered User
    Join Date
    Oct 2002
    Posts
    69
    i'm just using the cryptoAPI as provided in VC++ 6 (wincrypt.h)

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. gcc link external library
    By spank in forum C Programming
    Replies: 6
    Last Post: 08-08-2007, 03:44 PM
  2. Replies: 19
    Last Post: 05-30-2007, 05:47 PM
  3. Unknown Memory Leak in Init() Function
    By CodeHacker in forum Windows Programming
    Replies: 3
    Last Post: 07-09-2004, 09:54 AM
  4. archive format
    By Nor in forum A Brief History of Cprogramming.com
    Replies: 0
    Last Post: 08-05-2003, 07:01 PM
  5. FAQ: Directional Keys - Useing in Console
    By RoD in forum FAQ Board
    Replies: 38
    Last Post: 10-06-2002, 04:42 PM