16e80583aSopenharmony_ci<?xml version="1.0" encoding="UTF-8"?> 26e80583aSopenharmony_ci<!-- Copyright (c) 2021 Huawei Device Co., Ltd. 36e80583aSopenharmony_ci 46e80583aSopenharmony_ci Licensed under the Apache License, Version 2.0 (the "License"); 56e80583aSopenharmony_ci you may not use this file except in compliance with the License. 66e80583aSopenharmony_ci You may obtain a copy of the License at 76e80583aSopenharmony_ci 86e80583aSopenharmony_ci http://www.apache.org/licenses/LICENSE-2.0 96e80583aSopenharmony_ci 106e80583aSopenharmony_ci Unless required by applicable law or agreed to in writing, software 116e80583aSopenharmony_ci distributed under the License is distributed on an "AS IS" BASIS, 126e80583aSopenharmony_ci WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 136e80583aSopenharmony_ci See the License for the specific language governing permissions and 146e80583aSopenharmony_ci limitations under the License. 156e80583aSopenharmony_ci 166e80583aSopenharmony_ci This is the configuration file template for OpenHarmony OSS Audit Tool, please copy it to your project root dir and modify it refer to OpenHarmony/tools_oat/README. 176e80583aSopenharmony_ci All configurations in this file will be merged to OAT-Default.xml, if you have any questions or concerns, please create issue in OpenHarmony/tools_oat and @jalenchen or chenyaxun. 186e80583aSopenharmony_ci 196e80583aSopenharmony_ci licensefile: 206e80583aSopenharmony_ci 1.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. 216e80583aSopenharmony_ci 226e80583aSopenharmony_ci policylist: 236e80583aSopenharmony_ci 1. policy: If the OAT-Default.xml policies do not meet your requirements, please add policies here. 246e80583aSopenharmony_ci 2. policyitem: The fields type, name, path, desc is required, and the fields rule, group, filefilter is optional,the default value is: 256e80583aSopenharmony_ci <policyitem type="" name="" path="" desc="" rule="may" group="defaultGroup" filefilter="defaultPolicyFilter"/> 266e80583aSopenharmony_ci 3. policyitem type: 276e80583aSopenharmony_ci "compatibility" is used to check license compatibility in the specified path; 286e80583aSopenharmony_ci "license" is used to check source license header in the specified path; 296e80583aSopenharmony_ci "copyright" is used to check source copyright header in the specified path; 306e80583aSopenharmony_ci "import" is used to check source dependency in the specified path, such as import ... ,include ... 316e80583aSopenharmony_ci "filetype" is used to check file type in the specified path, supported file types: archive, binary 326e80583aSopenharmony_ci "filename" is used to check whether the specified file exists in the specified path(projectroot means the root dir of the project), supported file names: LICENSE, README, README.OpenSource 336e80583aSopenharmony_ci 4. 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. 346e80583aSopenharmony_ci 5. 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. 356e80583aSopenharmony_ci 6. 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. 366e80583aSopenharmony_ci 7. policyitem filefilter: Used to bind filefilter which define filter rules. 376e80583aSopenharmony_ci 7. policyitem desc: Used to describe the reason of this policy item, committers will check this while merging the code. 386e80583aSopenharmony_ci 8. filefilter: Filter rules, the type filename is used to filter file name, the type filepath is used to filter file path. 396e80583aSopenharmony_ci 406e80583aSopenharmony_ci Note:If the text contains special characters, please escape them according to the following rules: 416e80583aSopenharmony_ci " == > 426e80583aSopenharmony_ci & == > 436e80583aSopenharmony_ci ' == > 446e80583aSopenharmony_ci < == > 456e80583aSopenharmony_ci > == > 466e80583aSopenharmony_ci--> 476e80583aSopenharmony_ci 486e80583aSopenharmony_ci<configuration> 496e80583aSopenharmony_ci <oatconfig> 506e80583aSopenharmony_ci <policylist> 516e80583aSopenharmony_ci <policy name="projectPolicy" desc=""> 526e80583aSopenharmony_ci <policyitem type="license" name="Apache-2.0" path=".*" rule="may" group="defaultGroup" filefilter="defaultPolicyFilter" desc=""/> 536e80583aSopenharmony_ci <policyitem type="copyright" name="Huawei Device Co., Ltd." path=".*" rule="may" group="defaultGroup" filefilter="copyrightPolicyFilter" desc=""/> 546e80583aSopenharmony_ci <policyitem type="filetype" name="!binary" path=".*" rule="must" group="defaultGroup" filefilter="binaryFileTypePolicyFilter" desc=""/> 556e80583aSopenharmony_ci </policy> 566e80583aSopenharmony_ci </policylist> 576e80583aSopenharmony_ci <filefilterlist> 586e80583aSopenharmony_ci <filefilter name="binaryFileTypePolicyFilter" desc="Filters for binary file policies"> 596e80583aSopenharmony_ci <filteritem type="filepath" name="product/phone/src/main/resources/base/media/.*.png" desc="self developed image"/> 606e80583aSopenharmony_ci <filteritem type="filepath" name="product/phone/src/main/ets/default/common/pics/.*.png" desc="self developed image"/> 616e80583aSopenharmony_ci <filteritem type="filepath" name="product/phone/src/main/ets/default/common/pics/.*.jpg" desc="self developed image"/> 626e80583aSopenharmony_ci <filteritem type="filepath" name="product/phone/src/main/ets/default/common/pics/.*.svg" desc="self developed image"/> 636e80583aSopenharmony_ci <filteritem type="filepath" name="product/pad/src/main/resources/base/media/.*.png" desc="self developed image"/> 646e80583aSopenharmony_ci <filteritem type="filepath" name="product/pad/src/main/ets/default/common/pics/.*.jpg" desc="self developed image"/> 656e80583aSopenharmony_ci <filteritem type="filepath" name="product/pad/src/main/ets/default/common/pics/.*.svg" desc="self developed image"/> 666e80583aSopenharmony_ci <filteritem type="filepath" name="feature/recents/src/main/ets/default/common/pics/.*.png" desc="self developed image"/> 676e80583aSopenharmony_ci <filteritem type="filepath" name="feature/recents/src/main/ets/default/common/pics/.*.jpg" desc="self developed image"/> 686e80583aSopenharmony_ci <filteritem type="filepath" name="feature/recents/src/main/resources/base/media/.*.png" desc="self developed image"/> 696e80583aSopenharmony_ci <filteritem type="filepath" name="feature/recents/src/main/resources/base/media/.*.jpg" desc="self developed image"/> 706e80583aSopenharmony_ci <filteritem type="filepath" name="feature/settings/src/main/resources/base/media/.*.png" desc="self developed image"/> 716e80583aSopenharmony_ci <filteritem type="filepath" name="feature/appcenter/src/main/ets/default/common/pics/.*.jpg" desc="self developed image"/> 726e80583aSopenharmony_ci <filteritem type="filepath" name="feature/bigfolder/src/main/resources/base/media/.*.png" desc="self developed image"/> 736e80583aSopenharmony_ci <filteritem type="filepath" name="feature/form/src/main/resources/base/media/.*.png" desc="self developed image"/> 746e80583aSopenharmony_ci <filteritem type="filepath" name="figures/.*.png" desc="self developed image"/> 756e80583aSopenharmony_ci <filteritem type="filepath" name="feature/pagedesktop/src/main/resources/base/media/.*.png" desc="self developed image"/> 766e80583aSopenharmony_ci <filteritem type="filepath" name="feature/settings/src/main/resources/base/media/.*.svg" desc="self developed image"/> 776e80583aSopenharmony_ci <filteritem type="filepath" name="common/src/main/resources/base/media/.*.png" desc="self developed image"/> 786e80583aSopenharmony_ci <filteritem type="filepath" name="AppScope/resources/base/media/.*.png" desc="self developed image"/> 796e80583aSopenharmony_ci </filefilter> 806e80583aSopenharmony_ci <filefilter name="copyrightPolicyFilter" desc="Filters for copyright header policies"> 816e80583aSopenharmony_ci <filteritem type="filename" name="README|README_zh|.*.log|.*.json5|.*.json" desc=""/> 826e80583aSopenharmony_ci <filteritem type="filename" name="hvigorw|hvigorw.bat|hvigor-wrapper.js" desc="Build files"/> 836e80583aSopenharmony_ci </filefilter> 846e80583aSopenharmony_ci <filefilter name="defaultPolicyFilter" desc="Filters for LICENSE file policies"> 856e80583aSopenharmony_ci <filteritem type="filename" name="README|README_zh|*.log|*.json5|*.json" desc="json file"/> 866e80583aSopenharmony_ci <filteritem type="filename" name="hvigorw|hvigorw.bat|hvigor-wrapper.js" desc="Build files"/> 876e80583aSopenharmony_ci </filefilter> 886e80583aSopenharmony_ci </filefilterlist> 896e80583aSopenharmony_ci </oatconfig> 906e80583aSopenharmony_ci</configuration> 91