Commit Graph
18 Commits
Author SHA1 Message Date
Rodrigo Kumpera bbb7592661 Make the Crypto stack work with Full AOT.
* System.Security.Cryptography.*cs: To make Crypto work with
	Full AOT we remove the usage of providers and reflection. We hardcode
	the default algorithms for hashing, rng and symmetric cyphers.
2012-11-06 18:18:16 -05:00
Miguel de Icaza 3c39ac4586 Jumbo patch for NET_2_0, mscorlib is now clean
svn path=/trunk/mcs/; revision=145621
2009-11-06 22:23:59 +00:00
Andreas N ca4b3b3ea2 2008-07-03 Andreas Nahr <[email protected]>
* SHA512Managed.cs:
	* SHA384Managed.cs:
	* SHA256Managed.cs:
	* SHA1Managed.cs:
	* SHA1CryptoServiceProvider.cs:
	* RSAPKCS1KeyExchangeDeformatter.cs:
	* RSACryptoServiceProvider.cs:
	* RSA.cs:
	* RIPEMD160Managed.cs:
	* RC2.cs:
	* PKCS1MaskGenerationMethod.cs:
	* MD5CryptoServiceProvider.cs:
	* MD5.cs:
	* MACTripleDES.cs:
	* HMACSHA512.cs:
	* HMACSHA384.cs:
	* HMACSHA256.cs:
	* HMACSHA1.cs:
	* HMACRIPEMD160.cs:
	* HMACMD5.cs:
	* HMAC.cs:
	* HashAlgorithm.cs:
	* FromBase64Transform.cs:
	* DSACryptoServiceProvider.cs:
	* DES.cs:
	* CspParameters.cs: Fix parameter names

svn path=/trunk/mcs/; revision=107126
2008-07-02 23:56:08 +00:00
Sebastien Pouliot 2e04d92d70 2008-04-17 Sebastien Pouliot <[email protected]>
* AsymmetricAlgorithm.cs: Add shared GetNamedParam helper method.
	* DSA.cs, RSA.cs: Rework FromXmlString to be more "careless" like
	MS implementation. Fix #355464


svn path=/trunk/mcs/; revision=101003
2008-04-17 14:56:26 +00:00
Sebastien Pouliot 129324b2ca 2006-05-30 Sebastien Pouliot <[email protected]>
* AsymmetricKeyExchangeDeformatter.cs: Under 2.0 the ctor is 
	protected.
	* AsymmetricKeyExchangeFormatter.cs: Under 2.0 the ctor is protected.
	* AsymmetricSignatureDeformatter.cs: Under 2.0 the ctor is protected.
	* AsymmetricSignatureFormatter.cs: Under 2.0 the ctor is protected.
	* DES.cs: Under 2.0 the ctor is protected.
	* HashAlgorithm.cs: Under 2.0 the HashValue field is protected 
	internal.
	* RandomNumberGenerator.cs: Under 2.0 the ctor is protected.
	* RC2.cs: Under 2.0 the ctor is protected.
	* Rijndael.cs: Under 2.0 the ctor is protected.
	* RSA.cs: Under 2.0 the ctor is protected.
	* SHA256.cs: Under 2.0 the ctor is protected.
	* SHA384.cs: Under 2.0 the ctor is protected.
	* SHA512.cs: Under 2.0 the ctor is protected.
	* SymmetricAlgorithm.cs: Under 2.0 the ctor is protected.
	* TripleDES.cs: Under 2.0 the ctor is protected.


svn path=/trunk/mcs/; revision=61270
2006-05-30 17:57:47 +00:00
Sebastien Pouliot ccfef2f152 2005-06-10 Sebastien Pouliot <[email protected]>
* all: 2.0 beta2 fixes, i.e. mostly added [ComVisible(true)]


svn path=/trunk/mcs/; revision=45759
2005-06-10 14:42:08 +00:00
Sebastien Pouliot e4350d94da 2004-12-22 Sebastien Pouliot <[email protected]>
* RSA.cs: Throw the proper CryptographicException exception when 
	exporting a private key without CRT parameters, while keeping the
	ArgumentNullException when the private exponent (D) is missing.


svn path=/trunk/mcs/; revision=38052
2004-12-22 19:34:45 +00:00
Duncan Mak 13d1764537 Add license and copyright to all source files in corlib
svn path=/trunk/mcs/; revision=29249
2004-06-11 02:09:36 +00:00
Sebastien Pouliot e7cc9f30bc 2004-05-06 Sebastien Pouliot <[email protected]>
* RNGCryptoServiceProvider.cs: Removed TODO and documented them in
	mono doc. Now call runtime when a seed is provided.
	* RSA.cs: Added globalization to exceptions. Removed check for
	<RSAKeyValue> as it is not checked by MS implementation.
	* SignatureDescription.cs: Moved XML comments to monodoc. Added
	globalization to exceptions. Removed TODO and added notes to monodoc.
	* SymmetricAlgorithm.cs: Moved XML comments to monodoc. Added
	globalization to exceptions.
	* ToBase64Tranform.cs: Added missing exception handling. Moved XML
	comments to monodoc.

svn path=/trunk/mcs/; revision=26848
2004-05-06 16:31:52 +00:00
Sebastien Pouliot 0add9abe32 2003-07-05 Sebastien Pouliot <[email protected]>
* AsymmetricAlgorithm.cs: Removed AsymmetricParameters (IReader) class.
	Now uses the new Mono.Xml.SecurityParser (xml -> SecurityElement)
	* CryptoConfig.cs: Removed CorlibHandler and CorlibReader classes. Now
	uses the new Mono.Xml.SecurityParser (xml -> SecurityElement)
	* DSA.cs: Removed DSAHandler (IHandler) class. Now uses the new
	Mono.Xml.SecurityParser (xml -> SecurityElement)
	* DSACryptoServiceProvider.cs: Added ObjectDisposedException support
	and fixed bugs found in new unit tests.
	* RSA.cs: Removed DSAHandler (IHandler) class. Now uses the new
	Mono.Xml.SecurityParser (xml -> SecurityElement)
	* RSACryptoServiceProvider.cs: Added ObjectDisposedException support
	and fixed bugs found in new unit tests.

svn path=/trunk/mcs/; revision=15971
2003-07-06 02:48:57 +00:00
Sebastien Pouliot 66e393eccc 2003-02-08 Sebastien Pouliot <[email protected]>
* Changes to refer Mono.Xml

svn path=/trunk/mcs/; revision=11353
2003-02-08 16:31:12 +00:00
Sebastien Pouliot 8f7ce12d41 2002-12-31 Sebastien Pouliot <[email protected]>
* AsymmetricAlgorithm.cs: Removed ValidKeySize (method only present
	in SymmetricAlgorithm).
	* DSA.cs: Change ZeroizePrivateKey from protected to internal.
	* DSACryptoServiceProvider.cs: Added some case where we need to check
	for keypairGenerated.
	* RSA.cs: Change ZeroizePrivateKey from protected to internal.
	* RSACryptoServiceProvider.cs: Key were never generated with the default
	(no parameter) constructor. Now checks for keypairGenerated in methods.
	* SignatureDescription.cs: Added CreateDeformatter in RSAPKCS1SHA1-
	SignatureDescription to please corcompare (it just call it's ancestor).

svn path=/trunk/mcs/; revision=10019
2002-12-31 17:33:06 +00:00
Sebastien Pouliot a207a19f3b 2002-11-17 Sebastien Pouliot <[email protected]>
* CryptoConfig.cs: Added full classes name for MapNameToOID.
	* PKCS1.cs: New. Internal class for the various primitives defined
	in PKCS#1 v.2.1.
	* PKCS1MaskGenerationFunction.cs: Modified to use PKCS1.cs.
	* RSA.cs: Added internal class RSAHandler (which implements IHandler
	interface for MiniParser) to import RSA keypairs from XML strings.
	* RSACryptoServiceProvider.cs: Crypto implemented using BigInteger.
	Key generation is VERY LONG.
	* RSAOAEPKeyExchangeDeformatter.cs: Completed using PKCS1. Not sure
	of the results as this is not available in all versions of Windows.
	* RSAOAEPKeyExchangeFormatter.cs: Completed using PKCS1. Not sure
	of the results as this is not available in all versions of Windows.
	* RSAPKCS1KeyExchangeDeformatter.cs: Completed using PKCS1.
	* RSAPKCS1KeyExchangeFormatter.cs: Completed using PKCS1.
	* RSAPKCS1SignatureDeformatter.cs: Completed using PKCS1.
	* RSAPKCS1SignatureFormatter.cs: Completed using PKCS1.

svn path=/trunk/mcs/; revision=9035
2002-11-17 21:49:53 +00:00
Sebastien Pouliot b443cb3648 2002-10-19 Sebastien Pouliot <[email protected]>
* SymmetricAlgorithm.cs: Added new class SymmetricTransform to avoid
	duplicating CipherMode (currently ECB, CBC) and PaddingMode functionalities
	in every crytographic algorithm implementation.
	* RijndaelManaged.cs: Added the RjindaelTransform class (inherited
	from SymmetricTransform) based the old RijndaelImpl / RijndaelController
	code. Fixed encryption for block size 192, 256, there is still a problem
	decrypting block size 192, 256. Unrolled some loops + littl'optimizations
	* PKCS1MaskGenerationMethod.cs: Removed Array.Reverse in I2OSP to be
	compatible with MS implementation (however we are now failing the PKCS#1
	test vector) + added some more checks (null, overflow, ...)
	* AsymmetricAlgorithm.cs: Commented XMLDocument stuff to end the cyclic
	dependency (corlib->System.Xml->corlib)
	* RSA.cs: Commented FromXmlString stuff to end the cyclic dependency
	* DSA.cs: Commented FromXmlString stuff to end the cyclic dependency
	* RC2.cs: Create using CryptoConfig
	* TripleDES.cs: Marked class public. Added LegalKeySizes and LegalBlockSizes

svn path=/trunk/mcs/; revision=8392
2002-10-19 15:32:57 +00:00
Sebastien Pouliot 22fa9bf079 2002-10-10 Sebastien Pouliot <[email protected]>
* AsymmetricAlgorithm.cs: Inherit from IDisposable, common support from XML import
	* DSA.cs: FromXmlString() keypair import, Create() using CryptoConfig
	* RSA.cs: FromXmlString() keypair import, Create() using CryptoConfig
	* DSACryptoServiceProvider.cs: Added Dispose()

svn path=/trunk/mcs/; revision=8159
2002-10-11 03:20:52 +00:00
Martin Baulig 5263b1b718 Reverted my latest workaround in these files. The corresponding bug in MCS
is now fixed.

svn path=/trunk/mcs/; revision=6000
2002-07-22 01:04:31 +00:00
Martin Baulig fb53523db8 2002-06-29 Martin Baulig <[email protected]>
* AsymmetricAlgorithm.cs: Removed a duplicate semicolon to make it compile.

	* *.cs (Create (string)): Don't call the non-args version of Create(),
	duplicate their contents here.  [FIXME: I was too lazy to hunt this bug down
	in mcs and it was the last one which prevented us from compiling corlib.]

svn path=/trunk/mcs/; revision=5498
2002-06-29 03:36:15 +00:00
Dan Lewis e0e9356649 Modified and added stubs to allow corlib to compile without referencing mscorlib
or MS assemblies. (check the corlib.dll assembly metadata :)

svn path=/trunk/mcs/; revision=2379
2002-02-13 16:24:18 +00:00