Padding issue with C++ Crypto RC2 encryption
From: kishore (kishore_at_discussions.microsoft.com)
Date: 01/26/05
- Next message: dotNETDavid: "USA export restrictions for .NET Framework due to security feature"
- Previous message: Shawn Farkas [MS]: "Re: How is .net generating extra bits in MD5?"
- Next in thread: kishore: "RE: Padding issue with C++ Crypto RC2 encryption"
- Reply: kishore: "RE: Padding issue with C++ Crypto RC2 encryption"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Wed, 26 Jan 2005 10:45:07 -0800
Hello, I'm using the Crypto API RC2 encryption under Visual Studio 6 C++.
I've written some code and got encryption and decryption working fine.
The problem is when data is encrypted, the data is padded to accommodate for
block size. So I have the data encrypted with these additional characters.
The problem then is when I decrypt it, I get back the decrypted data with
the additional characters. My question(s) are :
1. How can I prevent the additional characters being padded and encrypted?
Is this even possible?
2. If I can't prevent #1 above, how can I extract only the encrypted
substring associated with the original string. If my original string was
"hello", I tried extracting only 5 chars from the encrypted string so I could
use this for decryption to get back "hello", but this didn't work.
Is there a one to one correspondence between the length of a string and the
lenght of an encrypted string? E.g. If have the string "hello" and have it
encrypted, will each letter in "hello" be associated with a single character
in the encrypted string?
Thanks.
- Next message: dotNETDavid: "USA export restrictions for .NET Framework due to security feature"
- Previous message: Shawn Farkas [MS]: "Re: How is .net generating extra bits in MD5?"
- Next in thread: kishore: "RE: Padding issue with C++ Crypto RC2 encryption"
- Reply: kishore: "RE: Padding issue with C++ Crypto RC2 encryption"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|