Skip to content

Commit 0317d35

Browse files
committed
.NET 1.1 fixes
1 parent a3a07f7 commit 0317d35

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

crypto/src/crypto/modes/GcmSivBlockCipher.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -724,7 +724,7 @@ private static void mulX(byte[] pValue)
724724
{
725725
byte myValue = pValue[i];
726726
pValue[i] = (byte)(((myValue >> 1) & ~MASK) | myMask);
727-
myMask = (byte)((myValue & 1) == 0 ? 0 : MASK);
727+
myMask = (byte)((myValue & 1) == 0 ? (byte)0 : MASK);
728728
}
729729

730730
/* Xor in addition if last bit was set */

crypto/test/src/crypto/test/SP80038GTest.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -274,6 +274,9 @@ private void testFF3_1w()
274274

275275
private void testDisable()
276276
{
277+
#if NETCF_1_0 || NETCF_2_0 || SILVERLIGHT || (PORTABLE && !DOTNET) || NET_1_1
278+
// Can't SetEnvironmentVariable !
279+
#else
277280
Environment.SetEnvironmentVariable("org.bouncycastle.fpe.disable", "true");
278281
try
279282
{
@@ -309,6 +312,7 @@ private void testDisable()
309312

310313
testFF3_1();
311314
Environment.SetEnvironmentVariable("org.bouncycastle.fpe.disable_ff1", "false");
315+
#endif
312316
}
313317

314318
private void testFF3_1_255()

0 commit comments

Comments
 (0)