Make TripleDESCryptoServiceProvider CreateTransform behave like netfx
authorJeremy Barton <jbarton@microsoft.com>
Thu, 29 Mar 2018 22:54:53 +0000 (15:54 -0700)
committerJosh Free <joshfree@users.noreply.github.com>
Fri, 30 Mar 2018 21:09:15 +0000 (14:09 -0700)
commit5bd1633543d3194c165668f35b600cd593c61e1c
treea843b49b48fd22df5440f14b8bfb60593f00f6e1
parentf6d22cd0f21c69595e2f8232aded78b95a382ee2
Make TripleDESCryptoServiceProvider CreateTransform behave like netfx

.NET Framework's TripleDESCryptoServiceProvider rejects small inputs, but
accepts oversized IVs (effectively truncating them to the block size).  This
change makes the .NET Core type behave the same way, and adds a test to
codify all of the oversized IV relationships with the CryptoServiceProvider
compat types.  (DES and RC2 apparently already allowed it)

Commit migrated from https://github.com/dotnet/corefx/commit/78357cf19232383d8e6b5356b760bf4c2f0e2f09
src/libraries/System.Security.Cryptography.Csp/src/System/Security/Cryptography/TripleDESCryptoServiceProvider.cs
src/libraries/System.Security.Cryptography.Csp/tests/CreateTransformCompat.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Csp/tests/System.Security.Cryptography.Csp.Tests.csproj