mirror of
https://github.com/apple/swift-nio-ssl
synced 2026-11-30 05:28:46 +00:00
Motivation: When server users turn on certificate verification, they usually expect that they'll actually require the certificate from their peer. Sadly, this is not the BoringSSL default behaviour. Modifications: Set `SSL_VERIFY_FAIL_IF_NO_PEER_CERT` when requesting certificate validation. Result: Better certificate validation.
43 lines
1.8 KiB
Swift
43 lines
1.8 KiB
Swift
//===----------------------------------------------------------------------===//
|
|
//
|
|
// This source file is part of the SwiftNIO open source project
|
|
//
|
|
// Copyright (c) 2017-2018 Apple Inc. and the SwiftNIO project authors
|
|
// Licensed under Apache License v2.0
|
|
//
|
|
// See LICENSE.txt for license information
|
|
// See CONTRIBUTORS.txt for the list of SwiftNIO project authors
|
|
//
|
|
// SPDX-License-Identifier: Apache-2.0
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
//
|
|
// TLSConfigurationTest+XCTest.swift
|
|
//
|
|
import XCTest
|
|
|
|
///
|
|
/// NOTE: This file was generated by generate_linux_tests.rb
|
|
///
|
|
/// Do NOT edit this file directly as it will be regenerated automatically when needed.
|
|
///
|
|
|
|
extension TLSConfigurationTest {
|
|
|
|
static var allTests : [(String, (TLSConfigurationTest) -> () throws -> Void)] {
|
|
return [
|
|
("testNonOverlappingTLSVersions", testNonOverlappingTLSVersions),
|
|
("testNonOverlappingCipherSuitesPreTLS13", testNonOverlappingCipherSuitesPreTLS13),
|
|
("testCannotVerifySelfSigned", testCannotVerifySelfSigned),
|
|
("testServerCannotValidateClientPreTLS13", testServerCannotValidateClientPreTLS13),
|
|
("testServerCannotValidateClientPostTLS13", testServerCannotValidateClientPostTLS13),
|
|
("testMutualValidation", testMutualValidation),
|
|
("testMutualValidationRequiresClientCertificatePreTLS13", testMutualValidationRequiresClientCertificatePreTLS13),
|
|
("testMutualValidationRequiresClientCertificatePostTLS13", testMutualValidationRequiresClientCertificatePostTLS13),
|
|
("testNonexistentFileObject", testNonexistentFileObject),
|
|
("testComputedApplicationProtocols", testComputedApplicationProtocols),
|
|
]
|
|
}
|
|
}
|
|
|