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", |
| 42 | "perfetto_trace_protos", |
| 43 | "libcompositionengine_mocks", |
| 44 | "perfetto_trace_protos", |
| 45 | ], |
| 46 | shared_libs: [ |
| 47 | "libprotoutil", |
| 48 | "libstatssocket", |
| 49 | "libstatspull", |
| 50 | "libtimestats", |
| 51 | "libtimestats_proto", |
| 52 | "libprotobuf-cpp-full", |
| 53 | "android.hardware.graphics.mapper@2.0", |
| 54 | "android.hardware.graphics.mapper@3.0", |
| 55 | "android.hardware.graphics.mapper@4.0", |
| 56 | ], |
| 57 | srcs: [ |
| 58 | ":libsurfaceflinger_sources", |
| 59 | ":libsurfaceflinger_mock_sources", |
| 60 | ], |
| 61 | defaults: [ |
| 62 | "libsurfaceflinger_defaults", |
| 63 | ], |
| 64 | header_libs: [ |
| 65 | "libui_fuzzableDataspaces_headers", |
| 66 | "libsurfaceflinger_headers", |
| 67 | "libui_headers", |
| 68 | ], |
| 69 | cflags: [ |
| 70 | "-Wno-unused-result", |
| 71 | "-Wno-conversion", |
| 72 | "-Wno-sign-compare", |
Leon Scroggins III | bfab505 | 2023-03-24 15:45:46 -0400 | [diff] [blame] | 73 | "-Wno-unused-function", |
Alec Mouri | b2089a3 | 2022-01-15 00:34:20 +0000 | [diff] [blame] | 74 | ], |
| 75 | fuzz_config: { |
| 76 | cc: [ |
Ayushi Khopkar | 7bf9189 | 2023-03-17 15:45:22 +0530 | [diff] [blame] | 77 | "android-cogs-eng@google.com", |
Alec Mouri | b2089a3 | 2022-01-15 00:34:20 +0000 | [diff] [blame] | 78 | ], |
Ayushi Khopkar | 7bf9189 | 2023-03-17 15:45:22 +0530 | [diff] [blame] | 79 | componentid: 1075131, |
| 80 | hotlists: [ |
| 81 | "4593311", |
| 82 | ], |
| 83 | description: "The fuzzer targets the APIs of libsurfaceflinger library", |
| 84 | vector: "local_no_privileges_required", |
| 85 | service_privilege: "privileged", |
| 86 | users: "multi_user", |
| 87 | fuzzed_code_usage: "shipped", |
Alec Mouri | b2089a3 | 2022-01-15 00:34:20 +0000 | [diff] [blame] | 88 | }, |
| 89 | } |
| 90 | |
| 91 | cc_fuzz { |
| 92 | name: "surfaceflinger_fuzzer", |
| 93 | defaults: [ |
| 94 | "surfaceflinger_fuzz_defaults", |
| 95 | ], |
| 96 | srcs: [ |
| 97 | "surfaceflinger_fuzzer.cpp", |
| 98 | ], |
| 99 | } |
Alec Mouri | 8c59b27 | 2022-01-15 00:34:20 +0000 | [diff] [blame] | 100 | |
| 101 | cc_fuzz { |
| 102 | name: "surfaceflinger_displayhardware_fuzzer", |
| 103 | defaults: [ |
| 104 | "surfaceflinger_fuzz_defaults", |
| 105 | ], |
| 106 | srcs: [ |
| 107 | "surfaceflinger_displayhardware_fuzzer.cpp", |
| 108 | ], |
| 109 | header_libs: [ |
| 110 | "android.hardware.graphics.composer@2.4-command-buffer", |
| 111 | "android.hardware.graphics.composer@2.4-hal", |
| 112 | ], |
| 113 | } |
Chethan Kumar R E | 70750f2 | 2021-11-23 17:39:01 +0530 | [diff] [blame] | 114 | |
| 115 | cc_fuzz { |
| 116 | name: "surfaceflinger_scheduler_fuzzer", |
| 117 | defaults: [ |
| 118 | "surfaceflinger_fuzz_defaults", |
| 119 | ], |
| 120 | srcs: [ |
| 121 | "surfaceflinger_scheduler_fuzzer.cpp", |
| 122 | ], |
| 123 | } |
Chethan Kumar R E | 041415a | 2021-11-23 17:42:22 +0530 | [diff] [blame] | 124 | |
| 125 | cc_fuzz { |
| 126 | name: "surfaceflinger_layer_fuzzer", |
| 127 | defaults: [ |
| 128 | "surfaceflinger_fuzz_defaults", |
| 129 | ], |
| 130 | header_libs: [ |
| 131 | "libgui_headers", |
| 132 | ], |
| 133 | static_libs: [ |
| 134 | "librenderengine", |
| 135 | ], |
| 136 | srcs: [ |
| 137 | "surfaceflinger_layer_fuzzer.cpp", |
| 138 | ], |
| 139 | } |
Chethan Kumar R E | cd5229e | 2021-11-23 17:45:54 +0530 | [diff] [blame] | 140 | |
| 141 | cc_fuzz { |
| 142 | name: "surfaceflinger_frametracer_fuzzer", |
| 143 | defaults: [ |
| 144 | "surfaceflinger_fuzz_defaults", |
| 145 | ], |
| 146 | srcs: [ |
| 147 | "surfaceflinger_frametracer_fuzzer.cpp", |
| 148 | ], |
| 149 | } |
Pawan Wagh | 1dd5f38 | 2023-06-01 23:43:10 +0000 | [diff] [blame] | 150 | |
| 151 | cc_fuzz { |
| 152 | name: "surfaceflinger_service_fuzzer", |
| 153 | defaults: [ |
| 154 | "surfaceflinger_fuzz_defaults", |
| 155 | "service_fuzzer_defaults", |
| 156 | "fuzzer_disable_leaks", |
| 157 | ], |
| 158 | srcs: [ |
| 159 | "surfaceflinger_service_fuzzer.cpp", |
| 160 | ], |
| 161 | fuzz_config: { |
| 162 | triage_assignee: "waghpawan@google.com", |
| 163 | }, |
| 164 | } |