1/*
2 * Copyright (C) 2022 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 */
16package {
17    default_team: "trendy_team_camera_framework",
18    // See: http://go/android-license-faq
19    // A large-scale-change added 'default_applicable_licenses' to import
20    // all of the 'license_kinds' from "frameworks_av_camera_license"
21    // to get the below license kinds:
22    //   SPDX-license-identifier-Apache-2.0
23    default_applicable_licenses: ["frameworks_av_camera_license"],
24}
25
26cc_defaults {
27    name: "camera_defaults",
28    static_libs: [
29        "libcamera_client",
30        "libbinder_random_parcel",
31    ],
32    shared_libs: [
33        "camera_platform_flags_c_lib",
34        "libbase",
35        "libcutils",
36        "libutils",
37        "liblog",
38        "libbinder",
39        "libgui",
40        "libcamera_metadata",
41        "libnativewindow",
42    ],
43    header_libs: [
44        "libbinder_headers",
45    ],
46    fuzz_config: {
47        cc: [
48            "android-camera-fwk-eng@google.com",
49        ],
50        componentid: 41727,
51        hotlists: [
52            "4593311",
53        ],
54        description: "The fuzzer targets the APIs of libcamera_client",
55        vector: "local_no_privileges_required",
56        service_privilege: "privileged",
57        users: "multi_user",
58        fuzzed_code_usage: "shipped",
59    },
60}
61
62cc_fuzz {
63    name: "camera_fuzzer",
64    srcs: [
65        "camera_fuzzer.cpp",
66    ],
67    defaults: [
68        "camera_defaults",
69    ],
70}
71
72cc_fuzz {
73    name: "camera_c2CaptureRequest_fuzzer",
74    srcs: [
75        "camera_c2CaptureRequest_fuzzer.cpp",
76    ],
77    defaults: [
78        "camera_defaults",
79    ],
80}
81
82cc_fuzz {
83    name: "camera_c2ConcurrentCamera_fuzzer",
84    srcs: [
85        "camera_c2ConcurrentCamera_fuzzer.cpp",
86    ],
87    defaults: [
88        "camera_defaults",
89    ],
90}
91
92cc_fuzz {
93    name: "camera_c2SubmitInfo_fuzzer",
94    srcs: [
95        "camera_c2SubmitInfo_fuzzer.cpp",
96    ],
97    defaults: [
98        "camera_defaults",
99    ],
100}
101
102cc_fuzz {
103    name: "camera_c2SessionConfiguration_fuzzer",
104    srcs: [
105        "camera_c2SessionConfiguration_fuzzer.cpp",
106    ],
107    defaults: [
108        "camera_defaults",
109    ],
110}
111
112cc_fuzz {
113    name: "camera_c2OutputConfiguration_fuzzer",
114    srcs: [
115        "camera_c2OutputConfiguration_fuzzer.cpp",
116    ],
117    defaults: [
118        "camera_defaults",
119    ],
120}
121
122cc_fuzz {
123    name: "camera_vendorTagDescriptor_fuzzer",
124    srcs: [
125        "camera_vendorTagDescriptor_fuzzer.cpp",
126    ],
127    defaults: [
128        "camera_defaults",
129    ],
130    include_dirs: [
131        "system/media/camera/tests",
132        "system/media/private/camera/include",
133    ],
134}
135
136cc_fuzz {
137    name: "camera_Parameters_fuzzer",
138    srcs: [
139        "camera_Parameters_fuzzer.cpp",
140    ],
141    defaults: [
142        "camera_defaults",
143    ],
144}
145
146cc_fuzz {
147    name: "camera_SessionStats_fuzzer",
148    srcs: [
149        "camera_SessionStats_fuzzer.cpp",
150    ],
151    defaults: [
152        "camera_defaults",
153    ],
154}
155
156cc_fuzz {
157    name: "camera_captureResult_fuzzer",
158    srcs: [
159        "camera_captureResult_fuzzer.cpp",
160    ],
161    defaults: [
162        "camera_defaults",
163    ],
164}
165
166cc_fuzz {
167    name: "camera_utils_fuzzer",
168    srcs: [
169        "camera_utils_fuzzer.cpp",
170    ],
171    defaults: [
172        "camera_defaults",
173    ],
174}
175
176cc_fuzz {
177    name: "camera_metadata_fuzzer",
178    srcs: [
179        "camera_metadata_fuzzer.cpp",
180    ],
181    defaults: [
182        "camera_defaults",
183    ],
184}
185