Author: spouliot
Date: 2005-04-18 08:58:51 -0400 (Mon, 18 Apr 2005)
New Revision: 43213

Modified:
   branches/mono-1-0/mcs/class/corlib/Mono.Security.Cryptography/ChangeLog
   
branches/mono-1-0/mcs/class/corlib/Mono.Security.Cryptography/SymmetricTransform.cs
Log:
2005-04-18  Sebastien Pouliot  <[EMAIL PROTECTED]>

        * SymmetricTransform.cs: Fixed a division by zero if someone changes 
        the feedback value to 0.



Modified: 
branches/mono-1-0/mcs/class/corlib/Mono.Security.Cryptography/ChangeLog
===================================================================
--- branches/mono-1-0/mcs/class/corlib/Mono.Security.Cryptography/ChangeLog     
2005-04-18 12:57:51 UTC (rev 43212)
+++ branches/mono-1-0/mcs/class/corlib/Mono.Security.Cryptography/ChangeLog     
2005-04-18 12:58:51 UTC (rev 43213)
@@ -1,3 +1,8 @@
+2005-04-18  Sebastien Pouliot  <[EMAIL PROTECTED]>
+
+       * SymmetricTransform.cs: Fixed a division by zero if someone changes 
+       the feedback value to 0.
+
 2004-12-06  Sebastien Pouliot  <[EMAIL PROTECTED]>
 
        * RSAManaged.cs: Implement key blinding for RSA decryption with, or

Modified: 
branches/mono-1-0/mcs/class/corlib/Mono.Security.Cryptography/SymmetricTransform.cs
===================================================================
--- 
branches/mono-1-0/mcs/class/corlib/Mono.Security.Cryptography/SymmetricTransform.cs
 2005-04-18 12:57:51 UTC (rev 43212)
+++ 
branches/mono-1-0/mcs/class/corlib/Mono.Security.Cryptography/SymmetricTransform.cs
 2005-04-18 12:58:51 UTC (rev 43213)
@@ -6,12 +6,8 @@
 //     Sebastien Pouliot <[EMAIL PROTECTED]>
 //
 // Portions (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
-// (C) 2004 Novell (http://www.novell.com)
+// Copyright (C) 2004-2005 Novell, Inc (http://www.novell.com)
 //
-
-//
-// Copyright (C) 2004 Novell, Inc (http://www.novell.com)
-//
 // Permission is hereby granted, free of charge, to any person obtaining
 // a copy of this software and associated documentation files (the
 // "Software"), to deal in the Software without restriction, including
@@ -69,7 +65,8 @@
                        Buffer.BlockCopy (rgbIV, 0, temp, 0, BlockSizeByte);
                        temp2 = new byte [BlockSizeByte];
                        FeedBackByte = (algo.FeedbackSize >> 3);
-                       FeedBackIter = (int) BlockSizeByte / FeedBackByte;
+                       if (FeedBackByte != 0)
+                               FeedBackIter = (int) BlockSizeByte / 
FeedBackByte;
                        // transform buffers
                        workBuff = new byte [BlockSizeByte];
                        workout =  new byte [BlockSizeByte];

_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to