AllOfPolicies

Use this to build a policy where all of the sub-policies must be met for the overall policy to be met. This is only useful within a OneOfPolicies block, because at the top-level, it is already required for all policies to be met, so adding this at the top-level is redundant. For example, the following policy requires that RFC5280Policy is always met, and then either policy C is met, or A and B are both met. If A and B are both met, then C does not have to be met. If C is met, then neither A nor B need to be met.

AllOfPolicies.swift:36
iOS
13+
macOS
10.15+
tvOS
13+
watchOS
6+
struct AllOfPolicies<Policy> where Policy : VerifierPolicy
let verifier = Verifier(rootCertificates: CertificateStore()) {
    RFC5280Policy(validationTime: Date())
    OneOfPolicies {
        AllOfPolicies {
            PolicyA()
            PolicyB()
        }
        PolicyC()
    }
}