xref: /aosp_15_r20/frameworks/native/services/surfaceflinger/fuzzer/Android.bp (revision 38e8c45f13ce32b0dcecb25141ffecaf386fa17f)
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
18package {
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    default_team: "trendy_team_android_core_graphics_stack",
26}
27
28cc_defaults {
29    name: "surfaceflinger_fuzz_defaults",
30    static_libs: [
31        "libsurfaceflinger_common",
32    ],
33    srcs: [
34        ":libsurfaceflinger_backend_mock_sources",
35        ":libsurfaceflinger_mock_sources",
36        ":libsurfaceflinger_sources",
37    ],
38    defaults: [
39        "libsurfaceflinger_defaults",
40    ],
41    header_libs: [
42        "libsurfaceflinger_backend_mock_headers",
43        "libsurfaceflinger_headers",
44    ],
45    cflags: [
46        "-Wno-unused-result",
47        "-Wno-conversion",
48        "-Wno-sign-compare",
49        "-Wno-unused-function",
50    ],
51    fuzz_config: {
52        cc: [
53            "[email protected]",
54        ],
55        componentid: 1075131,
56        hotlists: [
57            "4593311",
58        ],
59        description: "The fuzzer targets the APIs of libsurfaceflinger library",
60        vector: "local_no_privileges_required",
61        service_privilege: "privileged",
62        users: "multi_user",
63        fuzzed_code_usage: "shipped",
64    },
65}
66
67cc_fuzz {
68    name: "surfaceflinger_service_fuzzer",
69    defaults: [
70        "surfaceflinger_fuzz_defaults",
71        "service_fuzzer_defaults",
72        "fuzzer_disable_leaks",
73    ],
74    srcs: [
75        "surfaceflinger_service_fuzzer.cpp",
76    ],
77    fuzz_config: {
78        triage_assignee: "[email protected]",
79    },
80}
81