# Copyright 2018 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. import("//services/service_manager/public/service_manifest.gni") assert(is_chromeos, "Non-ChromeOS builds cannot depend on //chromeos") static_library("secure_channel") { sources = [ "active_connection_manager.cc", "active_connection_manager.h", "active_connection_manager_impl.cc", "active_connection_manager_impl.h", "authenticated_channel.cc", "authenticated_channel.h", "authenticated_channel_impl.cc", "authenticated_channel_impl.h", "ble_advertiser.cc", "ble_advertiser.h", "ble_advertiser_impl.cc", "ble_advertiser_impl.h", "ble_connection_manager.cc", "ble_connection_manager.h", "ble_connection_manager_impl.cc", "ble_connection_manager_impl.h", "ble_constants.h", "ble_initiator_connection_attempt.cc", "ble_initiator_connection_attempt.h", "ble_initiator_failure_type.cc", "ble_initiator_failure_type.h", "ble_initiator_operation.cc", "ble_initiator_operation.h", "ble_listener_connection_attempt.cc", "ble_listener_connection_attempt.h", "ble_listener_failure_type.cc", "ble_listener_failure_type.h", "ble_listener_operation.cc", "ble_listener_operation.h", "ble_scanner.cc", "ble_scanner.h", "ble_scanner_impl.cc", "ble_scanner_impl.h", "ble_service_data_helper.cc", "ble_service_data_helper.h", "ble_service_data_helper_impl.cc", "ble_service_data_helper_impl.h", "ble_synchronizer.cc", "ble_synchronizer.h", "ble_synchronizer_base.cc", "ble_synchronizer_base.h", "channel_impl.cc", "channel_impl.h", "client_connection_parameters.cc", "client_connection_parameters.h", "client_connection_parameters_impl.cc", "client_connection_parameters_impl.h", "connect_to_device_operation.h", "connect_to_device_operation_base.h", "connection_attempt.h", "connection_attempt_base.h", "connection_attempt_delegate.h", "connection_attempt_details.cc", "connection_attempt_details.h", "connection_details.cc", "connection_details.h", "connection_medium.cc", "connection_medium.h", "connection_role.cc", "connection_role.h", "device_id_pair.cc", "device_id_pair.h", "error_tolerant_ble_advertisement.cc", "error_tolerant_ble_advertisement.h", "error_tolerant_ble_advertisement_impl.cc", "error_tolerant_ble_advertisement_impl.h", "multiplexed_channel.cc", "multiplexed_channel.h", "multiplexed_channel_impl.cc", "multiplexed_channel_impl.h", "pending_ble_initiator_connection_request.cc", "pending_ble_initiator_connection_request.h", "pending_ble_listener_connection_request.cc", "pending_ble_listener_connection_request.h", "pending_connection_manager.cc", "pending_connection_manager.h", "pending_connection_manager_impl.cc", "pending_connection_manager_impl.h", "pending_connection_request.h", "pending_connection_request_base.h", "pending_connection_request_delegate.cc", "pending_connection_request_delegate.h", "secure_channel_base.cc", "secure_channel_base.h", "secure_channel_disconnector.h", "secure_channel_disconnector_impl.cc", "secure_channel_disconnector_impl.h", "secure_channel_impl.cc", "secure_channel_impl.h", "secure_channel_initializer.cc", "secure_channel_initializer.h", "secure_channel_service.cc", "secure_channel_service.h", "shared_resource_scheduler.cc", "shared_resource_scheduler.h", "single_client_message_proxy.cc", "single_client_message_proxy.h", "single_client_message_proxy_impl.cc", "single_client_message_proxy_impl.h", "timer_factory.h", "timer_factory_impl.cc", "timer_factory_impl.h", ] deps = [ "//base", "//chromeos", "//chromeos/components/proximity_auth/logging", "//chromeos/services/secure_channel/public/cpp/shared", "//chromeos/services/secure_channel/public/mojom", "//components/cryptauth", "//components/cryptauth/ble", "//device/bluetooth", "//services/service_manager/public/cpp", ] } service_manifest("manifest") { name = "secure_channel" source = "manifest.json" } static_library("test_support") { testonly = true sources = [ "fake_active_connection_manager.cc", "fake_active_connection_manager.h", "fake_authenticated_channel.cc", "fake_authenticated_channel.h", "fake_ble_advertiser.cc", "fake_ble_advertiser.h", "fake_ble_connection_manager.cc", "fake_ble_connection_manager.h", "fake_ble_scanner.cc", "fake_ble_scanner.h", "fake_ble_service_data_helper.cc", "fake_ble_service_data_helper.h", "fake_ble_synchronizer.cc", "fake_ble_synchronizer.h", "fake_channel.cc", "fake_channel.h", "fake_client_connection_parameters.cc", "fake_client_connection_parameters.h", "fake_connect_to_device_operation.h", "fake_connection_attempt.h", "fake_connection_attempt_delegate.cc", "fake_connection_attempt_delegate.h", "fake_connection_delegate.cc", "fake_connection_delegate.h", "fake_error_tolerant_ble_advertisement.cc", "fake_error_tolerant_ble_advertisement.h", "fake_message_receiver.cc", "fake_message_receiver.h", "fake_multiplexed_channel.cc", "fake_multiplexed_channel.h", "fake_one_shot_timer.cc", "fake_one_shot_timer.h", "fake_pending_connection_manager.cc", "fake_pending_connection_manager.h", "fake_pending_connection_request.h", "fake_pending_connection_request_delegate.cc", "fake_pending_connection_request_delegate.h", "fake_secure_channel.cc", "fake_secure_channel.h", "fake_secure_channel_disconnector.cc", "fake_secure_channel_disconnector.h", "fake_single_client_message_proxy.cc", "fake_single_client_message_proxy.h", "fake_timer_factory.cc", "fake_timer_factory.h", ] deps = [ ":secure_channel", "//base", "//base/test:test_support", "//chromeos/services/secure_channel/public/cpp/shared", "//chromeos/services/secure_channel/public/mojom", "//components/cryptauth:cryptauth", "//device/bluetooth:bluetooth", ] } source_set("unit_tests") { testonly = true sources = [ "active_connection_manager_impl_unittest.cc", "authenticated_channel_impl_unittest.cc", "ble_advertiser_impl_unittest.cc", "ble_connection_manager_impl_unittest.cc", "ble_initiator_operation_unittest.cc", "ble_listener_operation_unittest.cc", "ble_scanner_impl_unittest.cc", "ble_service_data_helper_impl_unittest.cc", "ble_synchronizer_unittest.cc", "client_connection_parameters_impl_unittest.cc", "connect_to_device_operation_base_unittest.cc", "connection_attempt_base_unittest.cc", "error_tolerant_ble_advertisement_impl_unittest.cc", "multiplexed_channel_impl_unittest.cc", "pending_ble_initiator_connection_request_unittest.cc", "pending_ble_listener_connection_request_unittest.cc", "pending_connection_manager_impl_unittest.cc", "pending_connection_request_base_unittest.cc", "secure_channel_disconnector_impl_unittest.cc", "secure_channel_service_unittest.cc", "shared_resource_scheduler_unittest.cc", "single_client_message_proxy_impl_unittest.cc", ] deps = [ ":secure_channel", ":test_support", "//base/test:test_support", "//chromeos/services/secure_channel/public/cpp/client:unit_tests", "//chromeos/services/secure_channel/public/cpp/shared", "//chromeos/services/secure_channel/public/mojom", "//chromeos/services/secure_channel/public/mojom:unit_tests", "//components/cryptauth:test_support", "//components/cryptauth/ble", "//components/cryptauth/ble:test_support", "//device/bluetooth:mocks", "//services/service_manager/public/cpp/test:test_support", "//testing/gmock", "//testing/gtest", ] }