2008-04-21 Sebastien Pouliot <sebastien@ximian.com>
authorSebastien Pouliot <sebastien@ximian.com>
Mon, 21 Apr 2008 13:44:37 +0000 (13:44 -0000)
committerSebastien Pouliot <sebastien@ximian.com>
Mon, 21 Apr 2008 13:44:37 +0000 (13:44 -0000)
* CryptoConvert.cs: Fix HMAC to respect start index inside an array.
Patch by Kazuki Oikawa.

svn path=/trunk/mcs/; revision=101297

mcs/class/Mono.Security/Mono.Security.Cryptography/ChangeLog
mcs/class/Mono.Security/Mono.Security.Cryptography/CryptoTools.cs

index bcdd26d895c0d340a3697fa3fbae2fb0c71f2eea..8a4736e8086e30f0b032584da9347eacb6fdee90 100644 (file)
@@ -1,3 +1,8 @@
+2008-04-21  Sebastien Pouliot  <sebastien@ximian.com>
+
+       * CryptoConvert.cs: Fix HMAC to respect start index inside an array.
+       Patch by Kazuki Oikawa.
+
 2008-03-13  Sebastien Pouliot  <sebastien@ximian.com>
 
        * CryptoConvert.cs: Re-order exception handling to report the most
index a1c5d1f21a168e9da545da060934527b732621dd..256268e39177f20376e4a8400f1fab3a0b4e6516 100644 (file)
@@ -129,7 +129,7 @@ namespace Mono.Security.Cryptography {
                                // 4. if data is still present fill the "block" with the remainder
                                blockCount = cb - n;
                                if (blockCount > 0)
-                                       Buffer.BlockCopy (rgb, n, block, 0, blockCount);
+                                       Buffer.BlockCopy (rgb, n + ib, block, 0, blockCount);
                        }
                }