13fc297bdSopenharmony_ci<?xml version="1.0" encoding="UTF-8"?> 23fc297bdSopenharmony_ci<!-- Copyright (c) 2023 Huawei Device Co., Ltd. 33fc297bdSopenharmony_ci 43fc297bdSopenharmony_ci Licensed under the Apache License, Version 2.0 (the "License"); 53fc297bdSopenharmony_ci you may not use this file except in compliance with the License. 63fc297bdSopenharmony_ci You may obtain a copy of the License at 73fc297bdSopenharmony_ci 83fc297bdSopenharmony_ci http://www.apache.org/licenses/LICENSE-2.0 93fc297bdSopenharmony_ci 103fc297bdSopenharmony_ci Unless required by applicable law or agreed to in writing, software 113fc297bdSopenharmony_ci distributed under the License is distributed on an "AS IS" BASIS, 123fc297bdSopenharmony_ci WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 133fc297bdSopenharmony_ci See the License for the specific language governing permissions and 143fc297bdSopenharmony_ci limitations under the License. 153fc297bdSopenharmony_ci 163fc297bdSopenharmony_ci Notes: 173fc297bdSopenharmony_ci This is project config file for OpenHarmony OSS Audit Tool, if you have any questions or concerns, please email chenyaxun. 183fc297bdSopenharmony_ci--> 193fc297bdSopenharmony_ci<!-- OAT(OSS Audit Tool) configuration guide: 203fc297bdSopenharmony_cibasedir: Root dir, the basedir + project path is the real source file location. 213fc297bdSopenharmony_cilicensefile: 223fc297bdSopenharmony_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. 233fc297bdSopenharmony_ci 243fc297bdSopenharmony_citasklist(only for batch mode): 253fc297bdSopenharmony_ci1. task: Define oat check thread, each task will start a new thread. 263fc297bdSopenharmony_ci2. task name: Only an name, no practical effect. 273fc297bdSopenharmony_ci3. task policy: Default policy for projects under this task, this field is required and the specified policy must defined in policylist. 283fc297bdSopenharmony_ci4. task filter: Default filefilter for projects under this task, this field is required and the specified filefilter must defined in filefilterlist. 293fc297bdSopenharmony_ci5. task project: Projects to be checked, the path field define the source root dir of the project. 303fc297bdSopenharmony_ci 313fc297bdSopenharmony_ci 323fc297bdSopenharmony_cipolicyList: 333fc297bdSopenharmony_ci1. policy: All policyitems will be merged to default OAT.xml rules, the name of policy doesn't affect OAT check process. 343fc297bdSopenharmony_ci2. policyitem: The fields type, name, path, desc is required, and the fields rule, group, filefilter is optional,the default value is: 353fc297bdSopenharmony_ci<policyitem type="" name="" path="" desc="" rule="may" group="defaultGroup" filefilter="defaultPolicyFilter"/> 363fc297bdSopenharmony_ci3. policyitem type: 373fc297bdSopenharmony_ci "compatibility" is used to check license compatibility in the specified path; 383fc297bdSopenharmony_ci "license" is used to check source license header in the specified path; 393fc297bdSopenharmony_ci "copyright" is used to check source copyright header in the specified path; 403fc297bdSopenharmony_ci "import" is used to check source dependency in the specified path, such as import ... ,include ... 413fc297bdSopenharmony_ci "filetype" is used to check file type in the specified path, supported file types: archive, binary 423fc297bdSopenharmony_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 433fc297bdSopenharmony_ci 443fc297bdSopenharmony_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. 453fc297bdSopenharmony_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. 463fc297bdSopenharmony_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. 473fc297bdSopenharmony_ci7. policyitem filefilter: Used to bind filefilter which define filter rules. 483fc297bdSopenharmony_ci8. filefilter: Filter rules, the type filename is used to filter file name, the type filepath is used to filter file path. 493fc297bdSopenharmony_ci 503fc297bdSopenharmony_ciNote:If the text contains special characters, please escape them according to the following rules: 513fc297bdSopenharmony_ci" == > 523fc297bdSopenharmony_ci& == > 533fc297bdSopenharmony_ci' == > 543fc297bdSopenharmony_ci< == > 553fc297bdSopenharmony_ci> == > 563fc297bdSopenharmony_ci--> 573fc297bdSopenharmony_ci<configuration> 583fc297bdSopenharmony_ci <oatconfig> 593fc297bdSopenharmony_ci <licensefile></licensefile> 603fc297bdSopenharmony_ci <policylist> 613fc297bdSopenharmony_ci <policy name="projectPolicy" desc=""> 623fc297bdSopenharmony_ci </policy> 633fc297bdSopenharmony_ci </policylist> 643fc297bdSopenharmony_ci <filefilterlist> 653fc297bdSopenharmony_ci <filefilter name="binaryFileTypePolicyFilter" desc="Filters for binary file policies" > 663fc297bdSopenharmony_ci <filteritem type="filepath" name="figures/.*" desc="architecture figure binary."/> 673fc297bdSopenharmony_ci </filefilter> 683fc297bdSopenharmony_ci </filefilterlist> 693fc297bdSopenharmony_ci </oatconfig> 703fc297bdSopenharmony_ci</configuration>