Refine encryption(#655)
* Refine encryption - Add AES-CTR, blowfish and camellia ciphers aes-256-ctr aes-192-ctr aes-128-ctr bf-cfb camellia-128-cfb camellia-192-cfb camellia-256-cfb - Merge the previous PolarSSL and MbedTLS - Switch to MbedTLS's cipher layer functions - Add workaround to set cipher operation(encrypt/decrypt) Signed-off-by: Syrone Wong <wong.syrone@gmail.com> * Add function to get MbedTLS cipher context size and drop hard-coded ctx sizes Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
This commit is contained in:
@@ -13,9 +13,9 @@ namespace Shadowsocks.Encryption
|
||||
static EncryptorFactory()
|
||||
{
|
||||
_registeredEncryptors = new Dictionary<string, Type>();
|
||||
foreach (string method in PolarSSLEncryptor.SupportedCiphers())
|
||||
foreach (string method in MbedTLSEncryptor.SupportedCiphers())
|
||||
{
|
||||
_registeredEncryptors.Add(method, typeof(PolarSSLEncryptor));
|
||||
_registeredEncryptors.Add(method, typeof(MbedTLSEncryptor));
|
||||
}
|
||||
foreach (string method in SodiumEncryptor.SupportedCiphers())
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user