Initial conditions:
Private TheKey() As Byte = {1, 2, 3, 4, 5, 6, 7, 8}
Private Vector() As Byte = {&H7C, &H22, &H2F, &HB2, &H92, &H7D, &H82, &H8A}
I then proceed to encrypt the string: "asd" (without quotations) using:
CryptoStream(ms, des.CreateEncryptor(TheKey, Vector), CryptoStreamMode.Write)
input: asd
output: 82804AD2B295E9E3
When i try to encrypt the same string with the same key/vector on http://tripledes.online-domain-tools.com/ as shown below (can't post image due to reputation):
I get a different result.
My ultimate goal is to have this output decrypted in a C application. But two 3DES encryptors giving 2 different results is a show stopper.. Any thoughts about what could be causing this ?
Thanks in advance!
A good idea to test your crypto against some other "oracle". But two issues apparent with your use of the online tool:
However that site gives me the same encrypted text for both DES and 3DES, so it may not be a reliable oracle anyway? Try another, but may need to use a plain text key (first two I looked at didn't offer hex input in any obvious way)