1# Copyright (c) 2023 Huawei Device Co., Ltd. 2# Licensed under the Apache License, Version 2.0 (the "License"); 3# you may not use this file except in compliance with the License. 4# You may obtain a copy of the License at 5# 6# http://www.apache.org/licenses/LICENSE-2.0 7# 8# Unless required by applicable law or agreed to in writing, software 9# distributed under the License is distributed on an "AS IS" BASIS, 10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 11# See the License for the specific language governing permissions and 12# limitations under the License. 13 14import("//base/security/device_auth/deps_adapter/deviceauth_hals.gni") 15import("//base/security/device_auth/services/deviceauth.gni") 16 17#####################hydra-fuzz################### 18import("//build/config/features.gni") 19import("//build/test.gni") 20THIRD_PATH = "//third_party/bounds_checking_function" 21module_output_path = "device_auth/device_auth" 22 23##############################fuzztest########################################## 24ohos_fuzztest("DestroyFuzzTest") { 25 module_out_path = module_output_path 26 fuzz_config_file = 27 "${deviceauth_path}/frameworks/deviceauth_lite/fuzztest/destroy_fuzzer" 28 include_dirs = [] 29 include_dirs += [ 30 "${deviceauth_path}/interfaces/inner_api/deviceauth_lite", 31 "${deviceauth_path}/frameworks/deviceauth_lite/source/schdeule", 32 "${deviceauth_path}/frameworks/deviceauth_lite/source/key_agreement", 33 "${deviceauth_path}/frameworks/deviceauth_lite/source/base", 34 "${deviceauth_path}/frameworks/deviceauth_lite/source/struct", 35 "$THIRD_PATH/include", 36 "${deviceauth_path}/frameworks/deviceauth_lite/source/json", 37 ] 38 cflags = [ 39 "-g", 40 "-O0", 41 "-Wno-unused-variable", 42 "-fno-omit-frame-pointer", 43 "--coverage", 44 ] 45 46 ldflags = [ "--coverage" ] 47 48 sources = [ "destroy_fuzzer.cpp" ] 49 deps = [ 50 "$THIRD_PATH:libsec_shared", 51 "${deviceauth_path}/frameworks/deviceauth_lite/source:hichainsdk", 52 ] 53} 54 55############################################################################### 56group("fuzztest") { 57 testonly = true 58 deps = [] 59 deps += [ 60 # deps file 61 ":DestroyFuzzTest", 62 ] 63} 64############################################################################### 65