Alec Mouri | b2089a3 | 2022-01-15 00:34:20 +0000 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2021 The Android Open Source Project |
| 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at: |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | * |
| 16 | */ |
| 17 | |
Bob Badour | c26d6d5 | 2022-02-10 13:41:04 -0800 | [diff] [blame] | 18 | package { |
| 19 | // See: http://go/android-license-faq |
| 20 | // A large-scale-change added 'default_applicable_licenses' to import |
| 21 | // all of the 'license_kinds' from "frameworks_native_license" |
| 22 | // to get the below license kinds: |
| 23 | // SPDX-license-identifier-Apache-2.0 |
| 24 | default_applicable_licenses: ["frameworks_native_license"], |
| 25 | } |
| 26 | |
Alec Mouri | b2089a3 | 2022-01-15 00:34:20 +0000 | [diff] [blame] | 27 | cc_defaults { |
| 28 | name: "surfaceflinger_fuzz_defaults", |
| 29 | include_dirs: [ |
| 30 | "frameworks/native/services/surfaceflinger/tests/unittests", |
| 31 | ], |
| 32 | static_libs: [ |
| 33 | "android.hardware.graphics.composer@2.1-resources", |
Patrick Williams | 8b731c1 | 2023-10-24 09:56:24 -0500 | [diff] [blame] | 34 | "libc++fs", |
Alec Mouri | b2089a3 | 2022-01-15 00:34:20 +0000 | [diff] [blame] | 35 | "libgmock", |
| 36 | "libgui_mocks", |
| 37 | "libgmock_ndk", |
| 38 | "libgmock_main", |
| 39 | "libgtest_ndk_c++", |
| 40 | "libgmock_main_ndk", |
| 41 | "librenderengine_mocks", |
Alec Mouri | 9b133ca | 2023-11-14 19:00:01 +0000 | [diff] [blame] | 42 | "libsurfaceflinger_common", |
Alec Mouri | b2089a3 | 2022-01-15 00:34:20 +0000 | [diff] [blame] | 43 | "perfetto_trace_protos", |
| 44 | "libcompositionengine_mocks", |
| 45 | "perfetto_trace_protos", |
| 46 | ], |
| 47 | shared_libs: [ |
| 48 | "libprotoutil", |
| 49 | "libstatssocket", |
| 50 | "libstatspull", |
| 51 | "libtimestats", |
| 52 | "libtimestats_proto", |
| 53 | "libprotobuf-cpp-full", |
| 54 | "android.hardware.graphics.mapper@2.0", |
| 55 | "android.hardware.graphics.mapper@3.0", |
| 56 | "android.hardware.graphics.mapper@4.0", |
| 57 | ], |
| 58 | srcs: [ |
| 59 | ":libsurfaceflinger_sources", |
| 60 | ":libsurfaceflinger_mock_sources", |
| 61 | ], |
| 62 | defaults: [ |
| 63 | "libsurfaceflinger_defaults", |
| 64 | ], |
| 65 | header_libs: [ |
| 66 | "libui_fuzzableDataspaces_headers", |
| 67 | "libsurfaceflinger_headers", |
| 68 | "libui_headers", |
| 69 | ], |
| 70 | cflags: [ |
| 71 | "-Wno-unused-result", |
| 72 | "-Wno-conversion", |
| 73 | "-Wno-sign-compare", |
Leon Scroggins III | bfab505 | 2023-03-24 15:45:46 -0400 | [diff] [blame] | 74 | "-Wno-unused-function", |
Alec Mouri | b2089a3 | 2022-01-15 00:34:20 +0000 | [diff] [blame] | 75 | ], |
| 76 | fuzz_config: { |
| 77 | cc: [ |
Ayushi Khopkar | 7bf9189 | 2023-03-17 15:45:22 +0530 | [diff] [blame] | 78 | "android-cogs-eng@google.com", |
Alec Mouri | b2089a3 | 2022-01-15 00:34:20 +0000 | [diff] [blame] | 79 | ], |
Ayushi Khopkar | 7bf9189 | 2023-03-17 15:45:22 +0530 | [diff] [blame] | 80 | componentid: 1075131, |
| 81 | hotlists: [ |
| 82 | "4593311", |
| 83 | ], |
| 84 | description: "The fuzzer targets the APIs of libsurfaceflinger library", |
| 85 | vector: "local_no_privileges_required", |
| 86 | service_privilege: "privileged", |
| 87 | users: "multi_user", |
| 88 | fuzzed_code_usage: "shipped", |
Alec Mouri | b2089a3 | 2022-01-15 00:34:20 +0000 | [diff] [blame] | 89 | }, |
| 90 | } |
| 91 | |
| 92 | cc_fuzz { |
| 93 | name: "surfaceflinger_fuzzer", |
| 94 | defaults: [ |
| 95 | "surfaceflinger_fuzz_defaults", |
| 96 | ], |
| 97 | srcs: [ |
| 98 | "surfaceflinger_fuzzer.cpp", |
| 99 | ], |
| 100 | } |
Alec Mouri | 8c59b27 | 2022-01-15 00:34:20 +0000 | [diff] [blame] | 101 | |
| 102 | cc_fuzz { |
| 103 | name: "surfaceflinger_displayhardware_fuzzer", |
| 104 | defaults: [ |
| 105 | "surfaceflinger_fuzz_defaults", |
| 106 | ], |
| 107 | srcs: [ |
| 108 | "surfaceflinger_displayhardware_fuzzer.cpp", |
| 109 | ], |
| 110 | header_libs: [ |
| 111 | "android.hardware.graphics.composer@2.4-command-buffer", |
| 112 | "android.hardware.graphics.composer@2.4-hal", |
| 113 | ], |
| 114 | } |
Chethan Kumar R E | 70750f2 | 2021-11-23 17:39:01 +0530 | [diff] [blame] | 115 | |
| 116 | cc_fuzz { |
| 117 | name: "surfaceflinger_scheduler_fuzzer", |
| 118 | defaults: [ |
| 119 | "surfaceflinger_fuzz_defaults", |
| 120 | ], |
| 121 | srcs: [ |
| 122 | "surfaceflinger_scheduler_fuzzer.cpp", |
| 123 | ], |
| 124 | } |
Chethan Kumar R E | 041415a | 2021-11-23 17:42:22 +0530 | [diff] [blame] | 125 | |
| 126 | cc_fuzz { |
| 127 | name: "surfaceflinger_layer_fuzzer", |
| 128 | defaults: [ |
| 129 | "surfaceflinger_fuzz_defaults", |
| 130 | ], |
| 131 | header_libs: [ |
| 132 | "libgui_headers", |
| 133 | ], |
| 134 | static_libs: [ |
| 135 | "librenderengine", |
| 136 | ], |
| 137 | srcs: [ |
| 138 | "surfaceflinger_layer_fuzzer.cpp", |
| 139 | ], |
| 140 | } |
Chethan Kumar R E | cd5229e | 2021-11-23 17:45:54 +0530 | [diff] [blame] | 141 | |
| 142 | cc_fuzz { |
| 143 | name: "surfaceflinger_frametracer_fuzzer", |
| 144 | defaults: [ |
| 145 | "surfaceflinger_fuzz_defaults", |
| 146 | ], |
| 147 | srcs: [ |
| 148 | "surfaceflinger_frametracer_fuzzer.cpp", |
| 149 | ], |
| 150 | } |
Pawan Wagh | 1dd5f38 | 2023-06-01 23:43:10 +0000 | [diff] [blame] | 151 | |
| 152 | cc_fuzz { |
| 153 | name: "surfaceflinger_service_fuzzer", |
| 154 | defaults: [ |
| 155 | "surfaceflinger_fuzz_defaults", |
| 156 | "service_fuzzer_defaults", |
| 157 | "fuzzer_disable_leaks", |
| 158 | ], |
| 159 | srcs: [ |
| 160 | "surfaceflinger_service_fuzzer.cpp", |
| 161 | ], |
| 162 | fuzz_config: { |
| 163 | triage_assignee: "waghpawan@google.com", |
| 164 | }, |
| 165 | } |