1da853ecaSopenharmony_ci<?xml version="1.0" encoding="UTF-8"?> 2da853ecaSopenharmony_ci<!-- Copyright (c) 2023 Huawei Device Co., Ltd. 3da853ecaSopenharmony_ci 4da853ecaSopenharmony_ci Licensed under the Apache License, Version 2.0 (the "License"); 5da853ecaSopenharmony_ci you may not use this file except in compliance with the License. 6da853ecaSopenharmony_ci You may obtain a copy of the License at 7da853ecaSopenharmony_ci 8da853ecaSopenharmony_ci http://www.apache.org/licenses/LICENSE-2.0 9da853ecaSopenharmony_ci 10da853ecaSopenharmony_ci Unless required by applicable law or agreed to in writing, software 11da853ecaSopenharmony_ci distributed under the License is distributed on an "AS IS" BASIS, 12da853ecaSopenharmony_ci WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13da853ecaSopenharmony_ci See the License for the specific language governing permissions and 14da853ecaSopenharmony_ci limitations under the License. 15da853ecaSopenharmony_ci 16da853ecaSopenharmony_ci Notes: 17da853ecaSopenharmony_ci This is project config file for OpenHarmony OSS Audit Tool, if you have any questions or concerns, please email chenyaxun. 18da853ecaSopenharmony_ci--> 19da853ecaSopenharmony_ci<!-- OAT(OSS Audit Tool) configuration guide: 20da853ecaSopenharmony_cibasedir: Root dir, the basedir + project path is the real source file location. 21da853ecaSopenharmony_cilicensefile: 22da853ecaSopenharmony_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. 23da853ecaSopenharmony_ci 24da853ecaSopenharmony_citasklist(only for batch mode): 25da853ecaSopenharmony_ci1. task: Define oat check thread, each task will start a new thread. 26da853ecaSopenharmony_ci2. task name: Only an name, no practical effect. 27da853ecaSopenharmony_ci3. task policy: Default policy for projects under this task, this field is required and the specified policy must defined in policylist. 28da853ecaSopenharmony_ci4. task filter: Default filefilter for projects under this task, this field is required and the specified filefilter must defined in filefilterlist. 29da853ecaSopenharmony_ci5. task project: Projects to be checked, the path field define the source root dir of the project. 30da853ecaSopenharmony_ci 31da853ecaSopenharmony_ci 32da853ecaSopenharmony_cipolicyList: 33da853ecaSopenharmony_ci1. policy: All policyitems will be merged to default OAT.xml rules, the name of policy doesn't affect OAT check process. 34da853ecaSopenharmony_ci2. policyitem: The fields type, name, path, desc is required, and the fields rule, group, filefilter is optional,the default value is: 35da853ecaSopenharmony_ci<policyitem type="" name="" path="" desc="" rule="may" group="defaultGroup" filefilter="defaultPolicyFilter"/> 36da853ecaSopenharmony_ci3. policyitem type: 37da853ecaSopenharmony_ci "compatibility" is used to check license compatibility in the specified path; 38da853ecaSopenharmony_ci "license" is used to check source license header in the specified path; 39da853ecaSopenharmony_ci "copyright" is used to check source copyright header in the specified path; 40da853ecaSopenharmony_ci "import" is used to check source dependency in the specified path, such as import ... ,include ... 41da853ecaSopenharmony_ci "filetype" is used to check file type in the specified path, supported file types: archive, binary 42da853ecaSopenharmony_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 43da853ecaSopenharmony_ci 44da853ecaSopenharmony_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. 45da853ecaSopenharmony_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. 46da853ecaSopenharmony_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. 47da853ecaSopenharmony_ci7. policyitem filefilter: Used to bind filefilter which define filter rules. 48da853ecaSopenharmony_ci8. filefilter: Filter rules, the type filename is used to filter file name, the type filepath is used to filter file path. 49da853ecaSopenharmony_ci 50da853ecaSopenharmony_ciNote:If the text contains special characters, please escape them according to the following rules: 51da853ecaSopenharmony_ci" == > 52da853ecaSopenharmony_ci& == > 53da853ecaSopenharmony_ci' == > 54da853ecaSopenharmony_ci< == > 55da853ecaSopenharmony_ci> == > 56da853ecaSopenharmony_ci--> 57da853ecaSopenharmony_ci<configuration> 58da853ecaSopenharmony_ci <oatconfig> 59da853ecaSopenharmony_ci <licensefile></licensefile> 60da853ecaSopenharmony_ci <policylist> 61da853ecaSopenharmony_ci <policy name="projectPolicy" desc=""> 62da853ecaSopenharmony_ci </policy> 63da853ecaSopenharmony_ci </policylist> 64da853ecaSopenharmony_ci <filefilterlist> 65da853ecaSopenharmony_ci <filefilter name="binaryFileTypePolicyFilter" desc="Filters for binary file policies" > 66da853ecaSopenharmony_ci <filteritem type="filepath" name="figures/.*" desc="architecture figure binary."/> 67da853ecaSopenharmony_ci </filefilter> 68da853ecaSopenharmony_ci <filefilter name="binaryFileTypePolicyFilter" desc="Filters for binary file policies" > 69da853ecaSopenharmony_ci <filteritem type="filepath" name="test/.*" desc="Resource, config and certification binary."/> 70da853ecaSopenharmony_ci </filefilter> 71da853ecaSopenharmony_ci <filefilter name="defaultFilter" desc="Default filter" > 72da853ecaSopenharmony_ci <filteritem type="filepath" name="test/.*" desc="Test path"/> 73da853ecaSopenharmony_ci </filefilter> 74da853ecaSopenharmony_ci </filefilterlist> 75da853ecaSopenharmony_ci </oatconfig> 76da853ecaSopenharmony_ci</configuration>