1e9297d28Sopenharmony_ci<?xml version="1.0" encoding="UTF-8"?> 2e9297d28Sopenharmony_ci<!-- Copyright (c) 2021 Huawei Device Co., Ltd. 3e9297d28Sopenharmony_ci 4e9297d28Sopenharmony_ci Licensed under the Apache License, Version 2.0 (the "License"); 5e9297d28Sopenharmony_ci you may not use this file except in compliance with the License. 6e9297d28Sopenharmony_ci You may obtain a copy of the License at 7e9297d28Sopenharmony_ci 8e9297d28Sopenharmony_ci http://www.apache.org/licenses/LICENSE-2.0 9e9297d28Sopenharmony_ci 10e9297d28Sopenharmony_ci Unless required by applicable law or agreed to in writing, software 11e9297d28Sopenharmony_ci distributed under the License is distributed on an "AS IS" BASIS, 12e9297d28Sopenharmony_ci WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13e9297d28Sopenharmony_ci See the License for the specific language governing permissions and 14e9297d28Sopenharmony_ci limitations under the License. 15e9297d28Sopenharmony_ci 16e9297d28Sopenharmony_ci Notes: 17e9297d28Sopenharmony_ci This is project config file for OpenHarmony OSS Audit Tool. If you have any questions or concerns, please send an email to chenyaxun. 18e9297d28Sopenharmony_ci--> 19e9297d28Sopenharmony_ci<!-- OAT (OSS Audit Tool) configuration guide: 20e9297d28Sopenharmony_cibasedir: Root dir. basedir + project path is the real source file location. 21e9297d28Sopenharmony_cilicensefile: 22e9297d28Sopenharmony_ciIf the project doesn't have "LICENSE" in root dir, please define all the license files in this project. OAT will check license files according to this rule. 23e9297d28Sopenharmony_ci 24e9297d28Sopenharmony_citasklist (for the batch mode only): 25e9297d28Sopenharmony_ci1. task: OAT check thread. Each task will start a new thread. 26e9297d28Sopenharmony_ci2. task name: Task name. 27e9297d28Sopenharmony_ci3. task policy: Default policy for projects under this task. This field is required and the specified policy must be defined in policylist. 28e9297d28Sopenharmony_ci4. task filter: Default filefilter for projects under this task. This field is required and the specified filefilter must be defined in filefilterlist. 29e9297d28Sopenharmony_ci5. task project: Projects to be checked. The path field defines the source root dir of the project. 30e9297d28Sopenharmony_ci 31e9297d28Sopenharmony_ci 32e9297d28Sopenharmony_cipolicyList: 33e9297d28Sopenharmony_ci1. policy: All policyitems will be merged to default OAT.xml rules. The name of policy doesn't affect the OAT check process. 34e9297d28Sopenharmony_ci2. policyitem: The fields type, name, path, desc are required, and the fields rule, group, filefilter are optional. The default value is: 35e9297d28Sopenharmony_ci<policyitem type="" name="" path="" desc="" rule="may" group="defaultGroup" filefilter="defaultPolicyFilter"/> 36e9297d28Sopenharmony_ci3. policyitem type: 37e9297d28Sopenharmony_ci "compatibility" is used to check license compatibility in the specified path. 38e9297d28Sopenharmony_ci "license" is used to check source license header in the specified path. 39e9297d28Sopenharmony_ci "copyright" is used to check source copyright header in the specified path. 40e9297d28Sopenharmony_ci "import" is used to check source dependency in the specified path, such as import and include. 41e9297d28Sopenharmony_ci "filetype" is used to check file type in the specified path. Supported file types include archive and binary. 42e9297d28Sopenharmony_ci "filename" is used to check whether the specified file exists in the specified path (support projectroot in the default OAT.xml). Supported file names include LICENSE, README, README.OpenSource. 43e9297d28Sopenharmony_ci 44e9297d28Sopenharmony_ci4. policyitem name: This field is used to define the license, copyright, "*" means match all, the "!" prefix means could not match this value. For example, "!GPL" means can not use GPL license. 45e9297d28Sopenharmony_ci5. policyitem path: This field is used to 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. 46e9297d28Sopenharmony_ci6. policyitem rule and group: These two fields are used together to merge policy results. "may" means that the result will be passed if any policyitem in the same group is passed. 47e9297d28Sopenharmony_ci7. policyitem filefilter: This field is used to bind filefilter which define filter rules. 48e9297d28Sopenharmony_ci8. filefilter: This field is used to define filter rules. filename is used to filter file name, and filepath is used to filter file path. 49e9297d28Sopenharmony_ci 50e9297d28Sopenharmony_ciNote: If the text contains special characters, please escape them according to the following rules: 51e9297d28Sopenharmony_ci" == > 52e9297d28Sopenharmony_ci& == > 53e9297d28Sopenharmony_ci' == > 54e9297d28Sopenharmony_ci< == > 55e9297d28Sopenharmony_ci> == > 56e9297d28Sopenharmony_ci--> 57e9297d28Sopenharmony_ci<configuration> 58e9297d28Sopenharmony_ci <oatconfig> 59e9297d28Sopenharmony_ci <licensefile>LICENSE</licensefile> 60e9297d28Sopenharmony_ci <filefilterlist> 61e9297d28Sopenharmony_ci <filefilter name="defaultFilter" desc="Files that do not need to be scanned"> 62e9297d28Sopenharmony_ci <filteritem type="filename" name="*.cfg" desc="cfg no need to add policy"/> 63e9297d28Sopenharmony_ci <filteritem type="filepath" name="frameworks/bootanimation/data/bootvideo.mp4" desc="default video"/> 64e9297d28Sopenharmony_ci </filefilter> 65e9297d28Sopenharmony_ci <filefilter name="binaryFileTypePolicyFilter" desc="Filters for binary file policies" > 66e9297d28Sopenharmony_ci <filteritem type="filename" name="graphic.png" desc="readme graphic png"/> 67e9297d28Sopenharmony_ci <filteritem type="filename" name="icon.png" desc="png for hap"/> 68e9297d28Sopenharmony_ci <filteritem type="filename" name="bootpic.zip" desc="bootanimation"/> 69e9297d28Sopenharmony_ci <filteritem type="filename" name="cursor.raw" desc="cursor"/> 70e9297d28Sopenharmony_ci <filteritem type="filename" name="startIcon.png" desc="app start icon"/> 71e9297d28Sopenharmony_ci <filteritem type="filename" name="DrawPath.jpg" desc="sample renderings"/> 72e9297d28Sopenharmony_ci <filteritem type="filename" name="Index.jpg" desc="sample renderings"/> 73e9297d28Sopenharmony_ci <filteritem type="filename" name="DrawText.jpg" desc="sample renderings"/> 74e9297d28Sopenharmony_ci <filteritem type="filename" name="app_icon.png" desc="app icon"/> 75e9297d28Sopenharmony_ci <filteritem type="filename" name="bootsound.wav" desc="bootanimation sound file"/> 76e9297d28Sopenharmony_ci <filteritem type="filename" name="bootvideo.mp4" desc="bootanimation video file"/> 77e9297d28Sopenharmony_ci </filefilter> 78e9297d28Sopenharmony_ci </filefilterlist> 79e9297d28Sopenharmony_ci </oatconfig> 80e9297d28Sopenharmony_ci</configuration> 81