Commit 1a2a7c36 authored by Jose Blaya's avatar Jose Blaya
Browse files

Merge branch '161-remove-not-ready-ikev2-algorithms' into 'release/2.2.0'

Resolve "Remove not ready IKEv2 algorithms"

See merge request ios/client-library-apple!218
parents 8a6c5de0 12557890
......@@ -13,24 +13,24 @@ public enum IKEv2EncryptionAlgorithm: Int, EnumsBuilder {
public static let defaultAlgorithm: Int = 2
case algorithmDES = 1
case algorithm3DES
//case algorithmDES = 1
case algorithm3DES = 2
case algorithmAES128
case algorithmAES256
case algorithmAES128GCM
case algorithmAES256GCM
@available(iOS 13.0, *)
case algorithmChaCha20Poly1305
//case algorithmAES128GCM
//case algorithmAES256GCM
//@available(iOS 13.0, *)
//case algorithmChaCha20Poly1305
public func description() -> String {
switch self {
case .algorithmDES: return "Data Encryption Standard (DES)"
// case .algorithmDES: return "Data Encryption Standard (DES)"
case .algorithm3DES: return "Triple Data Encryption Algorithm (aka 3DES)"
case .algorithmAES128: return "Advanced Encryption Standard 128 bit (AES128)"
case .algorithmAES256: return "Advanced Encryption Standard 256 bit (AES256)"
case .algorithmAES128GCM: return "Advanced Encryption Standard 128 bit (AES128GCM)"
case .algorithmAES256GCM: return "Advanced Encryption Standard 256 bit (AES256GCM)"
case .algorithmChaCha20Poly1305 : return "CHACHA20-POLY1305"
// case .algorithmAES128GCM: return "Advanced Encryption Standard 128 bit (AES128GCM)"
// case .algorithmAES256GCM: return "Advanced Encryption Standard 256 bit (AES256GCM)"
// case .algorithmChaCha20Poly1305 : return "CHACHA20-POLY1305"
}
}
......@@ -38,5 +38,11 @@ public enum IKEv2EncryptionAlgorithm: Int, EnumsBuilder {
return NEVPNIKEv2EncryptionAlgorithm(rawValue: self.rawValue) ?? .algorithm3DES
}
public static func allValues() -> [IKEv2EncryptionAlgorithm] {
return [.algorithm3DES,
.algorithmAES128,
.algorithmAES256
]
}
}
......@@ -14,18 +14,18 @@ public enum IKEv2IntegrityAlgorithm: Int, EnumsBuilder {
public static let defaultAlgorithm: Int = 1
case SHA96 = 1
case SHA160
case SHA256
case SHA384
case SHA512
//case SHA160
//case SHA256
//case SHA384
//case SHA512
public func description() -> String {
switch self {
case .SHA96: return "SHA96"
case .SHA160: return "SHA160"
case .SHA256: return "SHA256"
case .SHA384: return "SHA384"
case .SHA512: return "SHA512"
//case .SHA160: return "SHA160"
//case .SHA256: return "SHA256"
//case .SHA384: return "SHA384"
//case .SHA512: return "SHA512"
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment