SecurityProtocol
internal protocol SecurityProtocol : CaseIterable
The SecurityProtocol
protocol defines a set of requirements for security protocol implementations.
Implementations of this protocol must provide an ObjectIdentifier
(oid
) value that represents
the identifier of the security protocol.
-
Declaration
Swift
var oid: ObjectIdentifier { get }
-
from(oid:
Default implementation) Returns an instance of the
SecurityProtocol
based on the providedObjectIdentifier
, if there is a match between theObjectIdentifier
and a protocol.Default Implementation
Declaration
Swift
static func from(oid: ObjectIdentifier) -> Self?
Parameters
oid
The security protocol OID.
Return Value
An instance of a security protocol.
-
isValid(oid:
Default implementation) Checks if a given
ObjectIdentifier
corresponds to a validSecurityProtocol
.Default Implementation
Declaration
Swift
static func isValid(oid: ObjectIdentifier) -> Bool
Parameters
oid
The security protocol OID that has to be checked.
Return Value
true
if the givenObjectIdentifier
is valid;false
otherwise.