blob: 17f3af8f1c66fed0f79a3fccebff58ef86589206 [file] [log] [blame]
# Copyright 2018 The Fuchsia 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("//build/components.gni")
import("//build/config.gni")
import("//build/rust/rustc_binary.gni")
group("tests") {
testonly = true
deps = [ ":kms_tests" ]
}
rustc_binary("bin") {
name = "kms"
edition = "2021"
with_unit_tests = true
deps = [
"//sdk/fidl/fuchsia.kms:fuchsia.kms_rust",
"//sdk/fidl/fuchsia.mem:fuchsia.mem_rust",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia",
"//src/lib/fuchsia-async",
"//src/lib/fuchsia-component",
"//src/lib/mundane:mundane",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/security/lib/tee/rust",
"//third_party/boringssl/rust/boringssl-sys:bssl-sys",
"//third_party/rust_crates:aes-gcm",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:base64",
"//third_party/rust_crates:bincode",
"//third_party/rust_crates:byteorder",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:serde",
"//third_party/rust_crates:serde_json",
"//third_party/rust_crates:tracing",
]
test_deps = [
"//third_party/rust_crates:rand",
"//third_party/rust_crates:tempfile",
]
non_rust_deps = [ "//src/security/lib/tee/tee-client-api" ]
sources = [
"src/common.rs",
"src/crypto_provider/mock_provider.rs",
"src/crypto_provider/mod.rs",
"src/crypto_provider/mundane_provider.rs",
"src/crypto_provider/optee_provider/boringssl_wrapper.rs",
"src/crypto_provider/optee_provider/keysafe.rs",
"src/crypto_provider/optee_provider/mod.rs",
"src/crypto_provider/software_provider.rs",
"src/key_manager.rs",
"src/kms_asymmetric_key.rs",
"src/kms_sealing_key.rs",
"src/main.rs",
]
}
fuchsia_unittest_package("kms_tests") {
manifest = "meta/kms_bin_test.cml"
deps = [ ":bin_test" ]
}