blob: 50e2680096206d763b5105981d7e40464553a508 [file] [log] [blame]
// Copyright 2019 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// These interfaces support a trial comparing two different implementations of
// certificate verification, where the certificate verification may occur in
// one process and the configuration and reporting in another. They will be
// removed when the trial is completed.
// See https://crbug.com/649026
module network.mojom;
import "mojo/public/mojom/base/time.mojom";
import "services/network/public/mojom/network_param.mojom";
// Receives cert verifier trial configuration updates.
interface TrialComparisonCertVerifierConfigClient {
OnTrialConfigUpdated(bool allowed);
};
// Contains additional debugging data about the verification. This information
// does not change the meaning of the results.
struct CertVerifierDebugInfo {
// A bitfield of net::TrustStoreMac::TrustDebugInfo flags, containing the
// union of flags from all the GetTrust calls done during verification.
[EnableIf=is_mac]
int32 mac_combined_trust_debug_info;
// The time as seen by CertVerifyProcBuiltin, in raw timestamp and in
// exploded & encoded GeneralizedTime string.
mojo_base.mojom.Time trial_verification_time;
string trial_der_verification_time;
};
// Sends reports of differences found in the cert verifier trial.
interface TrialComparisonCertVerifierReportClient {
SendTrialReport(
string hostname, X509Certificate cert, bool enable_rev_checking,
bool require_rev_checking_local_anchors, bool enable_sha1_local_anchors,
bool disable_symantec_enforcement, CertVerifyResult primary_result,
CertVerifyResult trial_result, CertVerifierDebugInfo debug_info);
};
// Parameters for initializing the cert verification trial.
// |initial_allowed| is the initial setting for whether the trial is allowed.
// |config_client_request| is the Mojo pipe over which trial configuration
// updates are received.
// |report_client| is the Mojo pipe used to send trial reports.
struct TrialComparisonCertVerifierParams {
bool initial_allowed = false;
TrialComparisonCertVerifierConfigClient&? config_client_request;
TrialComparisonCertVerifierReportClient? report_client;
};