1b2a28edaSopenharmony_ci<?xml version="1.0" encoding="UTF-8"?> 2b2a28edaSopenharmony_ci<!-- Copyright (c) 2021 Huawei Device Co., Ltd. 3b2a28edaSopenharmony_ci 4b2a28edaSopenharmony_ci Licensed under the Apache License, Version 2.0 (the "License"); 5b2a28edaSopenharmony_ci you may not use this file except in compliance with the License. 6b2a28edaSopenharmony_ci You may obtain a copy of the License at 7b2a28edaSopenharmony_ci 8b2a28edaSopenharmony_ci http://www.apache.org/licenses/LICENSE-2.0 9b2a28edaSopenharmony_ci 10b2a28edaSopenharmony_ci Unless required by applicable law or agreed to in writing, software 11b2a28edaSopenharmony_ci distributed under the License is distributed on an "AS IS" BASIS, 12b2a28edaSopenharmony_ci WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13b2a28edaSopenharmony_ci See the License for the specific language governing permissions and 14b2a28edaSopenharmony_ci limitations under the License. 15b2a28edaSopenharmony_ci 16b2a28edaSopenharmony_ci Notes: 17b2a28edaSopenharmony_ci This is project config file for OpenHarmony OSS Audit Tool, if you have any questions or concerns, please email chenyaxun. 18b2a28edaSopenharmony_ci--> 19b2a28edaSopenharmony_ci<!-- OAT(OSS Audit Tool) configuration guide: 20b2a28edaSopenharmony_cibasedir: Root dir, the basedir + project path is the real source file location. 21b2a28edaSopenharmony_cilicensefile: 22b2a28edaSopenharmony_ci1.If the project don't have "LICENSE" in root dir, please define all the license files in this project in , OAT will check license files according to this rule. 23b2a28edaSopenharmony_ci 24b2a28edaSopenharmony_citasklist(only for batch mode): 25b2a28edaSopenharmony_ci1. task: Define oat check thread, each task will start a new thread. 26b2a28edaSopenharmony_ci2. task name: Only an name, no practical effect. 27b2a28edaSopenharmony_ci3. task policy: Default policy for projects under this task, this field is required and the specified policy must defined in policylist. 28b2a28edaSopenharmony_ci4. task filter: Default filefilter for projects under this task, this field is required and the specified filefilter must defined in filefilterlist. 29b2a28edaSopenharmony_ci5. task project: Projects to be checked, the path field define the source root dir of the project. 30b2a28edaSopenharmony_ci 31b2a28edaSopenharmony_ci 32b2a28edaSopenharmony_cipolicyList: 33b2a28edaSopenharmony_ci1. policy: All policyitems will be merged to default OAT.xml rules, the name of policy doesn't affect OAT check process. 34b2a28edaSopenharmony_ci2. policyitem: The fields type, name, path, desc is required, and the fields rule, group, filefilter is optional,the default value is: 35b2a28edaSopenharmony_ci<policyitem type="" name="" path="" desc="" rule="may" group="defaultGroup" filefilter="defaultPolicyFilter"/> 36b2a28edaSopenharmony_ci3. policyitem type: 37b2a28edaSopenharmony_ci "compatibility" is used to check license compatibility in the specified path; 38b2a28edaSopenharmony_ci "license" is used to check source license header in the specified path; 39b2a28edaSopenharmony_ci "copyright" is used to check source copyright header in the specified path; 40b2a28edaSopenharmony_ci "import" is used to check source dependency in the specified path, such as import ... ,include ... 41b2a28edaSopenharmony_ci "filetype" is used to check file type in the specified path, supported file types: archive, binary 42b2a28edaSopenharmony_ci "filename" is used to check whether the specified file exists in the specified path(support projectroot in default OAT.xml), supported file names: LICENSE, README, README.OpenSource 43b2a28edaSopenharmony_ci 44b2a28edaSopenharmony_ci4. policyitem name: This field is used for define the license, copyright, "*" means match all, the "!" prefix means could not match this value. For example, "!GPL" means can not use GPL license. 45b2a28edaSopenharmony_ci5. policyitem path: This field is used for define the source file scope to apply this policyitem, the "!" prefix means exclude the files. For example, "!.*/lib/.*" means files in lib dir will be exclude while process this policyitem. 46b2a28edaSopenharmony_ci6. policyitem rule and group: These two fields are used together to merge policy results. "may" policyitems in the same group means any one in this group passed, the result will be passed. 47b2a28edaSopenharmony_ci7. policyitem filefilter: Used to bind filefilter which define filter rules. 48b2a28edaSopenharmony_ci8. filefilter: Filter rules, the type filename is used to filter file name, the type filepath is used to filter file path. 49b2a28edaSopenharmony_ci 50b2a28edaSopenharmony_ciNote:If the text contains special characters, please escape them according to the following rules: 51b2a28edaSopenharmony_ci" == > 52b2a28edaSopenharmony_ci& == > 53b2a28edaSopenharmony_ci' == > 54b2a28edaSopenharmony_ci< == > 55b2a28edaSopenharmony_ci> == > 56b2a28edaSopenharmony_ci--> 57b2a28edaSopenharmony_ci<configuration> 58b2a28edaSopenharmony_ci <oatconfig> 59b2a28edaSopenharmony_ci <policylist> 60b2a28edaSopenharmony_ci <policy name="projectPolicy" desc=""> 61b2a28edaSopenharmony_ci <policyitem type="compatibility" name="Khronos License" path="BUILD.gn" desc="宽松型许可证,实际兼容"/> 62b2a28edaSopenharmony_ci <policyitem type="compatibility" name="Khronos License" path="LICENSE" desc="宽松型许可证,实际兼容"/> 63b2a28edaSopenharmony_ci <policyitem type="compatibility" name="Khronos License" path="example/example.cpp" desc="宽松型许可证,实际兼容"/> 64b2a28edaSopenharmony_ci <policyitem type="compatibility" name="Khronos License" path="include/spirv/.*" desc="宽松型许可证,实际兼容"/> 65b2a28edaSopenharmony_ci <policyitem type="compatibility" name="Khronos License" path="tools/buildHeaders/.*" desc="宽松型许可证,实际兼容"/> 66b2a28edaSopenharmony_ci </policy> 67b2a28edaSopenharmony_ci </policylist> 68b2a28edaSopenharmony_ci 69b2a28edaSopenharmony_ci <filefilterlist> 70b2a28edaSopenharmony_ci <filefilter name="defaultFilter" desc="Files not to check"> 71b2a28edaSopenharmony_ci </filefilter> 72b2a28edaSopenharmony_ci <filefilter name="defaultPolicyFilter" desc="Filters for compatibility,license header policies"> 73b2a28edaSopenharmony_ci <filteritem type="filename" name="README.OpenSource"/> 74b2a28edaSopenharmony_ci <filteritem type="filename" name="README"/> 75b2a28edaSopenharmony_ci <filteritem type="filename" name="*.pc"/> 76b2a28edaSopenharmony_ci <filteritem type="filename" name="doxygen.ini.in" desc="not used in ohos"/> 77b2a28edaSopenharmony_ci <filteritem type="filename" name="COPYING" desc="data/COPYING not used in ohos"/> 78b2a28edaSopenharmony_ci <filteritem type="filename" name="DCO-1.1.txt" desc="not used in ohos"/> 79b2a28edaSopenharmony_ci <filteritem type="filename" name="BUILD.bazel" desc="构建文件"/> 80b2a28edaSopenharmony_ci <filteritem type="filepath" name="tools/buildHeaders/jsoncpp/dist/.*"/> 81b2a28edaSopenharmony_ci </filefilter> 82b2a28edaSopenharmony_ci <filefilter name="copyrightPolicyFilter" desc="Filters for copyright header policies" > 83b2a28edaSopenharmony_ci <filteritem type="filename" name="README.OpenSource"/> 84b2a28edaSopenharmony_ci <filteritem type="filename" name="README"/> 85b2a28edaSopenharmony_ci </filefilter> 86b2a28edaSopenharmony_ci <filefilter name="binaryFileTypePolicyFilter" desc="Filters for binary file policies"> 87b2a28edaSopenharmony_ci <filteritem type="filename" name="*.bmp|*.png|*.jpg" desc="binary not used and belonged to weston"/> 88b2a28edaSopenharmony_ci </filefilter> 89b2a28edaSopenharmony_ci </filefilterlist> 90b2a28edaSopenharmony_ci </oatconfig> 91b2a28edaSopenharmony_ci</configuration> 92b2a28edaSopenharmony_ci 93