1e41f4b71Sopenharmony_ci# Licenses and Special License Review 2e41f4b71Sopenharmony_ci 3e41f4b71Sopenharmony_ci## Purpose 4e41f4b71Sopenharmony_ci 5e41f4b71Sopenharmony_ciThis document lists the acceptable licenses for the code used in the OpenHarmony community. It also describes the review process and rules for special licenses. 6e41f4b71Sopenharmony_ci 7e41f4b71Sopenharmony_ci## Scope 8e41f4b71Sopenharmony_ci 9e41f4b71Sopenharmony_ciThis document applies only to the code distributed in the OpenHarmony community. It does not apply to the scenario where the OpenHarmony project is used by individuals or enterprises to develop new products, or the scenario where third-party open-source software is distributed independently 10e41f4b71Sopenharmony_ci 11e41f4b71Sopenharmony_ci## Definition 12e41f4b71Sopenharmony_ci 13e41f4b71Sopenharmony_ciOpenHarmony is an open-source project launched by the OpenAtom Foundation. The purpose of this project is to build an open, distributed operating system (OS) framework for smart IoT devices in the full-scenario, full-connectivity, and full-intelligence era. 14e41f4b71Sopenharmony_ci 15e41f4b71Sopenharmony_ciThe OpenHarmony project is hosted on the website https://gitee.com/openharmony. 16e41f4b71Sopenharmony_ci 17e41f4b71Sopenharmony_ciCode contributed: A contributor commits copyrighted code to the OpenHarmony project, and the project further distributes the code on the hosted website. 18e41f4b71Sopenharmony_ci 19e41f4b71Sopenharmony_ciThird-party dependency: A third-party open source code that the OpenHarmony project depends. It will be further distributed by the project on the hosted address. 20e41f4b71Sopenharmony_ci 21e41f4b71Sopenharmony_ci## License Trustlist for Code Contributed 22e41f4b71Sopenharmony_ci 23e41f4b71Sopenharmony_ciIn principle, the code contributed to the OpenHarmony project must be source code, and its distribution must be carried out under an open source license approved by the Open Source Initiative (OSI). 24e41f4b71Sopenharmony_ci 25e41f4b71Sopenharmony_ciIt is recommended that the code contributed to the OpenHarmony project be distributed using a license in the license trustlist, which includes: 26e41f4b71Sopenharmony_ci 27e41f4b71Sopenharmony_ci- Apache License 2.0 (Apache-2.0) (applicable to user-mode code) 28e41f4b71Sopenharmony_ci- 3-clause BSD License (BSD-3-Clause) (applicable to LiteOS kernel code) 29e41f4b71Sopenharmony_ci- GNU General Public License version 2 (GPL-2.0) (applicable to Linux kernel code) 30e41f4b71Sopenharmony_ci 31e41f4b71Sopenharmony_ci## Licenses for Third-Party Dependencies 32e41f4b71Sopenharmony_ci 33e41f4b71Sopenharmony_ciIn addition to the code contributed, the OpenHarmony project may introduce or depend on third-party open source software, which uses a variety of licenses. To ensure the open source attributes, the dependent third-party open source software must have clearly defined upstream open source communities, and the introduction of the third-party open source software does not cause legal issues related to license compatibility. 34e41f4b71Sopenharmony_ci 35e41f4b71Sopenharmony_ci### Licenses for Acceptable Third-Party Dependencies 36e41f4b71Sopenharmony_ci 37e41f4b71Sopenharmony_ciLicenses compatible with Apache License 2.0 can be accepted. The OpenHarmony project recommends that third-party dependencies using the following licenses be preferentially accepted: 38e41f4b71Sopenharmony_ci 39e41f4b71Sopenharmony_ci- Academic Free License 3.0 (AFL-3.0) 40e41f4b71Sopenharmony_ci 41e41f4b71Sopenharmony_ci- Apache License 2.0 (Apache-2.0) 42e41f4b71Sopenharmony_ci 43e41f4b71Sopenharmony_ci- Apache Software License 1.1. Including variants: 44e41f4b71Sopenharmony_ci 45e41f4b71Sopenharmony_ci - PHP License 3.01 46e41f4b71Sopenharmony_ci - MX4J License 47e41f4b71Sopenharmony_ci 48e41f4b71Sopenharmony_ci- Boost Software License (BSL-1.0) 49e41f4b71Sopenharmony_ci 50e41f4b71Sopenharmony_ci- BSD License: 51e41f4b71Sopenharmony_ci 52e41f4b71Sopenharmony_ci - 3-clause BSD License 53e41f4b71Sopenharmony_ci - 2-clause BSD License 54e41f4b71Sopenharmony_ci - DOM4J License 55e41f4b71Sopenharmony_ci - PostgreSQL License 56e41f4b71Sopenharmony_ci 57e41f4b71Sopenharmony_ci- ISC 58e41f4b71Sopenharmony_ci 59e41f4b71Sopenharmony_ci- ICU 60e41f4b71Sopenharmony_ci 61e41f4b71Sopenharmony_ci- MIT License (MIT) / X11 62e41f4b71Sopenharmony_ci 63e41f4b71Sopenharmony_ci- MIT No Attribution License (MIT-0) 64e41f4b71Sopenharmony_ci 65e41f4b71Sopenharmony_ci- Mulan Permissive Software License v2 (MulanPSL-2.0) 66e41f4b71Sopenharmony_ci 67e41f4b71Sopenharmony_ci- The Unlicense 68e41f4b71Sopenharmony_ci 69e41f4b71Sopenharmony_ci- W3C License (W3C) 70e41f4b71Sopenharmony_ci 71e41f4b71Sopenharmony_ci- University of Illinois/NCSA 72e41f4b71Sopenharmony_ci 73e41f4b71Sopenharmony_ci- X.Net 74e41f4b71Sopenharmony_ci 75e41f4b71Sopenharmony_ci- zlib/libpng 76e41f4b71Sopenharmony_ci 77e41f4b71Sopenharmony_ci- FSF autoconf license 78e41f4b71Sopenharmony_ci 79e41f4b71Sopenharmony_ci- DejaVu Fonts (Bitstream Vera/Arev licenses) 80e41f4b71Sopenharmony_ci 81e41f4b71Sopenharmony_ci- OOXML XSD ECMA License 82e41f4b71Sopenharmony_ci 83e41f4b71Sopenharmony_ci- Microsoft Public License (MsPL) 84e41f4b71Sopenharmony_ci 85e41f4b71Sopenharmony_ci- Python Software Foundation License 86e41f4b71Sopenharmony_ci 87e41f4b71Sopenharmony_ci- Python Imaging Library Software License 88e41f4b71Sopenharmony_ci 89e41f4b71Sopenharmony_ci- Adobe Postcript(R) AFM files 90e41f4b71Sopenharmony_ci 91e41f4b71Sopenharmony_ci- Boost Software License Version 1.0 92e41f4b71Sopenharmony_ci 93e41f4b71Sopenharmony_ci- WTF Public License 94e41f4b71Sopenharmony_ci 95e41f4b71Sopenharmony_ci- The Romantic WTF public license 96e41f4b71Sopenharmony_ci 97e41f4b71Sopenharmony_ci- UNICODE, INC. LICENSE AGREEMENT - DATA FILES AND SOFTWARE 98e41f4b71Sopenharmony_ci 99e41f4b71Sopenharmony_ci- Zope Public License 2.0 100e41f4b71Sopenharmony_ci 101e41f4b71Sopenharmony_ci- ACE license 102e41f4b71Sopenharmony_ci 103e41f4b71Sopenharmony_ci- Oracle Universal Permissive License (UPL) Version 1.0 104e41f4b71Sopenharmony_ci 105e41f4b71Sopenharmony_ci- Open Grid Forum License 106e41f4b71Sopenharmony_ci 107e41f4b71Sopenharmony_ci- Google "Additional IP Rights Grant (Patents)" file 108e41f4b71Sopenharmony_ci 109e41f4b71Sopenharmony_ci- Historical Permission Notice and Disclaimer 110e41f4b71Sopenharmony_ci 111e41f4b71Sopenharmony_ci### Licenses for Unacceptable Third-Party Dependencies 112e41f4b71Sopenharmony_ci 113e41f4b71Sopenharmony_ciIn principle, the OpenHarmony project will not accept third-party dependencies that use the following licenses, since these licenses do not support commercial use or contain unreasonable restrictions or obligations: 114e41f4b71Sopenharmony_ci 115e41f4b71Sopenharmony_ci- Intel Simplified Software License 116e41f4b71Sopenharmony_ci- JSR-275 License 117e41f4b71Sopenharmony_ci- Microsoft Limited Public License 118e41f4b71Sopenharmony_ci- Amazon Software License (ASL) 119e41f4b71Sopenharmony_ci- Java SDK for Satori RTM license 120e41f4b71Sopenharmony_ci- Redis Source Available License (RSAL) 121e41f4b71Sopenharmony_ci- Booz Allen Public License 122e41f4b71Sopenharmony_ci- Confluent Community License Version 1.0 123e41f4b71Sopenharmony_ci- Any license including the Commons Clause License Condition v1.0 124e41f4b71Sopenharmony_ci- Creative Commons Non-Commercial variants 125e41f4b71Sopenharmony_ci- Sun Community Source License 3.0 126e41f4b71Sopenharmony_ci- GNU GPL 3 127e41f4b71Sopenharmony_ci- GNU Affero GPL 3 128e41f4b71Sopenharmony_ci- BSD-4-Clause/BSD-4-Clause (University of California-Specific) 129e41f4b71Sopenharmony_ci- Facebook BSD+Patents license 130e41f4b71Sopenharmony_ci- NPL 1.0/NPL 1.1 131e41f4b71Sopenharmony_ci- The Solipsistic Eclipse Public License 132e41f4b71Sopenharmony_ci- The "Don't Be A Dick" Public License 133e41f4b71Sopenharmony_ci- JSON License 134e41f4b71Sopenharmony_ci 135e41f4b71Sopenharmony_ci## Rules for Introducing Special Licenses 136e41f4b71Sopenharmony_ci 137e41f4b71Sopenharmony_ciThe OpenHarmony project accepts code contributed and third-party dependencies that use a license in their respective license trustlist. To accept the code or third-party dependency that uses a special license (a license not in the trustlist), a special license review must be carried out by the OpenHarmony project and related rules must be complied with. 138e41f4b71Sopenharmony_ci 139e41f4b71Sopenharmony_ci### Special License Review Process 140e41f4b71Sopenharmony_ci 141e41f4b71Sopenharmony_ci#### Organizing a Special License Review 142e41f4b71Sopenharmony_ci 143e41f4b71Sopenharmony_ciThe OpenHarmony compliance SIG is responsible for organizing the special license review. At least the PMC representative, legal affairs representative, and compliance SIG representative are required to participate in the review. 144e41f4b71Sopenharmony_ci 145e41f4b71Sopenharmony_ci#### Triggering a Special License Review 146e41f4b71Sopenharmony_ci 147e41f4b71Sopenharmony_ciIf your software module or code plans to use a special license, proactively provide a review request to the compliance SIG. 148e41f4b71Sopenharmony_ci 149e41f4b71Sopenharmony_ciThe review request must include at least the following information: software module name, service scenario description, names of involved special licenses and related information (licenses used for direct and indirect dependencies in the third-party dependency introduction scenario), and code check reports (such as OAT scanning reports) provided by the license compliance scanning tool. 150e41f4b71Sopenharmony_ci 151e41f4b71Sopenharmony_ciThe compliance SIG regularly summarizes the gated check-in results, obtains the software modules that use special licenses, and organizes reviews. 152e41f4b71Sopenharmony_ci 153e41f4b71Sopenharmony_ciBased on the tool check results, the compliance SIG can organize a special license review if it finds that the code will use a special license (a non-trustlist license is used for a third-party dependency, a dedicated license is used for the code contributed, or only binary code or object code is provided). 154e41f4b71Sopenharmony_ci 155e41f4b71Sopenharmony_ci#### Conclusion of Special License Review 156e41f4b71Sopenharmony_ci 157e41f4b71Sopenharmony_ciFor software modules that use special licenses in the OpenHarmony project, passing the special license review is a prerequisite for theirs code compliance check, and the review conclusion is a prerequisite for the exit review/incubation graduation review carried out by the OpenHarmony QA SIG. Software modules that fail the special license review cannot be incorporated into the OpenHarmony trunk. 158e41f4b71Sopenharmony_ci 159e41f4b71Sopenharmony_ci### Special License Review Rules 160e41f4b71Sopenharmony_ci 161e41f4b71Sopenharmony_ci- **Rule 1**: Apache License 2.0 is preferred for user-mode code to ensure license normalization. If a license other than Apache License 2.0 is used, a proper reason is required. If a special license is required for user-mode code, a license with open source obligations should be avoided. 162e41f4b71Sopenharmony_ci 163e41f4b71Sopenharmony_ci- **Rule 2**: The special licenses used by the code contributed or third-party dependencies should meet the basic distribution and compatibility principles of the open source licenses. That is, the special licenses should support downstream users to distribute related code, and they should not be incompatible with the licenses used by the existing code in the project. 164e41f4b71Sopenharmony_ci 165e41f4b71Sopenharmony_ci- **Rule 3**: The special licenses used by the code contributed or third-party dependencies should not contain unreasonable restrictions (such as commercial restrictions, domain restrictions, discrimination against special technical domains, or product-specific restrictions) or open source license obligations that cannot be fulfilled or are difficult to fulfill. 166e41f4b71Sopenharmony_ci 167e41f4b71Sopenharmony_ci- **Rule 4**: The introduction of third-party dependencies should not affect or change the existing licenses of the related code. 168e41f4b71Sopenharmony_ci 169e41f4b71Sopenharmony_ci- **Rule 5**: The non-source code (binary code or object code), if involved, should use an open source license and meet the preceding rules. The use of a self-prepared license should be approved by the PMC and further reviewed and approved by the OpenHarmony legal compliance team. (In principle, only special licenses for algorithms and special implementation related to necessary hardware, such as GPU, Wi-Fi firmware, and hardware codec algorithms, can be accepted.) 170