Click here to Skip to main content
15,895,084 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: DES Encryption Pin
jkirkerx16-Dec-11 10:31
professionaljkirkerx16-Dec-11 10:31 
GeneralRe: DES Encryption Pin
Randor 16-Dec-11 11:04
professional Randor 16-Dec-11 11:04 
GeneralRe: DES Encryption Pin
jkirkerx16-Dec-11 12:06
professionaljkirkerx16-Dec-11 12:06 
GeneralRe: DES Encryption Pin
Randor 16-Dec-11 13:25
professional Randor 16-Dec-11 13:25 
GeneralRe: DES Encryption Pin
jkirkerx17-Dec-11 8:05
professionaljkirkerx17-Dec-11 8:05 
GeneralRe: DES Encryption Pin
Randor 17-Dec-11 9:47
professional Randor 17-Dec-11 9:47 
GeneralRe: DES Encryption Pin
jkirkerx17-Dec-11 20:49
professionaljkirkerx17-Dec-11 20:49 
GeneralRe: DES Encryption Pin
Randor 18-Dec-11 3:55
professional Randor 18-Dec-11 3:55 
Hi,

Wow, what time zone are you in? The sun was rising out in the Atlantic ocean when you responded. Poke tongue | ;-P

jkirkerx wrote:
It's either this MS_ENHANCED_PROV, PROV_RSA_FULL, or the key not being in the right format, or perhaps 5 other possibilities.


Your not giving enough information... you need to tell me exactly which algorithm is not returning the expected value. The DES, 3DES, MD5 and Base64 algorithms are very standard... the only thing that would make them return an unexpected value... is an initialization vector or hash salt.

If you control both the ASP.NET and C++ source codes... could you step through a debugger in both and determine exactly which algorithm returns a different value?

The CryptSetKeyParam function[^] with either KP_SALT, KP_SALT_EX, KP_IV would potentially cause an encryption/hash algorithm to return an unexpected value. This is exactly what it is suppose to do...

You need to make sure salt and initialization vectors are the same in both your ASP.NET and C++ implementations.

Best Wishes,
-David Delaune

[EDIT]
I just recieved and read your e-mail. I'll take a look the source code you provided and we can correspond through e-mail from here. -Dave

modified 18-Dec-11 11:36am.

GeneralRe: DES Encryption Pin
jkirkerx18-Dec-11 8:32
professionaljkirkerx18-Dec-11 8:32 
GeneralRe: DES Encryption Pin
Randor 18-Dec-11 11:29
professional Randor 18-Dec-11 11:29 
GeneralRe: DES Encryption Pin
jkirkerx18-Dec-11 14:18
professionaljkirkerx18-Dec-11 14:18 
GeneralRe: DES Encryption Pin
Randor 19-Dec-11 6:19
professional Randor 19-Dec-11 6:19 
GeneralRe: DES Encryption Pin
jkirkerx19-Dec-11 8:06
professionaljkirkerx19-Dec-11 8:06 
GeneralRe: DES Encryption Pin
Randor 19-Dec-11 8:29
professional Randor 19-Dec-11 8:29 
GeneralRe: DES Encryption Pin
jkirkerx19-Dec-11 8:47
professionaljkirkerx19-Dec-11 8:47 
GeneralRe: DES Encryption Pin
jkirkerx19-Dec-11 9:30
professionaljkirkerx19-Dec-11 9:30 
GeneralRe: DES Encryption Pin
Randor 19-Dec-11 10:36
professional Randor 19-Dec-11 10:36 
GeneralRe: DES Encryption Pin
jkirkerx19-Dec-11 10:53
professionaljkirkerx19-Dec-11 10:53 
GeneralPerfect Match! Pin
jkirkerx19-Dec-11 12:13
professionaljkirkerx19-Dec-11 12:13 
GeneralRe: Perfect Match! Pin
Randor 19-Dec-11 14:03
professional Randor 19-Dec-11 14:03 
GeneralRe: Perfect Match! Pin
jkirkerx19-Dec-11 14:49
professionaljkirkerx19-Dec-11 14:49 
GeneralRe: DES Encryption Pin
jkirkerx16-Dec-11 7:59
professionaljkirkerx16-Dec-11 7:59 
AnswerSymmetric-key - Initialization Vector Pin
jkirkerx16-Dec-11 18:04
professionaljkirkerx16-Dec-11 18:04 
GeneralRe: Symmetric-key - Initialization Vector Pin
Chris Losinger17-Dec-11 9:38
professionalChris Losinger17-Dec-11 9:38 
QuestionInterview Preparation Pin
pix_programmer15-Dec-11 18:23
pix_programmer15-Dec-11 18:23 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.