[Mono-list] TripleDES encryption problem
Carlos Guzman Alvarez
carlosga@telefonica.net
Sat, 30 Aug 2003 01:36:35 +0200
Hello:
> [From my interpretation] the correct padding would be 07 07 07 07 07 07 07
> 07 (8 times 0x07) because the structure is
Huuummmm i'm encrypting the fragment + mac +
padding length, this gives 37 bytes of data and 3 bytes more for
padding, if i'm not wrong the correct padding is
03 03 03
I have checked this on windows and seems to be correct.
And a final note from the Microsoft .NET Framework help:
PaddingMode.PKCS7
The PKCS #7 padding string consists of a sequence of bytes, each of
which is equal to the total number of padding bytes added. For example,
if 24 bits (3 bytes) of padding need to be added, the padding string is
"03 03 03".
I think this matches OK to the padding needed for a TLS implementation (
but can be that i'm, wrong :) )
--
Best regards
Carlos Guzmán Álvarez
Vigo-Spain