2009-09-22 Sebastien Pouliot <[email protected]>
* CryptoStreamTest.cs: Add (nunit-ized) test cases provided by
Santa Marta (via Atsushi) as repro for bugs #539288 and #539229
In System.Security.Cryptography:
2009-09-22 Sebastien Pouliot <[email protected]>
* CryptoStream.cs: Fix [Input|Output]BlockSize for custom streams.
Patches by Santa Marta (via Atsushi).
[Fix bug #539288 and #539229]
svn path=/trunk/mcs/; revision=142435
* RSAPKCS1KeyExchangeFormatterTest.cs: Add test case where you are
passing null parameters to SetKey method and constructor with
the key as parameter. Fixes the bug #408738.
svn path=/trunk/mcs/; revision=107829
* Rfc2898DeriveBytesTest.cs: Add test cases for consecutive calls to
GetBytes and compare the result to a single, larger, call. Converted
all exitsing tests to NUnit 2.2.
svn path=/trunk/mcs/; revision=96343
* RC2CryptoServiceProviderTest.cs: Fix Create[De|En]cryptor_KeyNull
test case not to fail about 1 out of 256 times under the 2.0 profile.
* TripleDESCryptoServiceProviderTest.cs: Fix Create[De|En]cryptor_KeyNull
test case not to fail about 1 out of 256 times under the 2.0 profile.
svn path=/trunk/mcs/; revision=92119
* DESCryptoServiceProviderTest.cs: Fix CreateDecryptor_KeyNull test
case not to fail about 1 out of 256 times under the 2.0 profile.
svn path=/trunk/mcs/; revision=90058
* DESCryptoServiceProviderTest.cs: Fix CreateEncryptor_KeyNull test
case not to fail about 1 out of 256 times under the 2.0 profile.
svn path=/trunk/mcs/; revision=88016
* DSATest.cs: Add test case where we import a key that has a null Y
(public part) but where X (private part) is available - and usable
to compute Y.
svn path=/trunk/mcs/; revision=76951
* PasswordDeriveBytesTest.cs: Fix test case that used Reset (as the
method was fixed to reset the state in fx 2.0).
svn path=/trunk/mcs/; revision=74830
* SymmetricAlgorithmTransformTest.cs: Change/split test cases so that
they work properly under both MS 1.1 and 2.0. In some cases tests are
marked as NotWorking because Mono implements the, more consistent, 2.0
behavior for all transforms.
svn path=/trunk/mcs/; revision=74827
* SymmetricAlgorithmTransformTest.cs: Add test cases for #81008 by
looking at the encrypted/decrypted block length when TransformBlock is
called with different MoO and paddings.
svn path=/trunk/mcs/; revision=73713
* DESCryptoServiceProviderTest.cs: Remove test cases for bug #80439
as they are more general than DES and the default padding.
* SymmetricAlgorithmTransformTest.cs: New. Extensive test cases for
bug #80439, all symmtric ciphers (all block size), all mode of
operations and all supported padding modes.
svn path=/trunk/mcs/; revision=70688
* DESCryptoServiceProviderTest.cs: Add tests for bug #80439 where
inputCount is reduced to fit into the output buffer (for any mode).
svn path=/trunk/mcs/; revision=70428
* CryptoConfigTest.cs: Added test cases to ensure lower/mixed-case of
algorithm names are supported by CreateFromName and MapNameToOID (fix
bug #79641). Updated some OID that were changed (well nulled) in the
final 2.0 release of MS framework.
svn path=/trunk/mcs/; revision=66548
* RSACryptoServiceProviderTest.cs: Added test cases for decoding bad
PKCS1 and OAEP padding - both resulting in a CryptographicException.
* RSAOAEPKeyExchangeDeformatterTest.cs: Add test case for bad padding.
* RSAPKCS1KeyExchangeDeformatterTest.cs: Add test case for bad padding
svn path=/trunk/mcs/; revision=65100
* RSACryptoServiceProviderTest.cs: Test case for #79269 where we
ensure a CryptographicException (not a NRE) when decrypting without a
private key.
svn path=/trunk/mcs/; revision=64940
* RSAPKCS1SignatureDeformatterTest.cs: Added test case where
SetHashAlgorithm isn't called and the hash algorithm name is derived
from the hash instance. From bug #78744 by Diego Mesa Tabares.
svn path=/trunk/mcs/; revision=62171
* HashAlgorithmTest.cs: Added new test cases wrt the output buffer
used in TransformBlock (e.g. bug #78647). Updated existing test case
to work under 2.0 final.
* HMACMD5Test.cs: Fix SetUp to allow new inherited test cases to work
properly.
* HMACRIPEMD160Test.cs: Fix SetUp to allow new inherited test cases to
work properly.
* HMACSHA1Test.cs: Fix SetUp to allow new inherited test cases to
work properly.
* HMACSHA256Test.cs: Fix SetUp to allow new inherited test cases to
work properly.
* HMACSHA384Test.cs: New. Basic test cases that, cheaply, inherits
the HashAlgorithm tests.
* HMACSHA512Test.cs: New. Basic test cases that, cheaply, inherits
the HashAlgorithm tests.
* KeyedHashAlgorithmTest.cs: Ensure we're always using the same key
(required for new, inherited, test cases). Fix ToString to match
KeyedHashAlgorithm (and not an inherited class).
svn path=/trunk/mcs/; revision=61769
* RandomNumberGeneratorTest.cs: Don't forget the last run in Runs.
Track both 0 and 1 runs. Changed runs ranges to match FIPS140-2 Change
Notice #1 (fixes bug #78560). Updated test cases to NUnit 2.2 format.
svn path=/trunk/mcs/; revision=61375
* RijndaelTest.cs: Add test cases for cycling key sizes and block
sizes.
* SymmetricAlgorithm2Test.cs: Added test case for re-setting the
BlockSize. Keeping the same value *doesn't* change the current IV
(while doing the same on the KeySize *does* change the key).
svn path=/trunk/mcs/; revision=54450
* DSATest.cs: Added test case where J isn't imported. In this case we
don't export (our internally calculated) J and it's also not part of
the XML output.
svn path=/trunk/mcs/; revision=53357
* RC2CryptoServiceProviderTest.cs: New. Unit tests specific to this
implementation (not algorithm specific but required to match MS
behaviour).
* RijndaelManagedTest.cs: Added unit tests specific to this
implementation (not algorithm specific but required to match MS
behaviour).
* DESCryptoServiceProviderTest.cs: Added unit tests specific to this
implementation (not algorithm specific but required to match MS
behaviour).
* TripleDESCryptoServiceProviderTest.cs: New. Unit tests specific to
this implementation (not algorithm specific but required to match MS
behaviour).
svn path=/trunk/mcs/; revision=52044
* DSACryptoServiceProviderTest.cs: Catch UnauthorizedAccessException
directly in UseMachineKeyStore (not just wrapped inside a
CryptographicException).
* RSACryptoServiceProviderTest.cs: Catch UnauthorizedAccessException
directly in UseMachineKeyStore (not just wrapped inside a
CryptographicException).
svn path=/trunk/mcs/; revision=43675
* CryptoConfigTest.cs: Check that ArgumentNullException is throw in
EncodeOID for 2.0. Comment test for RSA OID (2.0).
* DESTest.cs: Check that null keys throws CryptographicException in
IsWeakKey and IsSemiWeakKey for 2.0.
* TripleDESTest.cs: Check that null keys throws CryptographicException
in IsWeakKey for 2.0.
* SymmetricAlgorithm2Test.cs: Check that a FeedbackSize of zero throws
a CryptographicException in 2.0.
svn path=/trunk/mcs/; revision=43555
* CryptoConfigCas.cs: New. CAS unit tests for CryptoConfig.
* CryptoAPITransformCas.cs: New. CAS unit tests for CryptoAPITransform.
svn path=/trunk/mcs/; revision=42206
* DSATest.cs: Added unit test for Counter == 0. Actualized test cases
for NET_2_0 now that we can inherit from DSA outside corlib.
svn path=/trunk/mcs/; revision=40405
* DSACryptoServiceProviderTest.cs: Fixed VerifySignatureWithoutKey to
ensure that Mono didn't create the key before starting verification.
* RSACryptoServiceProviderTest.cs: Added tests for PublicOnly in the
constructor tests and for VerifyHash with a null OID.
* RSAPKCS1SignatureFormatterTest.cs: Fixed signatures values for
SHA256, SHA384 and SHA512 for NET_2_0 profile. The older signatures
(working only in Mono) can't be used because 2.0 use new OID for those
hash algorithms. Note that this still only works with Mono in 2.0!
svn path=/trunk/mcs/; revision=38721
* CryptoConfigTest.cs: Added new RIPEMD160 hash algorithm and new HMAC
algorithms (HMACMD5, HMACRIPEMD160, HMACSHA256, HMACSHA384 and
HMACSHA512) to the tests.
svn path=/trunk/mcs/; revision=38684