diff --git a/etc/scripts/licenses/buildrules.py b/etc/scripts/licenses/buildrules.py index 5b4dd4c1e71..b180a0a15c2 100644 --- a/etc/scripts/licenses/buildrules.py +++ b/etc/scripts/licenses/buildrules.py @@ -143,14 +143,22 @@ def rule_exists(text): return match.rule.identifier -def all_rule_tokens(): +def all_rule_by_tokens(): """ - Return a set of tuples of tokens, one corresponding to every existing and - added rules. Used to avoid duplicates. + Return a mapping of {tuples of tokens: rule id}, with one item for each + existing and added rules. Used to avoid duplicates. """ - rule_tokens = set() + rule_tokens = {} for rule in models.get_rules(): - rule_tokens.add(tuple(rule.tokens())) + try: + rule_tokens[tuple(rule.tokens())] = rule.identifier + except Exception as e: + df=(' file://' + rule.data_file) + tf=(' file://' + rule.text_file) + raise Exception( + f'Failed to to get tokens from rule:: {rule.identifier}\n' + f'{df}\n{tf}' + ) from e return rule_tokens @@ -185,7 +193,7 @@ def cli(licenses_file): """ rules_data = load_data(licenses_file) - rules_tokens = all_rule_tokens() + rule_by_tokens = all_rule_by_tokens() licenses_by_key = cache.get_licenses_db() skinny_rules = [] @@ -205,10 +213,6 @@ def cli(licenses_file): print() for rule in skinny_rules: - existing = rule_exists(rule.text()) - if existing: - print('Skipping existing rule:', existing, 'with text:\n', rule.text()[:50].strip(), '...') - continue if rule.is_false_positive: base_name = 'false-positive' @@ -217,6 +221,21 @@ def cli(licenses_file): else: base_name = rule.license_expression + text = rule.text() + + existing_rule = rule_exists(text) + skinny_text = ' '.join(text[:80].split()) + + existing_msg = ( + f'Skipping rule for: {base_name!r}, ' + 'dupe of: {existing_rule} ' + f'with text: {skinny_text!r}...' + ) + + if existing_rule: + print(existing_msg.format(**locals())) + continue + base_loc = find_rule_base_loc(base_name) rd = rule.to_dict() @@ -234,17 +253,20 @@ def cli(licenses_file): rule_tokens = tuple(rulerec.tokens()) - if rule_tokens in rules_tokens: - print('Skipping already added rule with text for:', base_name) + existing_rule = rule_by_tokens.get(rule_tokens) + if existing_rule: + print(existing_msg.format(**locals())) + continue else: - print('Adding new rule:') + print(f'Adding new rule: {base_name}') print(' file://' + rulerec.data_file) print(' file://' + rulerec.text_file,) - rules_tokens.add(rule_tokens) rulerec.dump() models.update_ignorables(rulerec, verbose=False) rulerec.dump() + rule_by_tokens[rule_tokens] = base_name + if __name__ == '__main__': cli() diff --git a/src/licensedcode/data/licenses/agpl-3.0-plus.yml b/src/licensedcode/data/licenses/agpl-3.0-plus.yml index f3b4ed0f24f..c7a74b4b0e7 100644 --- a/src/licensedcode/data/licenses/agpl-3.0-plus.yml +++ b/src/licensedcode/data/licenses/agpl-3.0-plus.yml @@ -10,6 +10,7 @@ notes: | spdx_license_key: AGPL-3.0-or-later other_spdx_license_keys: - AGPL-3.0+ + - LicenseRef-AGPL text_urls: - http://www.gnu.org/licenses/agpl.txt osi_url: http://www.opensource.org/licenses/agpl-v3.html diff --git a/src/licensedcode/data/licenses/agpl-3.0.yml b/src/licensedcode/data/licenses/agpl-3.0.yml index 3dbf43f786c..e1f97596f58 100644 --- a/src/licensedcode/data/licenses/agpl-3.0.yml +++ b/src/licensedcode/data/licenses/agpl-3.0.yml @@ -10,6 +10,7 @@ notes: | spdx_license_key: AGPL-3.0-only other_spdx_license_keys: - AGPL-3.0 + - LicenseRef-AGPL-3.0 text_urls: - http://www.fsf.org/licensing/licenses/agpl-3.0.html osi_url: http://www.opensource.org/licenses/agpl-v3.html diff --git a/src/licensedcode/data/licenses/agpl-generic-additional-terms.yml b/src/licensedcode/data/licenses/agpl-generic-additional-terms.yml index 62b6f0a2bb0..98d50a4adeb 100644 --- a/src/licensedcode/data/licenses/agpl-generic-additional-terms.yml +++ b/src/licensedcode/data/licenses/agpl-generic-additional-terms.yml @@ -6,4 +6,5 @@ owner: Unspecified notes: this is a generic entry for rare one-off AGPL extra license terms. These are typically additional terms under section 7 of the AGPL-3.0 is_exception: yes +is_generic: yes spdx_license_key: LicenseRef-scancode-agpl-generic-additional-terms diff --git a/src/licensedcode/data/licenses/apache-2.0.yml b/src/licensedcode/data/licenses/apache-2.0.yml index f62434bb7e9..89a8ad2b424 100644 --- a/src/licensedcode/data/licenses/apache-2.0.yml +++ b/src/licensedcode/data/licenses/apache-2.0.yml @@ -8,6 +8,9 @@ notes: | Per SPDX.org, this version was released January 2004 This license is OSI certified spdx_license_key: Apache-2.0 +other_spdx_license_keys: + - LicenseRef-Apache + - LicenseRef-Apache-2.0 osi_license_key: Apache-2.0 text_urls: - http://www.apache.org/licenses/LICENSE-2.0 diff --git a/src/licensedcode/data/licenses/commercial-license.yml b/src/licensedcode/data/licenses/commercial-license.yml index 57ef508cc2b..e1e89da36ee 100644 --- a/src/licensedcode/data/licenses/commercial-license.yml +++ b/src/licensedcode/data/licenses/commercial-license.yml @@ -3,4 +3,6 @@ short_name: Commercial License name: Commercial License category: Commercial owner: Unspecified +is_generic: yes +notes: this is a generic commercial license spdx_license_key: LicenseRef-scancode-commercial-license diff --git a/src/licensedcode/data/licenses/commercial-option.yml b/src/licensedcode/data/licenses/commercial-option.yml index b7d4f9ed834..b5127b09972 100644 --- a/src/licensedcode/data/licenses/commercial-option.yml +++ b/src/licensedcode/data/licenses/commercial-option.yml @@ -4,4 +4,5 @@ short_name: Commercial Option name: Commercial Option category: Commercial owner: Unspecified +is_generic: yes notes: replaced by commercial-license diff --git a/src/licensedcode/data/licenses/generic-cla.yml b/src/licensedcode/data/licenses/generic-cla.yml index a8dc28040ee..14b1e3d41b8 100644 --- a/src/licensedcode/data/licenses/generic-cla.yml +++ b/src/licensedcode/data/licenses/generic-cla.yml @@ -1,4 +1,5 @@ key: generic-cla +is_generic: yes short_name: Generic CLA name: Prior Generic Contributor License Agreement category: Unstated License diff --git a/src/licensedcode/data/licenses/generic-exception.yml b/src/licensedcode/data/licenses/generic-exception.yml index ca91c46e2db..1fc23e82f8f 100644 --- a/src/licensedcode/data/licenses/generic-exception.yml +++ b/src/licensedcode/data/licenses/generic-exception.yml @@ -6,4 +6,5 @@ owner: Unspecified notes: this is a generic license exception notice. Actual terms are most commonly related to rare, one-off extra permission to the A/L/GPL licenses is_exception: yes +is_generic: yes spdx_license_key: LicenseRef-scancode-generic-exception diff --git a/src/licensedcode/data/licenses/generic-export-compliance.yml b/src/licensedcode/data/licenses/generic-export-compliance.yml index fce2fb35fa2..e07c11765ba 100644 --- a/src/licensedcode/data/licenses/generic-export-compliance.yml +++ b/src/licensedcode/data/licenses/generic-export-compliance.yml @@ -5,4 +5,5 @@ category: Unstated License owner: Unspecified notes: this is a generic export compliance notice. Actual terms are most commonly related to cryptography +is_generic: yes spdx_license_key: LicenseRef-scancode-generic-export-compliance diff --git a/src/licensedcode/data/licenses/generic-tos.yml b/src/licensedcode/data/licenses/generic-tos.yml index 6adfc0d1de4..692c0c57658 100644 --- a/src/licensedcode/data/licenses/generic-tos.yml +++ b/src/licensedcode/data/licenses/generic-tos.yml @@ -5,4 +5,5 @@ category: Unstated License owner: Unspecified notes: this is a generic license for Terms of Service such as aprivary terms and and other ToS-like agreement found in software but that are not directly licenses. +is_generic: yes spdx_license_key: LicenseRef-scancode-generic-tos diff --git a/src/licensedcode/data/licenses/generic-trademark.yml b/src/licensedcode/data/licenses/generic-trademark.yml index e7d50167c4c..6f45c418cc9 100644 --- a/src/licensedcode/data/licenses/generic-trademark.yml +++ b/src/licensedcode/data/licenses/generic-trademark.yml @@ -6,6 +6,7 @@ owner: Unspecified notes: this is a generic export Trademark and name realted notice. Actual terms are most commonly related to name use restrictions and no endorsement. This should be used only for rare one-off notices. +is_generic: yes spdx_license_key: LicenseRef-scancode-generic-trademark other_spdx_license_keys: - LicenseRef-scancode-trademark-notice diff --git a/src/licensedcode/data/licenses/gpl-1.0-plus.yml b/src/licensedcode/data/licenses/gpl-1.0-plus.yml index 91f3c1a455f..4eb988723f4 100644 --- a/src/licensedcode/data/licenses/gpl-1.0-plus.yml +++ b/src/licensedcode/data/licenses/gpl-1.0-plus.yml @@ -8,6 +8,7 @@ notes: Per SPDX.org, this license was released February 1989. spdx_license_key: GPL-1.0-or-later other_spdx_license_keys: - GPL-1.0+ + - LicenseRef-GPL text_urls: - http://www.gnu.org/licenses/old-licenses/gpl-1.0-standalone.html other_urls: diff --git a/src/licensedcode/data/licenses/gpl-2.0.yml b/src/licensedcode/data/licenses/gpl-2.0.yml index d4b771db000..42ed20f6420 100644 --- a/src/licensedcode/data/licenses/gpl-2.0.yml +++ b/src/licensedcode/data/licenses/gpl-2.0.yml @@ -22,6 +22,7 @@ spdx_license_key: GPL-2.0-only other_spdx_license_keys: - GPL-2.0 - GPL 2.0 + - LicenseRef-GPL-2.0 text_urls: - http://www.gnu.org/licenses/gpl-2.0.txt - http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt diff --git a/src/licensedcode/data/licenses/gpl-3.0-plus.yml b/src/licensedcode/data/licenses/gpl-3.0-plus.yml index 9589d019c4b..0ba8411ada4 100644 --- a/src/licensedcode/data/licenses/gpl-3.0-plus.yml +++ b/src/licensedcode/data/licenses/gpl-3.0-plus.yml @@ -10,6 +10,7 @@ notes: | spdx_license_key: GPL-3.0-or-later other_spdx_license_keys: - GPL-3.0+ + - LicenseRef-GPL-3.0-or-later text_urls: - http://www.gnu.org/licenses/gpl-3.0-standalone.html other_urls: diff --git a/src/licensedcode/data/licenses/gpl-3.0.yml b/src/licensedcode/data/licenses/gpl-3.0.yml index b6fd0b90446..42ac548e1cf 100644 --- a/src/licensedcode/data/licenses/gpl-3.0.yml +++ b/src/licensedcode/data/licenses/gpl-3.0.yml @@ -10,6 +10,7 @@ notes: | spdx_license_key: GPL-3.0-only other_spdx_license_keys: - GPL-3.0 + - LicenseRef-gpl-3.0 text_urls: - http://www.gnu.org/licenses/gpl-3.0-standalone.html - http://www.gnu.org/licenses/gpl-3.0.txt diff --git a/src/licensedcode/data/licenses/gpl-generic-additional-terms.yml b/src/licensedcode/data/licenses/gpl-generic-additional-terms.yml index 80f3ea8cb66..c66f92afeca 100644 --- a/src/licensedcode/data/licenses/gpl-generic-additional-terms.yml +++ b/src/licensedcode/data/licenses/gpl-generic-additional-terms.yml @@ -6,4 +6,5 @@ owner: Unspecified notes: this is a generic entry for rare one-off GPL extra license terms. These are typically additional terms under section 7 of the GPL-3.0 is_exception: yes +is_generic: yes spdx_license_key: LicenseRef-scancode-gpl-generic-additional-terms diff --git a/src/licensedcode/data/licenses/hippocratic-3.0.LICENSE b/src/licensedcode/data/licenses/hippocratic-3.0.LICENSE new file mode 100644 index 00000000000..084285c6d14 --- /dev/null +++ b/src/licensedcode/data/licenses/hippocratic-3.0.LICENSE @@ -0,0 +1,233 @@ +HIPPOCRATIC LICENSE + +Version 3.0, October 2021 + +*\Hyperlink* + +TERMS AND CONDITIONS + +TERMS AND CONDITIONS FOR USE, COPY, MODIFICATION, PREPARATION OF DERIVATIVE WORK, REPRODUCTION, AND DISTRIBUTION: + + +* DEFINITIONS: + + +This section defines certain terms used throughout this license agreement. + +1.1. "License” means the terms and conditions, as stated herein, for use, copy, modification, preparation of derivative work, reproduction, and distribution of Software (as defined below). + +1.2. "Licensor” means the copyright and/or patent owner or entity authorized by the copyright and/or patent owner that is granting the License. + +1.3. "Licensee” means the individual or entity exercising permissions granted by this License, including the use, copy, modification, preparation of derivative work, reproduction, and distribution of Software (as defined below). + +1.4. "Software” means any copyrighted work, including but not limited to software code, authored by Licensor and made available under this License. + +1.5. "Supply Chain” means the sequence of processes involved in the production and/or distribution of a commodity, good, or service offered by the Licensee. + +1.6. "Supply Chain Impacted Party” or "Supply Chain Impacted Parties” means any person(s) directly impacted by any of Licensee’s Supply Chain, including the practices of all persons or entities within the Supply Chain prior to a good or service reaching the Licensee. + +1.7. "Duty of Care” is defined by its use in tort law, delict law, and/or similar bodies of law closely related to tort and/or delict law, including without limitation, a requirement to act with the watchfulness, attention, caution, and prudence that a reasonable person in the same or similar circumstances would use towards any Supply Chain Impacted Party. + +1.8. "Worker” is defined to include any and all permanent, temporary, and agency workers, as well as piece-rate, salaried, hourly paid, legal young (minors), part-time, night, and migrant workers. + + +* INTELLECTUAL PROPERTY GRANTS: + + +This section identifies intellectual property rights granted to a Licensee. + +2.1. Grant of Copyright License: Subject to the terms and conditions of this License, Licensor hereby grants to Licensee a worldwide, non-exclusive, no-charge, royalty-free copyright license to use, copy, modify, prepare derivative work, reproduce, or distribute the Software, Licensor authored modified software, or other work derived from the Software. + +2.2 Grant of Patent License: Subject to the terms and conditions of this License, Licensor hereby grants Licensee a worldwide, non-exclusive, no-charge, royalty-free patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer Software. + + +* ETHICAL STANDARDS: + + +This section lists conditions the Licensee must comply with in order to have rights under this License. + +The rights granted to the Licensee by this License are expressly made subject to the Licensee’s ongoing compliance with the following conditions: + +3.1. The Licensee SHALL NOT, whether directly or indirectly, through agents or assigns: + +3.1.1. Infringe upon any person's right to life or security of person, engage in extrajudicial killings, or commit murder, without lawful cause +(See Article 3, *United Nations Universal Declaration of Human Rights*; Article 6, *International Covenant on Civil and Political Rights*) + +3.1.2. Hold any person in slavery, servitude, or forced labor +(See Article 4, *United Nations Universal Declaration of Human Rights*; Article 8, *International Covenant on Civil and Political Rights*); + +3.1.3. Contribute to the institution of slavery, slave trading, forced labor, or unlawful child labor +(See Article 4, *United Nations Universal Declaration of Human Rights*; Article 8, *International Covenant on Civil and Political Rights*); + +3.1.4. Torture or subject any person to cruel, inhumane, or degrading treatment or punishment +(See Article 5, *United Nations Universal Declaration of Human Rights*; Article 7, *International Covenant on Civil and Political Rights*); + +3.1.5. Discriminate on the basis of sex, gender, sexual orientation, race, ethnicity, nationality, religion, caste, age, medical disability or impairment, and/or any other like circumstances +(See Article 7, *United Nations Universal Declaration of Human Rights*; Article 2, *International Covenant on Economic, Social and Cultural Rights*; Article 26, *International Covenant on Civil and Political Rights*); + +3.1.6. Prevent any person from exercising his/her/their right to seek an effective remedy by a competent court or national tribunal (including domestic judicial systems, international courts, arbitration bodies, and other adjudicating bodies) for actions violating the fundamental rights granted to him/her/them by applicable constitutions, applicable laws, or by this License +(See Article 8, *United Nations Universal Declaration of Human Rights*; Articles 9 and 14, *International Covenant on Civil and Political Rights*); + +3.1.7. Subject any person to arbitrary arrest, detention, or exile +(See Article 9, *United Nations Universal Declaration of Human Rights*; Article 9, *International Covenant on Civil and Political Rights*); + +3.1.8. Subject any person to arbitrary interference with a person's privacy, family, home, or correspondence without the express written consent of the person +(See Article 12, *United Nations Universal Declaration of Human Rights*; Article 17, *International Covenant on Civil and Political Rights*); + +3.1.9. Arbitrarily deprive any person of his/her/their property +(See Article 17, *United Nations Universal Declaration of Human Rights*); + +3.1.10. Forcibly remove indigenous peoples from their lands or territories or take any action with the aim or effect of dispossessing indigenous peoples from their lands, territories, or resources, including without limitation the intellectual property or traditional knowledge of indigenous peoples, without the free, prior, and informed consent of indigenous peoples concerned +(See Articles 8 and 10, *United Nations Declaration on the Rights of Indigenous Peoples*); + +3.1.11. (Module -- Carbon Underground 200) Be an individual or entity, or a representative, agent, affiliate, successor, attorney, or assign of an individual or entity, on the FFI Solutions Carbon Underground 200 list; + +3.1.12. (Module -- Ecocide) Commit ecocide: + + 3.1.12.1 For the purpose of this section, "ecocide" means unlawful or wanton acts committed with knowledge that there is a substantial likelihood of severe and either widespread or long-term damage to the environment being caused by those acts; + + 3.1.12.2 For the purpose of further defining ecocide and the terms contained in the previous paragraph: + + 3.1.12.2.1. "Wanton" means with reckless disregard for damage which would be clearly excessive in relation to the social and economic benefits anticipated; + + 3.1.12.2.2. "Severe" means damage which involves very serious adverse changes, disruption, or harm to any element of the environment, including grave impacts on human life or natural, cultural, or economic resources; + + 3.1.12.2.3. "Widespread" means damage which extends beyond a limited geographic area, crosses state boundaries, or is suffered by an entire ecosystem or species or a large number of human beings; + + 3.1.12.2.4. "Long-term" means damage which is irreversible or which cannot be redressed through natural recovery within a reasonable period of time; and + + 3.1.12.2.5. "Environment" means the earth, its biosphere, cryosphere, lithosphere, hydrosphere, and atmosphere, as well as outer space + + (See Section II, *Independent Expert Panel for the Legal Definition of Ecocide*, Stop Ecocide Foundation and the Promise Institute for Human Rights at UCLA School of Law, June 2021); + +3.1.13. (Module -- Extractive Industries) Be an individual or entity, or a representative, agent, affiliate, successor, attorney, or assign of an individual or entity, that engages in fossil fuel or mineral exploration, extraction, development, or sale; + +3.1.14. (Module -- BDS) Be an individual or entity, or a representative, agent, affiliate, successor, attorney, or assign of an individual or entity, identified by the Boycott, Divestment, Sanctions ("BDS") movement on its website ([https://bdsmovement.net/](https://bdsmovement.net/) and [https://bdsmovement.net/get-involved/what-to-boycott](https://bdsmovement.net/get-involved/what-to-boycott)) as a target for boycott; + +3.1.15. (Module -- Taliban) Be an individual or entity that: + + 3.1.15.1. engages in any commercial transactions with the Taliban; or + + 3.1.15.2. is a representative, agent, affiliate, successor, attorney, or assign of the Taliban; + +3.1.16. (Module -- Myanmar) Be an individual or entity that: + + 3.1.16.1. engages in any commercial transactions with the Myanmar/Burmese military junta; or + + 3.1.16.2. is a representative, agent, affiliate, successor, attorney, or assign of the Myanmar/Burmese government; + +3.1.17. (Module -- Xinjiang Uygur Autonomous Region) Be an individual or entity, or a representative, agent, affiliate, successor, attorney, or assign of any individual or entity, that does business in, purchases goods from, or otherwise benefits from goods produced in the Xinjiang Uygur Autonomous Region of China; + +3.1.18. (Module -- U.S. Tariff Act) Be an individual or entity: + + 3.1.18.1. which U.S. Customs and Border Protection (CBP) has currently issued a Withhold Release Order (WRO) or finding against based on reasonable suspicion of forced labor; or + + 3.1.18.2. that is a representative, agent, affiliate, successor, attorney, or assign of an individual or entity that does business with an individual or entity which currently has a WRO or finding from CBP issued against it based on reasonable suspicion of forced labor; + +3.1.19. (Module -- Mass Surveillance) Be a government agency or multinational corporation, or a representative, agent, affiliate, successor, attorney, or assign of a government or multinational corporation, which participates in mass surveillance programs; + +3.1.20. (Module -- Military Activities) Be an entity or a representative, agent, affiliate, successor, attorney, or assign of an entity which conducts military activities; + +3.1.21. (Module -- Law Enforcement) Be an individual or entity, or a or a representative, agent, affiliate, successor, attorney, or assign of an individual or entity, that provides good or services to, or otherwise enters into any commercial contracts with, any local, state, or federal law enforcement agency; + +3.1.22. (Module -- Media) Be an individual or entity, or a or a representative, agent, affiliate, successor, attorney, or assign of an individual or entity, that broadcasts messages promoting killing, torture, or other forms of extreme violence; + +3.1.23. Interfere with Workers' free exercise of the right to organize and associate +(See Article 20, United Nations Universal Declaration of Human Rights; C087 - Freedom of Association and Protection of the Right to Organise Convention, 1948 (No. 87), International Labour Organization; Article 8, International Covenant on Economic, Social and Cultural Rights); and + +3.1.24. Harm the environment in a manner inconsistent with local, state, national, or international law. + + +3.2. The Licensee SHALL: + +3.2.1. (Module -- Social Auditing) Only use social auditing mechanisms that adhere to Worker-Driven Social Responsibility Network's Statement of Principles (https://wsr-network.org/what-is-wsr/statement-of-principles/) over traditional social auditing mechanisms, to the extent the Licensee uses any social auditing mechanisms at all; + +3.2.2. (Module -- Workers on Board of Directors) Ensure that if the Licensee has a Board of Directors, 30% of Licensee's board seats are held by Workers paid no more than 200% of the compensation of the lowest paid Worker of the Licensee; + +3.2.3. (Module -- Supply Chain Transparency) Provide clear, accessible supply chain data to the public in accordance with the following conditions: + + 3.2.3.1. All data will be on Licensee's website and/or, to the extent Licensee is a representative, agent, affiliate, successor, attorney, subsidiary, or assign, on Licensee's principal's or parent's website or some other online platform accessible to the public via an internet search on a common internet search engine; and + + 3.2.3.2. Data published will include, where applicable, manufacturers, top tier suppliers, subcontractors, cooperatives, component parts producers, and farms; + +3.2.4. Provide equal pay for equal work where the performance of such work requires equal skill, effort, and responsibility, and which are performed under similar working conditions, except where such payment is made pursuant to: + + 3.2.4.1. A seniority system; + + 3.2.4.2. A merit system; + + 3.2.4.3. A system which measures earnings by quantity or quality of production; or + + 3.2.4.4. A differential based on any other factor other than sex, gender, sexual orientation, race, ethnicity, nationality, religion, caste, age, medical disability or impairment, and/or any other like circumstances + (See 29 U.S.C.A. � 206(d)(1); Article 23, *United Nations Universal Declaration of Human Rights*; Article 7, *International Covenant on Economic, Social and Cultural Rights*; Article 26, *International Covenant on Civil and Political Rights*); and + +3.2.5. Allow for reasonable limitation of working hours and periodic holidays with pay +(See Article 24, *United Nations Universal Declaration of Human Rights*; Article 7, *International Covenant on Economic, Social and Cultural Rights*). + + + +* SUPPLY CHAIN IMPACTED PARTIES: + + +This section identifies additional individuals or entities that a Licensee could harm as a result of violating the Ethical Standards section, the condition that the Licensee must voluntarily accept a Duty of Care for those individuals or entities, and the right to a private right of action that those individuals or entities possess as a result of violations of the Ethical Standards section. + +4.1. In addition to the above Ethical Standards, Licensee voluntarily accepts a Duty of Care for Supply Chain Impacted Parties of this License, including individuals and communities impacted by violations of the Ethical Standards. The Duty of Care is breached when a provision within the Ethical Standards section is violated by a Licensee, one of its successors or assigns, or by an individual or entity that exists within the Supply Chain prior to a good or service reaching the Licensee. + +4.2. Breaches of the Duty of Care, as stated within this section, shall create a private right of action, allowing any Supply Chain Impacted Party harmed by the Licensee to take legal action against the Licensee in accordance with applicable negligence laws, whether they be in tort law, delict law, and/or similar bodies of law closely related to tort and/or delict law, regardless if Licensee is directly responsible for the harms suffered by a Supply Chain Impacted Party. Nothing in this section shall be interpreted to include acts committed by individuals outside of the scope of his/her/their employment. + + + +* NOTICE: +This section explains when a Licensee must notify others of the License. + + +5.1. Distribution of Notice: Licensee must ensure that everyone who receives a copy of or uses any part of Software from Licensee, with or without changes, also receives the License and the copyright notice included with Software (and if included by the Licensor, patent, trademark, and attribution notice). Licensee must ensure that License is prominently displayed so that any individual or entity seeking to download, copy, use, or otherwise receive any part of Software from Licensee is notified of this License and its terms and conditions. Licensee must cause any modified versions of the Software to carry prominent notices stating that Licensee changed the Software. + +5.2. Modified Software: Licensee is free to create modifications of the Software and distribute only the modified portion created by Licensee, however, any derivative work stemming from the Software or its code must be distributed pursuant to this License, including this Notice provision. + +5.3. Recipients as Licensees: Any individual or entity that uses, copies, modifies, reproduces, distributes, or prepares derivative work based upon the Software, all or part of the Software’s code, or a derivative work developed by using the Software, including a portion of its code, is a Licensee as defined above and is subject to the terms and conditions of this License. + + +* REPRESENTATIONS AND WARRANTIES: + + +6.1. Disclaimer of Warranty: TO THE FULL EXTENT ALLOWED BY LAW, THIS SOFTWARE COMES "AS IS,” WITHOUT ANY WARRANTY, EXPRESS OR IMPLIED, AND LICENSOR SHALL NOT BE LIABLE TO ANY PERSON OR ENTITY FOR ANY DAMAGES OR OTHER LIABILITY ARISING FROM, OUT OF, OR IN CONNECTION WITH THE SOFTWARE OR THIS LICENSE, UNDER ANY LEGAL CLAIM. + +6.2. Limitation of Liability: LICENSEE SHALL HOLD LICENSOR HARMLESS AGAINST ANY AND ALL CLAIMS, DEBTS, DUES, LIABILITIES, LIENS, CAUSES OF ACTION, DEMANDS, OBLIGATIONS, DISPUTES, DAMAGES, LOSSES, EXPENSES, ATTORNEYS’ FEES, COSTS, LIABILITIES, AND ALL OTHER CLAIMS OF EVERY KIND AND NATURE WHATSOEVER, WHETHER KNOWN OR UNKNOWN, ANTICIPATED OR UNANTICIPATED, FORESEEN OR UNFORESEEN, ACCRUED OR UNACCRUED, DISCLOSED OR UNDISCLOSED, ARISING OUT OF OR RELATING TO LICENSEE’S USE OF THE SOFTWARE. NOTHING IN THIS SECTION SHOULD BE INTERPRETED TO REQUIRE LICENSEE TO INDEMNIFY LICENSOR, NOR REQUIRE LICENSOR TO INDEMNIFY LICENSEE. + + +* TERMINATION + + +7.1. Violations of Ethical Standards or Breaching Duty of Care: If Licensee violates the Ethical Standards section or Licensee, or any other person or entity within the Supply Chain prior to a good or service reaching the Licensee, breaches its Duty of Care to Supply Chain Impacted Parties, Licensee must remedy the violation or harm caused by Licensee within 30 days of being notified of the violation or harm. If Licensee fails to remedy the violation or harm within 30 days, all rights in the Software granted to Licensee by License will be null and void as between Licensor and Licensee. + +7.2. Failure of Notice: If any person or entity notifies Licensee in writing that Licensee has not complied with the Notice section of this License, Licensee can keep this License by taking all practical steps to comply within 30 days after the notice of noncompliance. If Licensee does not do so, Licensee’s License (and all rights licensed hereunder) will end immediately. + +7.3. Judicial Findings: In the event Licensee is found by a civil, criminal, administrative, or other court of competent jurisdiction, or some other adjudicating body with legal authority, to have committed actions which are in violation of the Ethical Standards or Supply Chain Impacted Party sections of this License, all rights granted to Licensee by this License will terminate immediately. + +7.4. Patent Litigation: If Licensee institutes patent litigation against any entity (including a cross-claim or counterclaim in a suit) alleging that the Software, all or part of the Software’s code, or a derivative work developed using the Software, including a portion of its code, constitutes direct or contributory patent infringement, then any patent license, along with all other rights, granted to Licensee under this License will terminate as of the date such litigation is filed. + +7.5. Additional Remedies: Termination of the License by failing to remedy harms in no way prevents Licensor or Supply Chain Impacted Party from seeking appropriate remedies at law or in equity. + + +* MISCELLANEOUS: + + +8.1. Conditions: Sections 3, 4.1, 5.1, 5.2, 7.1, 7.2, 7.3, and 7.4 are conditions of the rights granted to Licensee in the License. + +8.2. Equitable Relief: Licensor and any Supply Chain Impacted Party shall be entitled to equitable relief, including injunctive relief or specific performance of the terms hereof, in addition to any other remedy to which they are entitled at law or in equity. + +8.3. (Module – Copyleft) Copyleft: Modified software, source code, or other derivative work must be licensed, in its entirety, under the exact same conditions as this License. + +8.4. Severability: If any term or provision of this License is determined to be invalid, illegal, or unenforceable by a court of competent jurisdiction, any such determination of invalidity, illegality, or unenforceability shall not affect any other term or provision of this License or invalidate or render unenforceable such term or provision in any other jurisdiction. If the determination of invalidity, illegality, or unenforceability by a court of competent jurisdiction pertains to the terms or provisions contained in the Ethical Standards section of this License, all rights in the Software granted to Licensee shall be deemed null and void as between Licensor and Licensee. + +8.5. Section Titles: Section titles are solely written for organizational purposes and should not be used to interpret the language within each section. + +8.6. Citations: Citations are solely written to provide context for the source of the provisions in the Ethical Standards. + +8.7. Section Summaries: Some sections have a brief italicized description which is provided for the sole purpose of briefly describing the section and should not be used to interpret the terms of the License. + +8.8. Entire License: This is the entire License between the Licensor and Licensee with respect to the claims released herein and that the consideration stated herein is the only consideration or compensation to be paid or exchanged between them for this License. This License cannot be modified or amended except in a writing signed by Licensor and Licensee. + +8.9. Successors and Assigns: This License shall be binding upon and inure to the benefit of the Licensor’s and Licensee’s respective heirs, successors, and assigns. + diff --git a/src/licensedcode/data/licenses/hippocratic-3.0.yml b/src/licensedcode/data/licenses/hippocratic-3.0.yml new file mode 100644 index 00000000000..bf35182c564 --- /dev/null +++ b/src/licensedcode/data/licenses/hippocratic-3.0.yml @@ -0,0 +1,17 @@ +key: hippocratic-3.0 +short_name: Hippocratic License v3.0 +name: Hippocratic License v3.0 +category: Free Restricted +owner: Ethical Source +homepage_url: https://firstdonoharm.dev/ +spdx_license_key: LicenseRef-scancode-Hippocratic-3.0 +text_urls: + - https://firstdonoharm.dev/version/3/0/license/license.txt + - https://firstdonoharm.dev/version/3/0/license/license.md + - https://firstdonoharm.dev/version/3/0/license/ +faq_url: https://www.un.org/en/universal-declaration-human-rights/ +ignorable_urls: + - https://bdsmovement.net/ + - https://bdsmovement.net/get-involved/what-to-boycott + - https://wsr-network.org/what-is-wsr/statement-of-principles + diff --git a/src/licensedcode/data/licenses/lgpl-2.0-plus.yml b/src/licensedcode/data/licenses/lgpl-2.0-plus.yml index 1d9144ce2f1..989357ed769 100644 --- a/src/licensedcode/data/licenses/lgpl-2.0-plus.yml +++ b/src/licensedcode/data/licenses/lgpl-2.0-plus.yml @@ -10,6 +10,7 @@ notes: | spdx_license_key: LGPL-2.0-or-later other_spdx_license_keys: - LGPL-2.0+ + - LicenseRef-LGPL text_urls: - http://www.gnu.org/licenses/old-licenses/lgpl-2.0-standalone.html other_urls: diff --git a/src/licensedcode/data/licenses/lgpl-2.0.yml b/src/licensedcode/data/licenses/lgpl-2.0.yml index 9f0d3914226..fef11b3ae83 100644 --- a/src/licensedcode/data/licenses/lgpl-2.0.yml +++ b/src/licensedcode/data/licenses/lgpl-2.0.yml @@ -10,6 +10,8 @@ notes: | spdx_license_key: LGPL-2.0-only other_spdx_license_keys: - LGPL-2.0 + - LicenseRef-LGPL-2 + - LicenseRef-LGPL-2.0 text_urls: - http://www.gnu.org/licenses/lgpl-2.0.html - http://www.gnu.org/licenses/lgpl-2.0.txt diff --git a/src/licensedcode/data/licenses/lgpl-2.1.yml b/src/licensedcode/data/licenses/lgpl-2.1.yml index d35054b51f8..d8ac978fab4 100644 --- a/src/licensedcode/data/licenses/lgpl-2.1.yml +++ b/src/licensedcode/data/licenses/lgpl-2.1.yml @@ -10,6 +10,7 @@ notes: | spdx_license_key: LGPL-2.1-only other_spdx_license_keys: - LGPL-2.1 + - LicenseRef-LGPL-2.1 text_urls: - http://www.gnu.org/licenses/lgpl-2.1.txt osi_url: http://opensource.org/licenses/lgpl-2.1.php diff --git a/src/licensedcode/data/licenses/openjdk-exception.yml b/src/licensedcode/data/licenses/openjdk-exception.yml index 4d804a1e91c..400f1c38708 100644 --- a/src/licensedcode/data/licenses/openjdk-exception.yml +++ b/src/licensedcode/data/licenses/openjdk-exception.yml @@ -9,6 +9,8 @@ notes: | terms and found only in the OpenJDK is_exception: yes spdx_license_key: LicenseRef-scancode-openjdk-exception +other_spdx_license_keys: + - Assembly-exception text_urls: - http://openjdk.java.net/legal/gplv2+ce.html - http://openjdk.java.net/legal/assembly-exception.html diff --git a/src/licensedcode/data/licenses/other-copyleft.yml b/src/licensedcode/data/licenses/other-copyleft.yml index bb95634795a..cf559c4e561 100644 --- a/src/licensedcode/data/licenses/other-copyleft.yml +++ b/src/licensedcode/data/licenses/other-copyleft.yml @@ -6,4 +6,5 @@ owner: nexB notes: | this is a catch all and ellipsis to deal with some cases when a large number of ancillary yet similar licenses may be reported as one. +is_generic: yes spdx_license_key: LicenseRef-scancode-other-copyleft diff --git a/src/licensedcode/data/licenses/other-permissive.yml b/src/licensedcode/data/licenses/other-permissive.yml index 226e8e3b8f6..a425db91f9e 100644 --- a/src/licensedcode/data/licenses/other-permissive.yml +++ b/src/licensedcode/data/licenses/other-permissive.yml @@ -6,4 +6,5 @@ owner: nexB notes: | this is a catch all and ellipsis to deal with some cases when a large number of ancillary yet similar licenses may be reported as one. +is_generic: yes spdx_license_key: LicenseRef-scancode-other-permissive diff --git a/src/licensedcode/data/licenses/proprietary-license.yml b/src/licensedcode/data/licenses/proprietary-license.yml index c1bfdeb07e5..429504eef9a 100644 --- a/src/licensedcode/data/licenses/proprietary-license.yml +++ b/src/licensedcode/data/licenses/proprietary-license.yml @@ -4,4 +4,5 @@ name: Proprietary License category: Commercial owner: Unspecified notes: replaces the proprietary key +is_generic: yes spdx_license_key: LicenseRef-scancode-proprietary-license diff --git a/src/licensedcode/data/licenses/proprietary.yml b/src/licensedcode/data/licenses/proprietary.yml index 2b769a24035..a03841e9c57 100644 --- a/src/licensedcode/data/licenses/proprietary.yml +++ b/src/licensedcode/data/licenses/proprietary.yml @@ -5,3 +5,4 @@ name: Proprietary category: Proprietary Free owner: Unspecified notes: see proprietary-license instead +is_generic: yes diff --git a/src/licensedcode/data/licenses/public-domain-disclaimer.yml b/src/licensedcode/data/licenses/public-domain-disclaimer.yml index a4208401a21..d71deacfb82 100644 --- a/src/licensedcode/data/licenses/public-domain-disclaimer.yml +++ b/src/licensedcode/data/licenses/public-domain-disclaimer.yml @@ -5,4 +5,6 @@ category: Public Domain owner: Unspecified spdx_license_key: LicenseRef-scancode-public-domain-disclaimer notes: this is used also as a placeholder for similar public domain dedications - texts and notices that come with an additional warranty disclaimer \ No newline at end of file + texts and notices that come with an additional warranty disclaimer +is_generic: yes + \ No newline at end of file diff --git a/src/licensedcode/data/licenses/public-domain.yml b/src/licensedcode/data/licenses/public-domain.yml index 12a5ccaf53d..ec37ed8e4be 100644 --- a/src/licensedcode/data/licenses/public-domain.yml +++ b/src/licensedcode/data/licenses/public-domain.yml @@ -5,6 +5,9 @@ category: Public Domain owner: Unspecified homepage_url: http://www.linfo.org/publicdomain.html spdx_license_key: LicenseRef-scancode-public-domain +other_spdx_license_keys: + - LicenseRef-PublicDomain +is_generic: yes faq_url: http://www.linfo.org/publicdomain.html other_urls: - http://creativecommons.org/licenses/publicdomain/ diff --git a/src/licensedcode/data/licenses/reportbug.yml b/src/licensedcode/data/licenses/reportbug.yml index b58983b3fb7..b2b81ef8f42 100644 --- a/src/licensedcode/data/licenses/reportbug.yml +++ b/src/licensedcode/data/licenses/reportbug.yml @@ -8,3 +8,4 @@ notes: found in Debian reportbug spdx_license_key: LicenseRef-scancode-reportbug text_urls: - https://tracker.debian.org/media/packages/r/reportbug/copyright-6.6.6 +minimum_coverage: 80 diff --git a/src/licensedcode/data/licenses/unpublished-source.yml b/src/licensedcode/data/licenses/unpublished-source.yml index 03972057296..11f457e2985 100644 --- a/src/licensedcode/data/licenses/unpublished-source.yml +++ b/src/licensedcode/data/licenses/unpublished-source.yml @@ -3,4 +3,5 @@ short_name: Unpublished Source License name: Unpublished Source License category: Commercial owner: Unspecified +is_generic: yes spdx_license_key: LicenseRef-scancode-unpublished-source diff --git a/src/licensedcode/data/licenses/us-govt-public-domain.yml b/src/licensedcode/data/licenses/us-govt-public-domain.yml index d9694a2faf9..232d28a6260 100644 --- a/src/licensedcode/data/licenses/us-govt-public-domain.yml +++ b/src/licensedcode/data/licenses/us-govt-public-domain.yml @@ -7,6 +7,7 @@ notes: Per 17 U.S. Code § 105. Subject matter of copyright, United States Go Copyright protection under this title is not available for any work of the United States Government spdx_license_key: LicenseRef-scancode-us-govt-public-domain +is_generic: yes other_urls: - https://www.law.cornell.edu/uscode/text/17/105 - https://en.wikipedia.org/wiki/Copyright_status_of_works_by_the_federal_government_of_the_United_States diff --git a/src/licensedcode/data/licenses/warranty-disclaimer.yml b/src/licensedcode/data/licenses/warranty-disclaimer.yml index 86129370095..1558fd68d82 100644 --- a/src/licensedcode/data/licenses/warranty-disclaimer.yml +++ b/src/licensedcode/data/licenses/warranty-disclaimer.yml @@ -6,4 +6,5 @@ owner: Unspecified notes: | This is a catch all license for plain, generic warranty disclaimers that do not provide much rights. Often seen in Microsoft code. +is_generic: yes spdx_license_key: LicenseRef-scancode-warranty-disclaimer diff --git a/src/licensedcode/data/rules/agpl-3.0-plus_276.RULE b/src/licensedcode/data/rules/agpl-3.0-plus_276.RULE new file mode 100644 index 00000000000..374bf082584 --- /dev/null +++ b/src/licensedcode/data/rules/agpl-3.0-plus_276.RULE @@ -0,0 +1 @@ +- LicenseRef-AGPL \ No newline at end of file diff --git a/src/licensedcode/data/rules/agpl-3.0-plus_276.yml b/src/licensedcode/data/rules/agpl-3.0-plus_276.yml new file mode 100644 index 00000000000..4b19d92b9c7 --- /dev/null +++ b/src/licensedcode/data/rules/agpl-3.0-plus_276.yml @@ -0,0 +1,3 @@ +license_expression: agpl-3.0-plus +is_license_tag: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/agpl-3.0-plus_with_agpl-generic-additional-terms_25.RULE b/src/licensedcode/data/rules/agpl-3.0-plus_with_agpl-generic-additional-terms_25.RULE new file mode 100644 index 00000000000..19cd0001e45 --- /dev/null +++ b/src/licensedcode/data/rules/agpl-3.0-plus_with_agpl-generic-additional-terms_25.RULE @@ -0,0 +1,10 @@ +Additional permission under {{GNU AGPL version 3}} section 7 + +If you modify this program, or any covered work, by linking or +combining it with the OpenSSL project's OpenSSL library (or a +modified version of that library), containing parts covered by the +terms of the OpenSSL or SSLeay licenses, the Free Software Foundation +grants you additional permission to convey the resulting work. +Corresponding Source for a non-source form of such a combination +shall include the source code for the parts of OpenSSL used as well +as that of the covered work. \ No newline at end of file diff --git a/src/licensedcode/data/rules/agpl-3.0-plus_with_agpl-generic-additional-terms_25.yml b/src/licensedcode/data/rules/agpl-3.0-plus_with_agpl-generic-additional-terms_25.yml new file mode 100644 index 00000000000..c1a0716d57e --- /dev/null +++ b/src/licensedcode/data/rules/agpl-3.0-plus_with_agpl-generic-additional-terms_25.yml @@ -0,0 +1,3 @@ +license_expression: agpl-3.0-plus WITH agpl-generic-additional-terms +is_license_notice: yes +notes: Seen in https://github.com/ca4ti/chiaki/blob/android-decoder-ndk-input-thread/LICENSES/AGPL-3.0-only-OpenSSL.txt diff --git a/src/licensedcode/data/rules/agpl-3.0-plus_with_agpl-generic-additional-terms_26.RULE b/src/licensedcode/data/rules/agpl-3.0-plus_with_agpl-generic-additional-terms_26.RULE new file mode 100644 index 00000000000..4aac97bac91 --- /dev/null +++ b/src/licensedcode/data/rules/agpl-3.0-plus_with_agpl-generic-additional-terms_26.RULE @@ -0,0 +1 @@ +SPDX-License-Identifier: LicenseRef-GPL-3.0-or-later-OpenSSL \ No newline at end of file diff --git a/src/licensedcode/data/rules/agpl-3.0-plus_with_agpl-generic-additional-terms_26.yml b/src/licensedcode/data/rules/agpl-3.0-plus_with_agpl-generic-additional-terms_26.yml new file mode 100644 index 00000000000..508e39ea80d --- /dev/null +++ b/src/licensedcode/data/rules/agpl-3.0-plus_with_agpl-generic-additional-terms_26.yml @@ -0,0 +1,4 @@ +license_expression: agpl-3.0-plus WITH agpl-generic-additional-terms +is_license_tag: yes +relevance: 100 +notes: Seen in https://github.com/ca4ti/chiaki/ diff --git a/src/licensedcode/data/rules/agpl-3.0_370.RULE b/src/licensedcode/data/rules/agpl-3.0_370.RULE new file mode 100644 index 00000000000..1085f029460 --- /dev/null +++ b/src/licensedcode/data/rules/agpl-3.0_370.RULE @@ -0,0 +1 @@ +- LicenseRef-AGPL-3.0 \ No newline at end of file diff --git a/src/licensedcode/data/rules/agpl-3.0_370.yml b/src/licensedcode/data/rules/agpl-3.0_370.yml new file mode 100644 index 00000000000..cd076255f67 --- /dev/null +++ b/src/licensedcode/data/rules/agpl-3.0_370.yml @@ -0,0 +1,3 @@ +license_expression: agpl-3.0 +is_license_tag: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/apache-2.0_1059.RULE b/src/licensedcode/data/rules/apache-2.0_1059.RULE new file mode 100644 index 00000000000..22b8f3a72dd --- /dev/null +++ b/src/licensedcode/data/rules/apache-2.0_1059.RULE @@ -0,0 +1,187 @@ +Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. \ No newline at end of file diff --git a/src/licensedcode/data/rules/apache-2.0_1059.yml b/src/licensedcode/data/rules/apache-2.0_1059.yml new file mode 100644 index 00000000000..9c5cd3eeea1 --- /dev/null +++ b/src/licensedcode/data/rules/apache-2.0_1059.yml @@ -0,0 +1,5 @@ +license_expression: apache-2.0 +is_license_text: yes +notes: truncated text +ignorable_urls: + - http://www.apache.org/licenses/ diff --git a/src/licensedcode/data/rules/apache-2.0_1060.RULE b/src/licensedcode/data/rules/apache-2.0_1060.RULE new file mode 100644 index 00000000000..015727a1e2f --- /dev/null +++ b/src/licensedcode/data/rules/apache-2.0_1060.RULE @@ -0,0 +1,7 @@ +Copyrights in the project are retained by their contributors. No +copyright assignment is required to contribute to the project. + +For full authorship information, see the version control history. + +Except as otherwise noted (below and/or in individual files), is +{{licensed under the Apache License, Version 2.0}} . \ No newline at end of file diff --git a/src/licensedcode/data/rules/apache-2.0_1060.yml b/src/licensedcode/data/rules/apache-2.0_1060.yml new file mode 100644 index 00000000000..487153a7721 --- /dev/null +++ b/src/licensedcode/data/rules/apache-2.0_1060.yml @@ -0,0 +1,2 @@ +license_expression: apache-2.0 +is_license_notice: yes diff --git a/src/licensedcode/data/rules/apache-2.0_and_other-permissive_3.RULE b/src/licensedcode/data/rules/apache-2.0_and_other-permissive_3.RULE new file mode 100644 index 00000000000..27745bbad48 --- /dev/null +++ b/src/licensedcode/data/rules/apache-2.0_and_other-permissive_3.RULE @@ -0,0 +1,4 @@ +The Apache HTTP Server includes a number of subcomponents with +separate copyright notices and license terms. Your use of the source +code for the these subcomponents is subject to the terms and +conditions of the following licenses. \ No newline at end of file diff --git a/src/licensedcode/data/rules/apache-2.0_and_other-permissive_3.yml b/src/licensedcode/data/rules/apache-2.0_and_other-permissive_3.yml new file mode 100644 index 00000000000..c7d60238f01 --- /dev/null +++ b/src/licensedcode/data/rules/apache-2.0_and_other-permissive_3.yml @@ -0,0 +1,3 @@ +license_expression: apache-2.0 AND other-permissive +is_license_notice: yes +minimum_coverage: 90 diff --git a/src/licensedcode/data/rules/apache-2.0_and_other-permissive_4.RULE b/src/licensedcode/data/rules/apache-2.0_and_other-permissive_4.RULE new file mode 100644 index 00000000000..b1670fbe066 --- /dev/null +++ b/src/licensedcode/data/rules/apache-2.0_and_other-permissive_4.RULE @@ -0,0 +1,3 @@ +Apache Tomcat includes a number of subcomponents with separate copyright notices +and license terms. Your use of the source code for the these subcomponents is +subject to the terms and conditions of the following licenses. \ No newline at end of file diff --git a/src/licensedcode/data/rules/apache-2.0_and_other-permissive_4.yml b/src/licensedcode/data/rules/apache-2.0_and_other-permissive_4.yml new file mode 100644 index 00000000000..157be8649cc --- /dev/null +++ b/src/licensedcode/data/rules/apache-2.0_and_other-permissive_4.yml @@ -0,0 +1,3 @@ +license_expression: apache-2.0 AND other-permissive +is_license_notice: yes +minimum_coverage: 100 diff --git a/src/licensedcode/data/rules/apache-2.0_or_mit_47.RULE b/src/licensedcode/data/rules/apache-2.0_or_mit_47.RULE index 774fa295f11..98fb571c098 100644 --- a/src/licensedcode/data/rules/apache-2.0_or_mit_47.RULE +++ b/src/licensedcode/data/rules/apache-2.0_or_mit_47.RULE @@ -1,4 +1,4 @@ Except as otherwise noted (below and/or in individual files), is -licensed under the {{Apache License, Version 2.0"" or +licensed under the {{Apache License, Version 2.0}} or or the {{MIT license}} or , {{at your option.}} diff --git a/src/licensedcode/data/rules/bsd-original_80.RULE b/src/licensedcode/data/rules/bsd-original_80.RULE new file mode 100644 index 00000000000..c4417b9e8a8 --- /dev/null +++ b/src/licensedcode/data/rules/bsd-original_80.RULE @@ -0,0 +1,27 @@ +Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + 1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer + in the documentation and/or other materials provided with the + distribution. + 3. All advertising materials mentioning features or use of this + software must display the following acknowledgement: + This product includes software developed by Industries. + 4. The name of Industries may not be used to endorse or + promote products derived from this software without specific prior + written permission. + + THIS SOFTWARE IS PROVIDED BY INDUSTRIES ``AS IS'' AND ANY + EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE INDUSTRIES BE + LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, + EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. \ No newline at end of file diff --git a/src/licensedcode/data/rules/bsd-original_80.yml b/src/licensedcode/data/rules/bsd-original_80.yml new file mode 100644 index 00000000000..8955ceaa750 --- /dev/null +++ b/src/licensedcode/data/rules/bsd-original_80.yml @@ -0,0 +1,2 @@ +license_expression: bsd-original +is_license_text: yes diff --git a/src/licensedcode/data/rules/bsd-simplified_253.RULE b/src/licensedcode/data/rules/bsd-simplified_253.RULE index 62664eeaf5d..b920489ac3e 100644 --- a/src/licensedcode/data/rules/bsd-simplified_253.RULE +++ b/src/licensedcode/data/rules/bsd-simplified_253.RULE @@ -1,2 +1,2 @@ -This `bc` is Free and Open Source Software (FOSS). It is offered under the BSD -2-clause License. Full license text may be found in the [`LICENSE.md`][4] file. \ No newline at end of file +This `bc` is Free and Open Source Software (FOSS). It is offered under the {{BSD +2-clause License}}. Full license text may be found in the [`LICENSE.md`][4] file. diff --git a/src/licensedcode/data/rules/bsd-simplified_and_imlib2_1.RULE b/src/licensedcode/data/rules/bsd-simplified_and_imlib2_1.RULE new file mode 100644 index 00000000000..91465cb968a --- /dev/null +++ b/src/licensedcode/data/rules/bsd-simplified_and_imlib2_1.RULE @@ -0,0 +1 @@ +BSD-2-Clause AND Imlib2 \ No newline at end of file diff --git a/src/licensedcode/data/rules/bsd-simplified_and_imlib2_1.yml b/src/licensedcode/data/rules/bsd-simplified_and_imlib2_1.yml new file mode 100644 index 00000000000..d7fcda03b12 --- /dev/null +++ b/src/licensedcode/data/rules/bsd-simplified_and_imlib2_1.yml @@ -0,0 +1,4 @@ +license_expression: bsd-simplified AND imlib2 +is_license_reference: yes +is_continuous: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/bsd-simplified_and_imlib2_2.RULE b/src/licensedcode/data/rules/bsd-simplified_and_imlib2_2.RULE new file mode 100644 index 00000000000..164b2258d70 --- /dev/null +++ b/src/licensedcode/data/rules/bsd-simplified_and_imlib2_2.RULE @@ -0,0 +1 @@ +LicenseId: BSD-2-Clause AND Imlib2 \ No newline at end of file diff --git a/src/licensedcode/data/rules/bsd-simplified_and_imlib2_2.yml b/src/licensedcode/data/rules/bsd-simplified_and_imlib2_2.yml new file mode 100644 index 00000000000..f11ce077243 --- /dev/null +++ b/src/licensedcode/data/rules/bsd-simplified_and_imlib2_2.yml @@ -0,0 +1,4 @@ +license_expression: bsd-simplified AND imlib2 +is_license_tag: yes +is_continuous: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/bsd-simplified_and_imlib2_3.RULE b/src/licensedcode/data/rules/bsd-simplified_and_imlib2_3.RULE new file mode 100644 index 00000000000..7d3727db11d --- /dev/null +++ b/src/licensedcode/data/rules/bsd-simplified_and_imlib2_3.RULE @@ -0,0 +1 @@ +License: "BSD 2-clause Simplified License and Imlib2 License \ No newline at end of file diff --git a/src/licensedcode/data/rules/bsd-simplified_and_imlib2_3.yml b/src/licensedcode/data/rules/bsd-simplified_and_imlib2_3.yml new file mode 100644 index 00000000000..f11ce077243 --- /dev/null +++ b/src/licensedcode/data/rules/bsd-simplified_and_imlib2_3.yml @@ -0,0 +1,4 @@ +license_expression: bsd-simplified AND imlib2 +is_license_tag: yes +is_continuous: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/cc-by-3.0_14.RULE b/src/licensedcode/data/rules/cc-by-3.0_14.RULE index 6c781d29927..f77ff5867bf 100644 --- a/src/licensedcode/data/rules/cc-by-3.0_14.RULE +++ b/src/licensedcode/data/rules/cc-by-3.0_14.RULE @@ -1,10 +1,10 @@ Except where otherwise noted, third-party content on this site is licensed under a -http://creativecommons.org/licenses/by/3.0/us/ -Creative Commons Attribution 3.0 License +{{ http://creativecommons.org/licenses/by/3.0/us/ }} +{{ Creative Commons Attribution 3.0 License }} Visitors to this website agree to grant a non-exclusive, irrevocable, royalty-free license to the rest of the world for their submissions to http://www.whitehouse.gov/ Whitehouse.gov under the -http://creativecommons.org/licenses/by/3.0/us/ -Creative Commons Attribution 3.0 License \ No newline at end of file +{{ http://creativecommons.org/licenses/by/3.0/us/ }} +{{Creative Commons Attribution 3.0 License}} diff --git a/src/licensedcode/data/rules/cc-by-4.0_url_badge_2.RULE b/src/licensedcode/data/rules/cc-by-4.0_url_badge_2.RULE index 9a142031493..9ed2de92aea 100644 --- a/src/licensedcode/data/rules/cc-by-4.0_url_badge_2.RULE +++ b/src/licensedcode/data/rules/cc-by-4.0_url_badge_2.RULE @@ -1,3 +1,3 @@ -license http://creativecommons.org/licenses/by/4.0/ +license {{ http://creativecommons.org/licenses/by/4.0/ }} Creative Commons License https://i.creativecommons.org/l/by/4.0/88x31.png -This work is licensed under license http://creativecommons.org/licenses/by/4.0/ Creative Commons Attribution 4.0 International License +This work is licensed under license {{ http://creativecommons.org/licenses/by/4.0/ }} {{Creative Commons Attribution 4.0}} International License diff --git a/src/licensedcode/data/rules/commercial-license_64.RULE b/src/licensedcode/data/rules/commercial-license_64.RULE index 47b542d5205..dd545e46b1b 100644 --- a/src/licensedcode/data/rules/commercial-license_64.RULE +++ b/src/licensedcode/data/rules/commercial-license_64.RULE @@ -1,2 +1,2 @@ License -This is commercial software. To use it, you need to agree to the End User License Agreement . If you do not own a commercial license, this file shall be governed by the trial license terms. \ No newline at end of file +This is {{commercial software}}. To use it, you need to {{agree to the End User License Agreement}} . If you {{do not own a commercial license}}, this file shall be governed by the trial license terms. diff --git a/src/licensedcode/data/rules/cpal-1.0_36.RULE b/src/licensedcode/data/rules/cpal-1.0_36.RULE new file mode 100644 index 00000000000..e5b2eb711bd --- /dev/null +++ b/src/licensedcode/data/rules/cpal-1.0_36.RULE @@ -0,0 +1,3 @@ +Graphic Image as provided in the Covered Code. +Display of Attribution Information is required in Larger Works which are defined in the CPAL as a work +which combines Covered Code or portions thereof with code not governed by the terms of the CPAL. \ No newline at end of file diff --git a/src/licensedcode/data/rules/cpal-1.0_36.yml b/src/licensedcode/data/rules/cpal-1.0_36.yml new file mode 100644 index 00000000000..24f13203725 --- /dev/null +++ b/src/licensedcode/data/rules/cpal-1.0_36.yml @@ -0,0 +1,2 @@ +license_expression: cpal-1.0 +is_license_notice: yes diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_1.RULE b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_1.RULE new file mode 100644 index 00000000000..b5b8ae583d0 --- /dev/null +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_1.RULE @@ -0,0 +1,17 @@ +License + +This program and the accompanying materials are made available under the terms of the {{Eclipse Public License 2}} which accompanies this distribution and is available at https://www.eclipse.org/legal/epl-2.0/ or {{the Apache License, Version 2.0}} which accompanies this distribution and is available at https://www.apache.org/licenses/LICENSE-2.0. + +This Source Code may also be made available under the following Secondary Licenses when the conditions for such availability set forth in the {{Eclipse Public License, v. 2.0}} are satisfied: {{GNU General Public License, version 2 with the GNU Classpath Exception}} [1] and {{GNU General Public License, version 2 with the OpenJDK Assembly Exception}} [2]. + +[1] https://www.gnu.org/software/classpath/license.html +[2] http://openjdk.java.net/legal/assembly-exception.html + +{{SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 OR LicenseRef-GPL-2.0 WITH Assembly-exception}} + +If you did not receive this Content directly from the Eclipse Foundation, the Content is +being redistributed by another party ("Redistributor") and different terms and conditions may +apply to your use of any object code in the Content. Check the Redistributor's license that was +provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise +indicated below, the terms and conditions of the EPL still apply to any source code in the Content +and such source code may be obtained at https://www.eclipse.org diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_1.yml b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_1.yml new file mode 100644 index 00000000000..abf5945f896 --- /dev/null +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_1.yml @@ -0,0 +1,9 @@ +license_expression: epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 + WITH openjdk-exception +is_license_notice: yes +ignorable_urls: + - http://openjdk.java.net/legal/assembly-exception.html + - https://www.apache.org/licenses/LICENSE-2.0 + - https://www.eclipse.org/ + - https://www.eclipse.org/legal/epl-2.0/ + - https://www.gnu.org/software/classpath/license.html diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_2.RULE b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_2.RULE new file mode 100644 index 00000000000..3cefae38d26 --- /dev/null +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_2.RULE @@ -0,0 +1,17 @@ +This program and the accompanying materials are made available under the terms of the Eclipse Public License 2 which accompanies this distribution and is available at https://www.eclipse.org/legal/epl-2.0/ or the Apache License, Version 2.0 which accompanies this distribution and is available at https://www.apache.org/licenses/LICENSE-2.0. +

+This Source Code may also be made available under the following Secondary Licenses when the conditions for such availability set forth in the Eclipse Public License, v. 2.0 are satisfied:�GNU General Public License, version 2 with the GNU Classpath Exception [1] and GNU General Public License, version 2 with the OpenJDK Assembly Exception [2]. +

+[1] https://www.gnu.org/software/classpath/license.html +
+[2] http://openjdk.java.net/legal/assembly-exception.html +
+
+SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 OR LicenseRef-GPL-2.0 WITH Assembly-exception + +

If you did not receive this Content directly from the Eclipse Foundation, the Content is +being redistributed by another party ("Redistributor") and different terms and conditions may +apply to your use of any object code in the Content. Check the Redistributor's license that was +provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise +indicated below, the terms and conditions of the EPL still apply to any source code in the Content +and such source code may be obtained at https://www.eclipse.org.

\ No newline at end of file diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_2.yml b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_2.yml new file mode 100644 index 00000000000..abf5945f896 --- /dev/null +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_2.yml @@ -0,0 +1,9 @@ +license_expression: epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 + WITH openjdk-exception +is_license_notice: yes +ignorable_urls: + - http://openjdk.java.net/legal/assembly-exception.html + - https://www.apache.org/licenses/LICENSE-2.0 + - https://www.eclipse.org/ + - https://www.eclipse.org/legal/epl-2.0/ + - https://www.gnu.org/software/classpath/license.html diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_3.RULE b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_3.RULE new file mode 100644 index 00000000000..a3d2f53b644 --- /dev/null +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_3.RULE @@ -0,0 +1,18 @@ +License + +This program and the accompanying materials are made available under the terms of the {{Eclipse Public License 2}} which accompanies this distribution and is available at https://www.eclipse.org/legal/epl-2.0/ or the {{Apache License, Version 2.0}} which accompanies this distribution and is available at https://www.apache.org/licenses/LICENSE-2.0. + +This Source Code may also be made available under the following Secondary Licenses when the conditions for such availability set forth in the {{Eclipse Public License, v. 2.0}} are satisfied {{GNU General Public License, version 2 with the GNU Classpath Exception}} [1] and {{GNU General Public License, version 2 with the OpenJDK Assembly Exception}} [2]. + +[1] https://www.gnu.org/software/classpath/license.html + +[2] http://openjdk.java.net/legal/assembly-exception.html + +{{SPDX-License-Identifier: EPL-2.0 OR Apache-2.0}} + +If you did not receive this Content directly from the Eclipse Foundation, the Content is +being redistributed by another party ("Redistributor") and different terms and conditions may +apply to your use of any object code in the Content. Check the Redistributor's license that was +provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise +indicated below, the terms and conditions of the EPL still apply to any source code in the Content +and such source code may be obtained at https://www.eclipse.org/ https://www.eclipse.org \ No newline at end of file diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_3.yml b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_3.yml new file mode 100644 index 00000000000..abf5945f896 --- /dev/null +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_3.yml @@ -0,0 +1,9 @@ +license_expression: epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 + WITH openjdk-exception +is_license_notice: yes +ignorable_urls: + - http://openjdk.java.net/legal/assembly-exception.html + - https://www.apache.org/licenses/LICENSE-2.0 + - https://www.eclipse.org/ + - https://www.eclipse.org/legal/epl-2.0/ + - https://www.gnu.org/software/classpath/license.html diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_4.RULE b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_4.RULE new file mode 100644 index 00000000000..34fce8def81 --- /dev/null +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_4.RULE @@ -0,0 +1,25 @@ +License + + This program and the accompanying materials are made available under the terms of the +{{Eclipse Public License 2}} which accompanies this distribution and is available at + https://eclipse.org/legal/epl-2.0 https://eclipse.org/legal/epl-2.0 or the +{{Apache License, Version 2.0}} which accompanies this distribution and is available at + https://www.apache.org/licenses/LICENSE-2.0 https://www.apache.org/licenses/LICENSE-2.0 . + + This Source Code may also be made available under the following Secondary Licenses when +the conditions for such availability set forth in the {{Eclipse Public License, v. 2.0}} are +satisfied: {{GNU General Public License, version 2 with the GNU Classpath Exception}} [1] and +{{GNU General Public License, version 2 with the OpenJDK Assembly Exception}} [2]. + + +[1] https://www.gnu.org/software/classpath/license.html https://www.gnu.org/software/classpath/license.html +[2] http://openjdk.java.net/legal/assembly-exception.html http://openjdk.java.net/legal/assembly-exception.html +{{SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 OR LicenseRef-GPL-2.0 WITH Assembly-exception}} + + + If you did not receive this Content directly from the Eclipse Foundation, the Content is being redistributed by +another party ( Redistributor ) and different terms and conditions may apply to your use of any object code in +the Content. Check the Redistributor's license that was provided with the Content. If no such license exists, +contact the Redistributor. Unless otherwise indicated below, the terms and conditions of the {{EPL and Apache +License 2.0}} still apply to any source code in the Content and such source code may be obtained at + https://www.eclipse.org/ https://www.eclipse.org \ No newline at end of file diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_4.yml b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_4.yml new file mode 100644 index 00000000000..ff992d2880f --- /dev/null +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_4.yml @@ -0,0 +1,9 @@ +license_expression: epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 + WITH openjdk-exception +is_license_notice: yes +ignorable_urls: + - http://openjdk.java.net/legal/assembly-exception.html + - https://eclipse.org/legal/epl-2.0 + - https://www.apache.org/licenses/LICENSE-2.0 + - https://www.eclipse.org/ + - https://www.gnu.org/software/classpath/license.html diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_5.RULE b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_5.RULE new file mode 100644 index 00000000000..284af40db98 --- /dev/null +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_5.RULE @@ -0,0 +1 @@ +SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 OR LicenseRef-GPL-2.0 WITH Assembly-exception \ No newline at end of file diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_5.yml b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_5.yml new file mode 100644 index 00000000000..426cc2a48d2 --- /dev/null +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_5.yml @@ -0,0 +1,4 @@ +license_expression: epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 + WITH openjdk-exception +is_license_tag: yes +is_continuous: yes diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_6.RULE b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_6.RULE new file mode 100644 index 00000000000..86ecbf77505 --- /dev/null +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_6.RULE @@ -0,0 +1 @@ +EPL-2.0 OR Apache-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 OR LicenseRef-GPL-2.0 WITH Assembly-exception \ No newline at end of file diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_6.yml b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_6.yml new file mode 100644 index 00000000000..426cc2a48d2 --- /dev/null +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_classpath-exception-2.0_or_gpl-2.0_with_openjdk-exception_6.yml @@ -0,0 +1,4 @@ +license_expression: epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 + WITH openjdk-exception +is_license_tag: yes +is_continuous: yes diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception.RULE b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception.RULE index c36c8d24208..adf33334c75 100644 --- a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception.RULE +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception.RULE @@ -1,14 +1,14 @@ This program and the accompanying materials are made available under the -terms of the Eclipse Public License 2 which accompanies this +terms of the {{Eclipse Public License 2}} which accompanies this distribution and is available at https://www.eclipse.org/legal/epl-2.0/ -or the Apache License, Version 2.0 which accompanies this distribution +or the {{Apache License, Version 2.0}} which accompanies this distribution and is available at https://www.apache.org/licenses/LICENSE-2.0. This Source Code may also be made available under the following Secondary Licenses when the conditions for such availability set forth -in the Eclipse Public License, v. 2.0 are satisfied: GNU General Public -License, version 2 with the GNU Classpath Exception [1] and GNU General -Public License, version 2 with the OpenJDK Assembly Exception [2]. +in the {{Eclipse Public License, v. 2.0}} are satisfied: {{GNU General Public +License, version 2 with the GNU Classpath Exception}} [1] and {{GNU General +Public License, version 2 with the OpenJDK Assembly Exception}} [2]. [1] https://www.gnu.org/software/classpath/license.html [2] http://openjdk.java.net/legal/assembly-exception.html diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception.yml b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception.yml index 93b4310837b..f05a06302ab 100644 --- a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception.yml +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception.yml @@ -1,5 +1,4 @@ -license_expression: epl-2.0 OR apache-2.0 OR (gpl-2.0 WITH classpath-exception-2.0 AND gpl-2.0 - WITH openjdk-exception) +license_expression: epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception is_license_notice: yes ignorable_urls: - http://openjdk.java.net/legal/assembly-exception.html diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception3.yml b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception3.yml index 93b4310837b..f05a06302ab 100644 --- a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception3.yml +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception3.yml @@ -1,5 +1,4 @@ -license_expression: epl-2.0 OR apache-2.0 OR (gpl-2.0 WITH classpath-exception-2.0 AND gpl-2.0 - WITH openjdk-exception) +license_expression: epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception is_license_notice: yes ignorable_urls: - http://openjdk.java.net/legal/assembly-exception.html diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception6.RULE b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception6.RULE index 3211b09c486..ed95555a147 100644 --- a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception6.RULE +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception6.RULE @@ -1,19 +1,19 @@ License This program and the accompanying materials are made available under the terms of the -Eclipse Public License 2 which accompanies this distribution and is available at +{{Eclipse Public License 2}} which accompanies this distribution and is available at "https://eclipse.org/legal/epl-2.0" https://eclipse.org/legal/epl-2.0 or the -Apache License, Version 2.0 which accompanies this distribution and is available at +{{Apache License, Version 2.0}} which accompanies this distribution and is available at "https://www.apache.org/licenses/LICENSE-2.0" https://www.apache.org/licenses/LICENSE-2.0 . This Source Code may also be made available under the following Secondary Licenses when -the conditions for such availability set forth in the Eclipse Public License, v. 2.0 are -satisfied: GNU General Public License, version 2 with the GNU Classpath Exception [1] and -GNU General Public License, version 2 with the OpenJDK Assembly Exception [2]. +the conditions for such availability set forth in the {{Eclipse Public License, v. 2.0}} are +satisfied: {{GNU General Public License, version 2 with the GNU Classpath Exception}} [1] and +{{GNU General Public License, version 2 with the OpenJDK Assembly Exception}} [2]. [1]"https://www.gnu.org/software/classpath/license.html" https://www.gnu.org/software/classpath/license.html [2]"http://openjdk.java.net/legal/assembly-exception.html" http://openjdk.java.net/legal/assembly-exception.html -SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 +{{SPDX-License-Identifier: EPL-2.0 OR Apache-2.0}} If you did not receive this Content directly from the Eclipse Foundation, the Content is being redistributed by another party ("Redistributor") and different terms and conditions may apply to your use of any object code in diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception6.yml b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception6.yml index cb63a0353ae..1156cd34253 100644 --- a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception6.yml +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception6.yml @@ -1,5 +1,4 @@ -license_expression: epl-2.0 OR apache-2.0 OR (gpl-2.0 WITH classpath-exception-2.0 AND gpl-2.0 - WITH openjdk-exception) +license_expression: epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception is_license_notice: yes ignorable_urls: - http://openjdk.java.net/legal/assembly-exception.html diff --git a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception_and_others.yml b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception_and_others.yml index 02212c6c066..7360ed4c588 100644 --- a/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception_and_others.yml +++ b/src/licensedcode/data/rules/epl-2.0_or_apache-2.0_or_gpl-2.0_with_openjdk-exception_and_others.yml @@ -1,5 +1,6 @@ license_expression: (epl-2.0 OR apache-2.0 OR (gpl-2.0 WITH classpath-exception-2.0 AND gpl-2.0 WITH openjdk-exception)) AND bsd-new AND mit AND gpl-3.0-plus WITH autoconf-simple-exception +minimum_coverage: 80 is_license_notice: yes ignorable_urls: - http://openjdk.java.net/legal/assembly-exception.html diff --git a/src/licensedcode/data/rules/free-unknown_47.yml b/src/licensedcode/data/rules/free-unknown_47.yml deleted file mode 100644 index f85198e646d..00000000000 --- a/src/licensedcode/data/rules/free-unknown_47.yml +++ /dev/null @@ -1,3 +0,0 @@ -license_expression: free-unknown -is_license_intro: yes -notes: header in the newlib license notice diff --git a/src/licensedcode/data/rules/free-unknown_50.yml b/src/licensedcode/data/rules/free-unknown_50.yml index 77a621c29ef..75d88af7da4 100644 --- a/src/licensedcode/data/rules/free-unknown_50.yml +++ b/src/licensedcode/data/rules/free-unknown_50.yml @@ -1,3 +1,3 @@ -license_expression: free-unknown +license_expression: other-permissive is_license_notice: yes notes: POSIX man page notice, no license key assigned yet diff --git a/src/licensedcode/data/rules/gcc-exception_1.RULE b/src/licensedcode/data/rules/gcc-exception_1.RULE deleted file mode 100644 index 4bfadd63467..00000000000 --- a/src/licensedcode/data/rules/gcc-exception_1.RULE +++ /dev/null @@ -1,16 +0,0 @@ -/* -In addition to the permissions in the GNU General Public License, the -Free Software Foundation gives you unlimited permission to link the -compiled version of this file into combinations with other programs, -and to distribute those combinations without any restriction coming -from the use of this file. (The General Public License restrictions -do apply in other respects; for example, they cover modification of -the file, and distribution when not linked into a combine -executable.) - - - As a special exception, if you link this library with files compiled with - GCC to produce an executable, this does not cause the resulting executable - to be covered by the GNU General Public License. This exception does not - however invalidate any other reasons why the executable file might be - covered by the GNU General Public License. */ \ No newline at end of file diff --git a/src/licensedcode/data/rules/gcc-exception_1.yml b/src/licensedcode/data/rules/gcc-exception_1.yml deleted file mode 100644 index ed053fc4100..00000000000 --- a/src/licensedcode/data/rules/gcc-exception_1.yml +++ /dev/null @@ -1,4 +0,0 @@ -license_expression: gpl-1.0-plus WITH gcc-compiler-exception-2.0 AND gpl-1.0-plus WITH gcc-linking-exception-2.0 -is_license_notice: yes -notes: even though these exceptions have been typically used with GPLv2 there is no version - referenced in the notices diff --git a/src/licensedcode/data/rules/generic-trademark_4.RULE b/src/licensedcode/data/rules/generic-trademark_4.RULE new file mode 100644 index 00000000000..60512827910 --- /dev/null +++ b/src/licensedcode/data/rules/generic-trademark_4.RULE @@ -0,0 +1,5 @@ +Trademarks +NVIDIA and the NVIDIA logo are trademarks or registered trademarks of +NVIDIA Corporation in the U.S. and other countries. Other company and +product names may be trademarks of the respective companies with which +they are associated. \ No newline at end of file diff --git a/src/licensedcode/data/rules/generic-trademark_4.yml b/src/licensedcode/data/rules/generic-trademark_4.yml new file mode 100644 index 00000000000..0a9376474dd --- /dev/null +++ b/src/licensedcode/data/rules/generic-trademark_4.yml @@ -0,0 +1,2 @@ +license_expression: generic-trademark +is_license_notice: yes diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_449.RULE b/src/licensedcode/data/rules/gpl-1.0-plus_449.RULE index cebeb2a2607..3ddf2207196 100644 --- a/src/licensedcode/data/rules/gpl-1.0-plus_449.RULE +++ b/src/licensedcode/data/rules/gpl-1.0-plus_449.RULE @@ -1,7 +1,7 @@ -On Debian GNU/Linux systems, the complete text of the GNU General -Public License can be found in `/usr/share/common-licenses/GPL'. +On Debian GNU/Linux systems, the {{complete text of the GNU General +Public License can be found in `/usr/share/common-licenses/GPL}}'. - A copy of the GNU General Public License is also available at + A copy of the {{GNU General Public License is also available}} at . You may also obtain it by writing to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_514.RULE b/src/licensedcode/data/rules/gpl-1.0-plus_514.RULE index 7a9a3a85ec7..852c14ea423 100644 --- a/src/licensedcode/data/rules/gpl-1.0-plus_514.RULE +++ b/src/licensedcode/data/rules/gpl-1.0-plus_514.RULE @@ -1,7 +1,7 @@ -On Debian GNU/Linux systems, the complete text of the GNU General -Public License can be found in `/usr/share/common-licenses/GPL'. +On Debian GNU/Linux systems, the complete {{text of the GNU General +Public License can be found in `/usr/share/common-licenses/GPL'}}. - A copy of the GNU General Public License is also available at + A copy of the {{GNU General Public License is also available}} at . You may also obtain it by writing to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_521_1.RULE b/src/licensedcode/data/rules/gpl-1.0-plus_521_1.RULE deleted file mode 100644 index 7a946f24489..00000000000 --- a/src/licensedcode/data/rules/gpl-1.0-plus_521_1.RULE +++ /dev/null @@ -1,2 +0,0 @@ -is licensed under the terms of the GNU General Public -License. diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_521_1.yml b/src/licensedcode/data/rules/gpl-1.0-plus_521_1.yml deleted file mode 100644 index 116c9848025..00000000000 --- a/src/licensedcode/data/rules/gpl-1.0-plus_521_1.yml +++ /dev/null @@ -1,3 +0,0 @@ -license_expression: gpl-1.0-plus -is_license_notice: yes -relevance: 100 diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_8.RULE b/src/licensedcode/data/rules/gpl-1.0-plus_8.RULE index 04d46624b40..987cae79720 100644 --- a/src/licensedcode/data/rules/gpl-1.0-plus_8.RULE +++ b/src/licensedcode/data/rules/gpl-1.0-plus_8.RULE @@ -1 +1 @@ -Licensed under the terms of the GNU General Public License. \ No newline at end of file +{{licensed under the terms of the GNU General Public License.}} diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_gcc_1.RULE b/src/licensedcode/data/rules/gpl-1.0-plus_gcc_1.RULE index 4227c183517..a1ba27a1942 100644 --- a/src/licensedcode/data/rules/gpl-1.0-plus_gcc_1.RULE +++ b/src/licensedcode/data/rules/gpl-1.0-plus_gcc_1.RULE @@ -1,7 +1,7 @@ -In addition to the permissions in the GNU General Public License, the Free -Software Foundation gives you unlimited permission to link the compiled version +{{In addition to the permissions in the GNU General Public License}}, the Free +Software Foundation gives you {{unlimited permission to link the compiled version}} of this file into combinations with other programs, and to distribute those combinations without any restriction coming from the use of this file. (The General Public License restrictions do apply in other respects; for example, they cover modification of the file, and distribution when not linked -into a combine executable.) \ No newline at end of file +into a combine executable.) diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_ada-linking-exception_1.RULE b/src/licensedcode/data/rules/gpl-1.0-plus_with_ada-linking-exception_1.RULE new file mode 100644 index 00000000000..994e3d0b34f --- /dev/null +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_ada-linking-exception_1.RULE @@ -0,0 +1,9 @@ +licensed under the +terms of the {{GNU General Public License}}, with this special exception: + + {{As a special exception, if other files instantiate generics from this + unit, or you link this unit with other files to produce an executable}}, + this unit does not by itself cause the resulting executable to be + covered by the {{GNU General Public License}}. This exception does not + however invalidate any other reasons why the executable file might be + covered by the GNU Public License. \ No newline at end of file diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_ada-linking-exception_1.yml b/src/licensedcode/data/rules/gpl-1.0-plus_with_ada-linking-exception_1.yml new file mode 100644 index 00000000000..9316acf65c2 --- /dev/null +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_ada-linking-exception_1.yml @@ -0,0 +1,2 @@ +license_expression: gpl-1.0-plus WITH ada-linking-exception +is_license_notice: yes diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_autoconf-simple-exception-2.0_3.yml b/src/licensedcode/data/rules/gpl-1.0-plus_with_autoconf-simple-exception-2.0_3.yml index 2b5fafec6da..a4e01f47389 100644 --- a/src/licensedcode/data/rules/gpl-1.0-plus_with_autoconf-simple-exception-2.0_3.yml +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_autoconf-simple-exception-2.0_3.yml @@ -1,2 +1,3 @@ license_expression: gpl-1.0-plus WITH autoconf-simple-exception-2.0 is_license_notice: yes +minimum_coverage: 80 diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_classpath-exception-2.0_2.RULE b/src/licensedcode/data/rules/gpl-1.0-plus_with_classpath-exception-2.0_2.RULE index 20b10d65234..b6a75af2c20 100644 --- a/src/licensedcode/data/rules/gpl-1.0-plus_with_classpath-exception-2.0_2.RULE +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_classpath-exception-2.0_2.RULE @@ -1,7 +1,7 @@ -library is licensed under the terms of the GNU General +library is {{licensed under the terms of the GNU General Public License. -Linking this library statically or dynamically with other modules is +Linking this library statically or dynamically }} with other modules is making a combined work based on this library. Thus, the terms and conditions of the GNU General Public License cover the whole combination. @@ -19,4 +19,4 @@ obligated to do so. If you do not wish to do so, delete this exception statement from your version. You should have received a copy of the GNU General Public License -along with \ No newline at end of file +along with diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_classpath-exception-2.0_2.yml b/src/licensedcode/data/rules/gpl-1.0-plus_with_classpath-exception-2.0_2.yml index 40d55452350..968febba318 100644 --- a/src/licensedcode/data/rules/gpl-1.0-plus_with_classpath-exception-2.0_2.yml +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_classpath-exception-2.0_2.yml @@ -1,3 +1,4 @@ license_expression: gpl-1.0-plus WITH classpath-exception-2.0 is_license_reference: yes relevance: 100 + diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_classpath-exception-2.0_3.RULE b/src/licensedcode/data/rules/gpl-1.0-plus_with_classpath-exception-2.0_3.RULE new file mode 100644 index 00000000000..e7663ff4c54 --- /dev/null +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_classpath-exception-2.0_3.RULE @@ -0,0 +1,19 @@ +licensed {{under the terms of the GNU General +Public License, with a special exception}}: + + Linking this library statically or dynamically with {{other modules + is making a combined work based on this library}}. Thus, the terms + and conditions of the GNU General Public License cover the whole + combination. + + As a special exception, the copyright holders of this library give + you permission to link this library with independent modules to + produce an executable, regardless of the license terms of these + independent modules, and to copy and distribute the resulting + executable under terms of your choice, provided that you also + meet, for each linked independent module, the terms and conditions + of the license of that module. {{An independent module is a module + which is not derived from or based on this library}}. If you modify + this library, you may extend this exception to your version of the + library, but you are not obligated to do so. If you do not wish + to do so, delete this exception statement from your version. \ No newline at end of file diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_classpath-exception-2.0_3.yml b/src/licensedcode/data/rules/gpl-1.0-plus_with_classpath-exception-2.0_3.yml new file mode 100644 index 00000000000..55df48c90ab --- /dev/null +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_classpath-exception-2.0_3.yml @@ -0,0 +1,2 @@ +license_expression: gpl-1.0-plus WITH classpath-exception-2.0 +is_license_notice: yes diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_gcc-compiler-exception-2.0_1.RULE b/src/licensedcode/data/rules/gpl-1.0-plus_with_gcc-compiler-exception-2.0_1.RULE new file mode 100644 index 00000000000..199269b137e --- /dev/null +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_gcc-compiler-exception-2.0_1.RULE @@ -0,0 +1,9 @@ +licensed under the terms of the {{GNU General +Public License}}, with this special exception: + + As a special exception, if you link this file with files compiled + with a GNU compiler to produce an executable, this does not cause + the resulting executable to be covered by the GNU General Public + License. This exception does not however invalidate any other + reasons why the executable file might be covered by the GNU + General Public License. \ No newline at end of file diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_gcc-compiler-exception-2.0_1.yml b/src/licensedcode/data/rules/gpl-1.0-plus_with_gcc-compiler-exception-2.0_1.yml new file mode 100644 index 00000000000..86dff73d650 --- /dev/null +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_gcc-compiler-exception-2.0_1.yml @@ -0,0 +1,2 @@ +license_expression: gpl-1.0-plus WITH gcc-compiler-exception-2.0 +is_license_notice: yes diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_gcc-linking-exception-2.0_2.RULE b/src/licensedcode/data/rules/gpl-1.0-plus_with_gcc-linking-exception-2.0_2.RULE new file mode 100644 index 00000000000..f06cc7d528f --- /dev/null +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_gcc-linking-exception-2.0_2.RULE @@ -0,0 +1,11 @@ +licensed under the terms of the GNU General +Public License, and has the following addition: + + In addition to the permissions in the GNU General Public License, + the Free Software Foundation gives you unlimited permission to + link the compiled version of this file into combinations with + other programs, and to distribute those combinations without any + restriction coming from the use of this file. (The General Public + License restrictions do apply in other respects; for example, they + cover modification of the file, and distribution when not linked + into a combine executable.) \ No newline at end of file diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_gcc-linking-exception-2.0_2.yml b/src/licensedcode/data/rules/gpl-1.0-plus_with_gcc-linking-exception-2.0_2.yml new file mode 100644 index 00000000000..e063426bd99 --- /dev/null +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_gcc-linking-exception-2.0_2.yml @@ -0,0 +1,2 @@ +license_expression: gpl-1.0-plus WITH gcc-linking-exception-2.0 +is_license_notice: yes diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_linking-exception-2.0-plus_1.RULE b/src/licensedcode/data/rules/gpl-1.0-plus_with_linking-exception-2.0-plus_1.RULE new file mode 100644 index 00000000000..a2f6bc72b07 --- /dev/null +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_linking-exception-2.0-plus_1.RULE @@ -0,0 +1,9 @@ +licensed under the terms of the GNU General +Public License, with a special exception: + + As a special exception, if you link this library with other files, + some of which are compiled with GCC, to produce an executable, + this library does not by itself cause the resulting executable to + be covered by the GNU General Public License. This exception does + not however invalidate any other reasons why the executable file + might be covered by the GNU General Public License. \ No newline at end of file diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_linking-exception-2.0-plus_1.yml b/src/licensedcode/data/rules/gpl-1.0-plus_with_linking-exception-2.0-plus_1.yml new file mode 100644 index 00000000000..c8eb05bde0c --- /dev/null +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_linking-exception-2.0-plus_1.yml @@ -0,0 +1,2 @@ +license_expression: gpl-1.0-plus WITH linking-exception-2.0-plus +is_license_notice: yes diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_mif-exception_1.RULE b/src/licensedcode/data/rules/gpl-1.0-plus_with_mif-exception_1.RULE new file mode 100644 index 00000000000..791560b2e38 --- /dev/null +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_mif-exception_1.RULE @@ -0,0 +1,11 @@ +library is licensed under the terms of the {{GNU General +Public License}}, with this special exception: + + {{As a special exception, you may use this file as part of a free software + library without restriction}}. Specifically, if other files instantiate + templates or use macros or inline functions from this file, or you compile + this file and link it with other files to produce an executable, this + file does not by itself cause the resulting executable to be covered by + the GNU General Public License. This exception does not however + invalidate any other reasons why the executable file might be covered by + the GNU General Public License. \ No newline at end of file diff --git a/src/licensedcode/data/rules/gpl-1.0-plus_with_mif-exception_1.yml b/src/licensedcode/data/rules/gpl-1.0-plus_with_mif-exception_1.yml new file mode 100644 index 00000000000..02b4fc322a9 --- /dev/null +++ b/src/licensedcode/data/rules/gpl-1.0-plus_with_mif-exception_1.yml @@ -0,0 +1,2 @@ +license_expression: gpl-1.0-plus WITH mif-exception +is_license_notice: yes diff --git a/src/licensedcode/data/rules/gpl-2.0-plus_2.RULE b/src/licensedcode/data/rules/gpl-2.0-plus_2.RULE index f84b98de1fb..2460212d9df 100644 --- a/src/licensedcode/data/rules/gpl-2.0-plus_2.RULE +++ b/src/licensedcode/data/rules/gpl-2.0-plus_2.RULE @@ -1,4 +1,4 @@ -is licensend under the terms of the GNU General + licensend under the terms of the {{GNU General Public License, either version 2 of the License, or (at your option) -any later version, which on Debian GNU/Linux systems can be found as -`/usr/share/common-licenses/GPL'. \ No newline at end of file +any later version}}, which on Debian GNU/Linux systems can be found as +`{{/usr/share/common-licenses/GPL}}'. diff --git a/src/licensedcode/data/rules/gpl-2.0-plus_427.RULE b/src/licensedcode/data/rules/gpl-2.0-plus_427.RULE index 734345c08ff..a45a274bcb6 100644 --- a/src/licensedcode/data/rules/gpl-2.0-plus_427.RULE +++ b/src/licensedcode/data/rules/gpl-2.0-plus_427.RULE @@ -1,9 +1,9 @@ -Released under GNU General Public License (GPL) version 2 +Released under {{GNU General Public License (GPL) version 2}} This program is free software; you can redistribute it and/or -modify it under the terms of the GNU General Public License as -published by the Free Software Foundation; either version 2 of the -License, or (at your option) any later version. +modify it under the terms of the{{ GNU General Public License}} as +published by the Free Software Foundation; {{either version 2 of the +License, or (at your option) any later version.}} This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of diff --git a/src/licensedcode/data/rules/gpl-2.0-plus_and_gpl-3.0-plus.RULE b/src/licensedcode/data/rules/gpl-2.0-plus_and_gpl-3.0-plus.RULE index c23c99cd48c..924813fa3ea 100644 --- a/src/licensedcode/data/rules/gpl-2.0-plus_and_gpl-3.0-plus.RULE +++ b/src/licensedcode/data/rules/gpl-2.0-plus_and_gpl-3.0-plus.RULE @@ -1,7 +1,7 @@ GCC is free software; you can redistribute it and/or modify it under -the terms of the GNU General Public License as published by the Free -Software Foundation; either version 3, or (at your option) any later -version. +the terms of the {{GNU General Public License}} as published by the Free +Software Foundation; {{either version 3}}, or (at your option) {{any later +version}}. GCC is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or @@ -12,6 +12,6 @@ Files that have exception clauses are licensed under the terms of the GNU General Public License; either version 2, or (at your option) any later version. -On Debian GNU/Linux systems, the complete text of the GNU General -Public License is in `/usr/share/common-licenses/GPL', version 2 of this -license in `/usr/share/common-licenses/GPL-2'. +On Debian GNU/Linux systems, the complete text of the {{GNU General +Public License is in `/usr/share/common-licenses/GPL'}}, {{version 2 of this +license in `/usr/share/common-licenses/GPL-2'.}} diff --git a/src/licensedcode/data/rules/gpl-2.0-plus_and_lgpl-2.1-plus_and_cc-by-sa-4.0_and_bds-new.RULE b/src/licensedcode/data/rules/gpl-2.0-plus_and_lgpl-2.1-plus_and_cc-by-sa-4.0_and_bds-new.RULE index eeb67c6c211..f43ca628f33 100644 --- a/src/licensedcode/data/rules/gpl-2.0-plus_and_lgpl-2.1-plus_and_cc-by-sa-4.0_and_bds-new.RULE +++ b/src/licensedcode/data/rules/gpl-2.0-plus_and_lgpl-2.1-plus_and_cc-by-sa-4.0_and_bds-new.RULE @@ -1,7 +1,7 @@ Except where noted otherwise in the file itself, the source code for all programs is licensed under version 2 or later of the GNU General -Public License (GPLv2+), its headers and libraries under version 2.1 or -later of the less restrictive GNU Lesser General Public License (LGPLv2.1+), +Public License {{(GPLv2+)}}, its headers and libraries under version 2.1 or +later of the less restrictive GNU Lesser General Public License {{(LGPLv2.1+)}}, its documentation under version 4.0 or later of the Creative Commons -Attribution-ShareAlike International Public License (CC-BY-SA v4.0+), -and its init scripts under the Revised BSD license. +Attribution-ShareAlike International Public License ({{CC-BY-SA v4.0+}}), +and its init scripts under the {{Revised BSD license}}. diff --git a/src/licensedcode/data/rules/gpl-2.0_1122.RULE b/src/licensedcode/data/rules/gpl-2.0_1122.RULE index 5041dc26d28..c3d28282d27 100644 --- a/src/licensedcode/data/rules/gpl-2.0_1122.RULE +++ b/src/licensedcode/data/rules/gpl-2.0_1122.RULE @@ -1,11 +1,11 @@ - The Debian specific changes are and distributed under the terms of the GNU - General Public License, version 2. + The Debian specific changes are and {{distributed under the terms of the GNU + General Public License, version 2}}. -On Debian GNU/Linux systems, the complete text of the GNU General -Public License can be found in `/usr/share/common-licenses/GPL'. +On Debian GNU/Linux systems, the {{complete text of the GNU General +Public License can be found in `/usr/share/common-licenses/GPL}}'. - A copy of the GNU General Public License is also available at + A copy of the {{GNU General Public License is also available}} at . You may also obtain it by writing to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA diff --git a/src/licensedcode/data/rules/gpl-2.0_1123.RULE b/src/licensedcode/data/rules/gpl-2.0_1123.RULE index b981ec148b3..9c4911f0373 100644 --- a/src/licensedcode/data/rules/gpl-2.0_1123.RULE +++ b/src/licensedcode/data/rules/gpl-2.0_1123.RULE @@ -1,11 +1,10 @@ -distributed under the terms of the GNU - General Public License, version 2. +distributed {{under the terms of the GNU + General Public License, version 2}}. +On Debian GNU/Linux systems, the complete {{text of the GNU General +Public License can be found in `/usr/share/common-licenses/GPL}}'. -On Debian GNU/Linux systems, the complete text of the GNU General -Public License can be found in `/usr/share/common-licenses/GPL'. - - A copy of the GNU General Public License is also available at + {{A copy of the GNU General Public License is also available at}} . You may also obtain it by writing to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA diff --git a/src/licensedcode/data/rules/gpl-2.0_1212.RULE b/src/licensedcode/data/rules/gpl-2.0_1212.RULE index 17e227663f5..f3e32682320 100644 --- a/src/licensedcode/data/rules/gpl-2.0_1212.RULE +++ b/src/licensedcode/data/rules/gpl-2.0_1212.RULE @@ -1,11 +1,11 @@ - The Debian specific changes are and distributed under the terms of the GNU - General Public License, version 2. + The Debian specific changes are and distributed {{under the terms of the GNU + General Public License, version 2}}. -On Debian GNU/Linux systems, the complete text of the GNU General -Public License can be found in `/usr/share/common-licenses/GPL'. +On Debian GNU/Linux systems, the complete text of the {{GNU General +Public License can be found in `/usr/share/common-licenses/GPL}}'. - A copy of the GNU General Public License is also available at + A copy of the {{GNU General Public License is also available}} at . You may also obtain it by writing to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA diff --git a/src/licensedcode/data/rules/gpl-2.0_1221.RULE b/src/licensedcode/data/rules/gpl-2.0_1221.RULE index 6a58dd7b859..af310099461 100644 --- a/src/licensedcode/data/rules/gpl-2.0_1221.RULE +++ b/src/licensedcode/data/rules/gpl-2.0_1221.RULE @@ -1,10 +1,10 @@ -distributed under the terms of the GNU -General Public License, version 2. +{{distributed under the terms of the GNU +General Public License, version 2}}. -On Debian GNU/Linux systems, the complete text of the GNU General -Public License can be found in `/usr/share/common-licenses/GPL-2'. +On Debian GNU/Linux systems, the complete {{text of the GNU General +Public License can be found in `/usr/share/common-licenses/GPL-2}}'. - A copy of the GNU General Public License is also available at + A copy of the {{GNU General Public License is also available}} at . You may also obtain it by writing to the Free Software Foundation, Inc., 51 Franklin - St, Fifth Floor, Boston, MA 02110-1301, USA. \ No newline at end of file + St, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/src/licensedcode/data/rules/gpl-2.0_1260.RULE b/src/licensedcode/data/rules/gpl-2.0_1260.RULE index b61a69a680b..8e2e265cdea 100644 --- a/src/licensedcode/data/rules/gpl-2.0_1260.RULE +++ b/src/licensedcode/data/rules/gpl-2.0_1260.RULE @@ -1,11 +1,11 @@ -distributed under the terms of the GNU - General Public License, version 2. +{{distributed under the terms of the GNU + General Public License, version 2}}. -On Debian GNU/Linux systems, the complete text of the GNU General -Public License can be found in `/usr/share/common-licenses/GPL'. +On Debian GNU/Linux systems, the complete text of the {{GNU General +Public License can be found in `/usr/share/common-licenses/GPL}}'. - A copy of the GNU General Public License is also available at + A copy of the {{GNU General Public License is also available}} at . You may also obtain it by writing to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA diff --git a/src/licensedcode/data/rules/gpl-2.0_929.RULE b/src/licensedcode/data/rules/gpl-2.0_929.RULE index 47a5407db99..d41bb3eaae2 100644 --- a/src/licensedcode/data/rules/gpl-2.0_929.RULE +++ b/src/licensedcode/data/rules/gpl-2.0_929.RULE @@ -1 +1 @@ -distributed underthe terms of the GNU General Public License, version 2. \ No newline at end of file +distributed {{underthe terms of the GNU General Public License, version 2}}. diff --git a/src/licensedcode/data/rules/gpl-2.0_930.RULE b/src/licensedcode/data/rules/gpl-2.0_930.RULE index 23a0df99d30..61fb24867b3 100644 --- a/src/licensedcode/data/rules/gpl-2.0_930.RULE +++ b/src/licensedcode/data/rules/gpl-2.0_930.RULE @@ -1,10 +1,10 @@ -distributed under the terms of the GNU -General Public License, version 2. +distributed {{under the terms of the GNU +General Public License, version 2}}. -On Debian GNU/Linux systems, the complete text of the GNU General -Public License can be found in `/usr/share/common-licenses/GPL-2'. +On Debian GNU/Linux systems, the complete text of the {{GNU General +Public License can be found in `/usr/share/common-licenses/GPL-2 }}'. - A copy of the GNU General Public License is also available at + A copy of the {{GNU General Public License is also available}} at . You may also obtain it by writing to the Free Software Foundation, Inc., 51 Franklin - St, Fifth Floor, Boston, MA 02110-1301, USA. \ No newline at end of file + St, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/src/licensedcode/data/rules/gpl-3.0-plus_23.RULE b/src/licensedcode/data/rules/gpl-3.0-plus_23.RULE index 7b0b70c8208..c01d256a025 100644 --- a/src/licensedcode/data/rules/gpl-3.0-plus_23.RULE +++ b/src/licensedcode/data/rules/gpl-3.0-plus_23.RULE @@ -1,7 +1,7 @@ - This program is free software: you can redistribute it and/or modify +This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. + the Free Software Foundation, either {{version 3}} of the License, or + (at your option) {{any later version}}. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of @@ -12,4 +12,4 @@ along with this program. If not, see . On Debian systems, the complete text of the GNU General Public -License can be found in /usr/share/common-licenses/GPL +License can be found in /usr/share/common-licenses/GPL \ No newline at end of file diff --git a/src/licensedcode/data/rules/gpl-3.0-plus_23.yml b/src/licensedcode/data/rules/gpl-3.0-plus_23.yml index 25a772d29fc..591fbe36a5b 100644 --- a/src/licensedcode/data/rules/gpl-3.0-plus_23.yml +++ b/src/licensedcode/data/rules/gpl-3.0-plus_23.yml @@ -1,4 +1,6 @@ license_expression: gpl-3.0-plus is_license_notice: yes +referenced_filenames: + - /usr/share/common-licenses/GPL ignorable_urls: - http://www.gnu.org/licenses/ diff --git a/src/licensedcode/data/rules/gpl-3.0-plus_290.RULE b/src/licensedcode/data/rules/gpl-3.0-plus_290.RULE index beceabe5e7c..279b584d117 100644 --- a/src/licensedcode/data/rules/gpl-3.0-plus_290.RULE +++ b/src/licensedcode/data/rules/gpl-3.0-plus_290.RULE @@ -1,12 +1,12 @@ This program is free software: you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation, either version 3 of the License, or -(at your option) any later version. + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either {{version 3}} of the License, or + (at your option) {{any later version}}. -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. -You should have received a copy of the GNU General Public License -along with this program. If not, see . \ No newline at end of file + You should have received a copy of the GNU General Public License + along with this program. If not, see . \ No newline at end of file diff --git a/src/licensedcode/data/rules/gpl-3.0-plus_290.yml b/src/licensedcode/data/rules/gpl-3.0-plus_290.yml index b65379797c5..25a772d29fc 100644 --- a/src/licensedcode/data/rules/gpl-3.0-plus_290.yml +++ b/src/licensedcode/data/rules/gpl-3.0-plus_290.yml @@ -1,6 +1,4 @@ license_expression: gpl-3.0-plus is_license_notice: yes -relevance: 100 -minimum_coverage: 10 ignorable_urls: - http://www.gnu.org/licenses/ diff --git a/src/licensedcode/data/rules/gpl-3.0-plus_82.RULE b/src/licensedcode/data/rules/gpl-3.0-plus_82.RULE index e2b85c8a991..920307917d8 100644 --- a/src/licensedcode/data/rules/gpl-3.0-plus_82.RULE +++ b/src/licensedcode/data/rules/gpl-3.0-plus_82.RULE @@ -1,7 +1,7 @@ This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. + the Free Software Foundation, either {{version 3}} of the License, or + (at your option) {{any later version}}. This package is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of @@ -11,7 +11,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . -On Debian systems, the complete text of the GNU General Public License -version 2 can be found in `/usr/share/common-licenses/GPL-2'. the -complete text of the GNU General Public License version 3 can be found -in `/usr/share/common-licenses/GPL-3'. +On Debian systems, the {{complete text}} of the GNU General Public License +{{version 2 can be found in `/usr/share/common-licenses/GPL-2}}'. the +{{complete text}} of the GNU General Public License {{version 3 can be found +in `/usr/share/common-licenses/GPL-3'}}. diff --git a/src/licensedcode/data/rules/gpl-3.0-plus_with_gpl-generic-additional-terms_1.RULE b/src/licensedcode/data/rules/gpl-3.0-plus_with_gpl-generic-additional-terms_1.RULE new file mode 100644 index 00000000000..8828316a31e --- /dev/null +++ b/src/licensedcode/data/rules/gpl-3.0-plus_with_gpl-generic-additional-terms_1.RULE @@ -0,0 +1,10 @@ +Additional permission under {{GNU GPL version 3}} section 7 + +If you modify this program, or any covered work, by linking or +combining it with the OpenSSL project's OpenSSL library (or a +modified version of that library), containing parts covered by the +terms of the OpenSSL or SSLeay licenses, the Free Software Foundation +grants you additional permission to convey the resulting work. +Corresponding Source for a non-source form of such a combination +shall include the source code for the parts of OpenSSL used as well +as that of the covered work. \ No newline at end of file diff --git a/src/licensedcode/data/rules/gpl-3.0-plus_with_gpl-generic-additional-terms_1.yml b/src/licensedcode/data/rules/gpl-3.0-plus_with_gpl-generic-additional-terms_1.yml new file mode 100644 index 00000000000..76f4d524f74 --- /dev/null +++ b/src/licensedcode/data/rules/gpl-3.0-plus_with_gpl-generic-additional-terms_1.yml @@ -0,0 +1,3 @@ +license_expression: gpl-3.0-plus WITH gpl-generic-additional-terms +is_license_notice: yes +notes: Seen in older https://github.com/ca4ti/chiaki/ diff --git a/src/licensedcode/data/rules/gpl_19.RULE b/src/licensedcode/data/rules/gpl_19.RULE index 538a1df6f60..b3609531773 100644 --- a/src/licensedcode/data/rules/gpl_19.RULE +++ b/src/licensedcode/data/rules/gpl_19.RULE @@ -1,3 +1,3 @@ -is copyright Free Software Foundation, and is licensed under the -GNU General Public License which on Debian GNU/Linux systems can be -found as `/usr/share/common-licenses/GPL'. +licensed under the +{{GNU General Public License}} which on Debian GNU/Linux systems can be +found as {{/usr/share/common-licenses/GPL}}'. diff --git a/src/licensedcode/data/rules/gpl_19.yml b/src/licensedcode/data/rules/gpl_19.yml index c80169fe640..c974511f715 100644 --- a/src/licensedcode/data/rules/gpl_19.yml +++ b/src/licensedcode/data/rules/gpl_19.yml @@ -1,7 +1,5 @@ license_expression: gpl-1.0-plus is_license_notice: yes relevance: 100 -ignorable_copyrights: - - copyright Free Software Foundation -ignorable_holders: - - Free Software Foundation +referenced_filenames: + - /usr/share/common-licenses/GPL diff --git a/src/licensedcode/data/rules/gpl_44.RULE b/src/licensedcode/data/rules/gpl_44.RULE index f60e6c7acc0..b828d03b520 100644 --- a/src/licensedcode/data/rules/gpl_44.RULE +++ b/src/licensedcode/data/rules/gpl_44.RULE @@ -1,2 +1 @@ -In contrast, libgnatprj is licensed under the terms of the pure GNU -General Public License. \ No newline at end of file +licensed under the terms of the pure GNU General Public License. diff --git a/src/licensedcode/data/rules/gpl_44.yml b/src/licensedcode/data/rules/gpl_44.yml index 7071924eb9e..71014d90554 100644 --- a/src/licensedcode/data/rules/gpl_44.yml +++ b/src/licensedcode/data/rules/gpl_44.yml @@ -1,3 +1,5 @@ license_expression: gpl-1.0-plus -is_license_reference: yes relevance: 100 +is_license_notice: yes +minimum_coverage: 100 +is_continuous: yes diff --git a/src/licensedcode/data/rules/lgpl-2.0-plus_544.RULE b/src/licensedcode/data/rules/lgpl-2.0-plus_544.RULE new file mode 100644 index 00000000000..25b17add54d --- /dev/null +++ b/src/licensedcode/data/rules/lgpl-2.0-plus_544.RULE @@ -0,0 +1 @@ +- LicenseRef-LGPL \ No newline at end of file diff --git a/src/licensedcode/data/rules/lgpl-2.0-plus_544.yml b/src/licensedcode/data/rules/lgpl-2.0-plus_544.yml new file mode 100644 index 00000000000..00706bdc2a4 --- /dev/null +++ b/src/licensedcode/data/rules/lgpl-2.0-plus_544.yml @@ -0,0 +1,3 @@ +license_expression: lgpl-2.0-plus +is_license_tag: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/lgpl-2.0-plus_with_linking-exception-2.0-plus_1.RULE b/src/licensedcode/data/rules/lgpl-2.0-plus_with_linking-exception-2.0-plus_1.RULE new file mode 100644 index 00000000000..88b6d9995b1 --- /dev/null +++ b/src/licensedcode/data/rules/lgpl-2.0-plus_with_linking-exception-2.0-plus_1.RULE @@ -0,0 +1,9 @@ +licensed under the terms of the {{GNU Lesser +General Public License, with a special exception}}: + + As a special exception, if you link this library with other files, some + of which are compiled with GCC, to produce an executable, this library + does not by itself cause the resulting executable to be covered by the + GNU General Public License. This exception does not however invalidate + any other reasons why the executable file might be covered by the GNU + General Public License. \ No newline at end of file diff --git a/src/licensedcode/data/rules/lgpl-2.0-plus_with_linking-exception-2.0-plus_1.yml b/src/licensedcode/data/rules/lgpl-2.0-plus_with_linking-exception-2.0-plus_1.yml new file mode 100644 index 00000000000..399dfe96a13 --- /dev/null +++ b/src/licensedcode/data/rules/lgpl-2.0-plus_with_linking-exception-2.0-plus_1.yml @@ -0,0 +1,3 @@ +license_expression: lgpl-2.0-plus WITH linking-exception-2.0-plus +is_license_notice: yes +minimum_coverage: 95 diff --git a/src/licensedcode/data/rules/lgpl-2.0_203.RULE b/src/licensedcode/data/rules/lgpl-2.0_203.RULE new file mode 100644 index 00000000000..3e4463caf5a --- /dev/null +++ b/src/licensedcode/data/rules/lgpl-2.0_203.RULE @@ -0,0 +1 @@ +- LicenseRef-LGPL-2 \ No newline at end of file diff --git a/src/licensedcode/data/rules/lgpl-2.0_203.yml b/src/licensedcode/data/rules/lgpl-2.0_203.yml new file mode 100644 index 00000000000..1058535b4b2 --- /dev/null +++ b/src/licensedcode/data/rules/lgpl-2.0_203.yml @@ -0,0 +1,3 @@ +license_expression: lgpl-2.0 +is_license_tag: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/lgpl-2.0_204.RULE b/src/licensedcode/data/rules/lgpl-2.0_204.RULE new file mode 100644 index 00000000000..5d07ecdbb70 --- /dev/null +++ b/src/licensedcode/data/rules/lgpl-2.0_204.RULE @@ -0,0 +1 @@ +- LicenseRef-LGPL-2.0 \ No newline at end of file diff --git a/src/licensedcode/data/rules/lgpl-2.0_204.yml b/src/licensedcode/data/rules/lgpl-2.0_204.yml new file mode 100644 index 00000000000..1058535b4b2 --- /dev/null +++ b/src/licensedcode/data/rules/lgpl-2.0_204.yml @@ -0,0 +1,3 @@ +license_expression: lgpl-2.0 +is_license_tag: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/lgpl-2.1-plus_287.RULE b/src/licensedcode/data/rules/lgpl-2.1-plus_287.RULE index 2d10c799e5a..7f7c9d9cb2e 100644 --- a/src/licensedcode/data/rules/lgpl-2.1-plus_287.RULE +++ b/src/licensedcode/data/rules/lgpl-2.1-plus_287.RULE @@ -1 +1 @@ -licensed under the terms of the GNU Lesser General Public License \ No newline at end of file +licensed under the terms of the {{GNU Lesser General Public License}} diff --git a/src/licensedcode/data/rules/lgpl-2.1-plus_287.yml b/src/licensedcode/data/rules/lgpl-2.1-plus_287.yml index f57751a8d70..9897d4c23a2 100644 --- a/src/licensedcode/data/rules/lgpl-2.1-plus_287.yml +++ b/src/licensedcode/data/rules/lgpl-2.1-plus_287.yml @@ -1,3 +1,4 @@ license_expression: lgpl-2.1-plus is_license_notice: yes relevance: 100 +notes: no version but lesser implies 2.1 diff --git a/src/licensedcode/data/rules/lgpl-3.0-plus_26.RULE b/src/licensedcode/data/rules/lgpl-3.0-plus_26.RULE index 649474318cf..67151527294 100644 --- a/src/licensedcode/data/rules/lgpl-3.0-plus_26.RULE +++ b/src/licensedcode/data/rules/lgpl-3.0-plus_26.RULE @@ -1,7 +1,7 @@ * is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. + * modify it under the terms of the {{GNU Lesser General Public + * License}} as published by the Free Software Foundation; either + * {{version 3}} of the License, or (at your option) {{any later version}}. * * is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of @@ -11,4 +11,4 @@ * You should have received a copy of the GNU Lesser General Public License * along with this program; if not, write to the Free Software Foundation, * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ \ No newline at end of file + */ diff --git a/src/licensedcode/data/rules/lgpl_11.RULE b/src/licensedcode/data/rules/lgpl_11.RULE deleted file mode 100644 index 0910daa9310..00000000000 --- a/src/licensedcode/data/rules/lgpl_11.RULE +++ /dev/null @@ -1 +0,0 @@ -is licensed under the terms of the GNU Lesser General Public License \ No newline at end of file diff --git a/src/licensedcode/data/rules/lgpl_11.yml b/src/licensedcode/data/rules/lgpl_11.yml deleted file mode 100644 index cd4aad9b414..00000000000 --- a/src/licensedcode/data/rules/lgpl_11.yml +++ /dev/null @@ -1,5 +0,0 @@ -license_expression: lgpl-2.1-plus -is_license_reference: yes -relevance: 100 -minimum_coverage: 100 -notes: LGPL libgomp with lesser hence the 2.1-plus version diff --git a/src/licensedcode/data/rules/license-intro_55.RULE b/src/licensedcode/data/rules/license-intro_55.RULE new file mode 100644 index 00000000000..3771d10da31 --- /dev/null +++ b/src/licensedcode/data/rules/license-intro_55.RULE @@ -0,0 +1,4 @@ +The {{newlib subdirectory is a collection of software from several sources}}. +Each file may have its own copyright/license that is embedded in the source +file. Unless otherwise noted in the body of the source file(s), the following {{copyright +notices will apply to the contents of the newlib subdirectory}} \ No newline at end of file diff --git a/src/licensedcode/data/rules/license-intro_55.yml b/src/licensedcode/data/rules/license-intro_55.yml new file mode 100644 index 00000000000..f79781e9b44 --- /dev/null +++ b/src/licensedcode/data/rules/license-intro_55.yml @@ -0,0 +1,3 @@ +license_expression: bsd-new AND other-permissive AND other-copyleft +is_license_intro: yes +notes: Seen in newlib diff --git a/src/licensedcode/data/rules/license-intro_56.RULE b/src/licensedcode/data/rules/license-intro_56.RULE new file mode 100644 index 00000000000..4251d681a45 --- /dev/null +++ b/src/licensedcode/data/rules/license-intro_56.RULE @@ -0,0 +1,6 @@ +WILLING TO LICENSE THIS SPECIFICATION TO YOU +ONLY UPON THE CONDITION THAT YOU ACCEPT ALL OF THE TERMS CONTAINED IN THIS +AGREEMENT. PLEASE READ THE TERMS AND CONDITIONS OF THIS AGREEMENT CAREFULLY. BY +DOWNLOADING THIS SPECIFICATION, YOU ACCEPT THE TERMS AND CONDITIONS OF THE +AGREEMENT. IF YOU ARE NOT WILLING TO BE BOUND BY IT, SELECT THE "DECLINE" BUTTON +AT THE BOTTOM OF THIS PAGE. \ No newline at end of file diff --git a/src/licensedcode/data/rules/license-intro_56.yml b/src/licensedcode/data/rules/license-intro_56.yml new file mode 100644 index 00000000000..adfeb433e82 --- /dev/null +++ b/src/licensedcode/data/rules/license-intro_56.yml @@ -0,0 +1,3 @@ +license_expression: proprietary-license +is_license_intro: yes +minimum_coverage: 80 diff --git a/src/licensedcode/data/rules/free-unknown_47.RULE b/src/licensedcode/data/rules/license-intro_bsd-new_and_other-permissive_and_other-copyleft_1.RULE similarity index 60% rename from src/licensedcode/data/rules/free-unknown_47.RULE rename to src/licensedcode/data/rules/license-intro_bsd-new_and_other-permissive_and_other-copyleft_1.RULE index 9f0fc530470..7b8fa0ddaf2 100644 --- a/src/licensedcode/data/rules/free-unknown_47.RULE +++ b/src/licensedcode/data/rules/license-intro_bsd-new_and_other-permissive_and_other-copyleft_1.RULE @@ -1,3 +1,3 @@ Each file may have its own copyright/license that is embedded in the source -file. Unless otherwise noted in the body of the source file(s), the following copyright -notices will apply to the contents of the newlib subdirectory: \ No newline at end of file +file. Unless otherwise noted in the body of the source file(s), the following {{copyright +notices will apply to the contents of the newlib subdirectory}}: diff --git a/src/licensedcode/data/rules/license-intro_bsd-new_and_other-permissive_and_other-copyleft_1.yml b/src/licensedcode/data/rules/license-intro_bsd-new_and_other-permissive_and_other-copyleft_1.yml new file mode 100644 index 00000000000..5becae3bf8d --- /dev/null +++ b/src/licensedcode/data/rules/license-intro_bsd-new_and_other-permissive_and_other-copyleft_1.yml @@ -0,0 +1,3 @@ +license_expression: bsd-new AND other-permissive AND other-copyleft +is_license_intro: yes +notes: header in the newlib license notice diff --git a/src/licensedcode/data/rules/mit-old-style-no-advert_25.RULE b/src/licensedcode/data/rules/mit-old-style-no-advert_25.RULE new file mode 100644 index 00000000000..f019c206568 --- /dev/null +++ b/src/licensedcode/data/rules/mit-old-style-no-advert_25.RULE @@ -0,0 +1 @@ +Permission to use, copy, modify, and distribute this software and its documentation for any purpose and with or without fee, is hereby granted provided that the above copyright notice appears in all copies and in supporting documentation, and that the name of the copyright holder not be used in advertising or publicity pertaining to distribution of the software without specific, written prior permission. \ No newline at end of file diff --git a/src/licensedcode/data/rules/mit-old-style-no-advert_25.yml b/src/licensedcode/data/rules/mit-old-style-no-advert_25.yml new file mode 100644 index 00000000000..f069c0e7c9b --- /dev/null +++ b/src/licensedcode/data/rules/mit-old-style-no-advert_25.yml @@ -0,0 +1,5 @@ +license_expression: mit-old-style-no-advert +is_license_text: yes +relevance: 95 +notes: this is a truncated notice without warranty disclaimer Seen in https://fastcrypto.org/ + umac diff --git a/src/licensedcode/data/rules/mit_1097.RULE b/src/licensedcode/data/rules/mit_1097.RULE index a77d5a0432a..b838b897380 100644 --- a/src/licensedcode/data/rules/mit_1097.RULE +++ b/src/licensedcode/data/rules/mit_1097.RULE @@ -1 +1 @@ -Distributed under the terms of an MIT-style license: The MIT License \ No newline at end of file +Distributed under the terms of an {{MIT-style license: The MIT License}} diff --git a/src/licensedcode/data/rules/mit_or_apache-2.0_and_other-permissive_1.RULE b/src/licensedcode/data/rules/mit_or_apache-2.0_and_other-permissive_1.RULE index b98991f14a2..4de9cb3e231 100644 --- a/src/licensedcode/data/rules/mit_or_apache-2.0_and_other-permissive_1.RULE +++ b/src/licensedcode/data/rules/mit_or_apache-2.0_and_other-permissive_1.RULE @@ -1,8 +1,8 @@ ## License -Rust is primarily distributed under the terms of both the MIT license -and the Apache License (Version 2.0), with portions covered by various -BSD-like licenses. +Rust is primarily distributed under the terms of {{both the MIT license +and the Apache License}} (Version 2.0), with {{portions covered by various +BSD-like licenses.}} See [LICENSE-APACHE](LICENSE-APACHE), [LICENSE-MIT](LICENSE-MIT), and -[COPYRIGHT](COPYRIGHT) for details. \ No newline at end of file +[COPYRIGHT](COPYRIGHT) for details. diff --git a/src/licensedcode/data/rules/mit_or_apache-2.0_and_other-permissive_3.RULE b/src/licensedcode/data/rules/mit_or_apache-2.0_and_other-permissive_3.RULE index 79074892578..57a6d2653ab 100644 --- a/src/licensedcode/data/rules/mit_or_apache-2.0_and_other-permissive_3.RULE +++ b/src/licensedcode/data/rules/mit_or_apache-2.0_and_other-permissive_3.RULE @@ -6,6 +6,6 @@ For full authorship information, see the version control history or https://thanks.rust-lang.org Except as otherwise noted (below and/or in individual files), Rust is -licensed under the Apache License, Version 2.0 or - or the MIT license - or , at your option. \ No newline at end of file +licensed under the {{Apache License, Version 2.0}} or + {{or the MIT license}} + or , {{at your option}}. diff --git a/src/licensedcode/data/rules/mpl-1.0_or_lgpl-2.0-plus_or_gpl-1.0-plus_and_apache-2.0_and_apache-2.0_and_apache-2.0_and_apache-2.0_and_bsd-new_or_afl-2.1_1.RULE b/src/licensedcode/data/rules/mpl-1.0_or_lgpl-2.0-plus_or_gpl-1.0-plus_and_apache-2.0_and_apache-2.0_and_apache-2.0_and_apache-2.0_and_bsd-new_or_afl-2.1_1.RULE new file mode 100644 index 00000000000..1ffb33123f0 --- /dev/null +++ b/src/licensedcode/data/rules/mpl-1.0_or_lgpl-2.0-plus_or_gpl-1.0-plus_and_apache-2.0_and_apache-2.0_and_apache-2.0_and_apache-2.0_and_bsd-new_or_afl-2.1_1.RULE @@ -0,0 +1,10 @@ +you may choose which +license to receive this code under (except as noted in per-module LICENSE +files). Persevere is distributed with several libraries which were produced with +their own license including Rhino (MPL, LGPL, or GPL), +Derby (Apache license), and Apache Commons +(Apache license), however, none of these libraries have been modified, the standard binary +distributions are included for setup convenience, with the exception that portions of +the Stringtree JSON Library source code was used in org.persvr.util.JSONParser. +Stringtree is Apache licensed and can be freely used and modified in Persevere +(compatible with AFL/BSD). \ No newline at end of file diff --git a/src/licensedcode/data/rules/mpl-1.0_or_lgpl-2.0-plus_or_gpl-1.0-plus_and_apache-2.0_and_apache-2.0_and_apache-2.0_and_apache-2.0_and_bsd-new_or_afl-2.1_1.yml b/src/licensedcode/data/rules/mpl-1.0_or_lgpl-2.0-plus_or_gpl-1.0-plus_and_apache-2.0_and_apache-2.0_and_apache-2.0_and_apache-2.0_and_bsd-new_or_afl-2.1_1.yml new file mode 100644 index 00000000000..53167bfcc34 --- /dev/null +++ b/src/licensedcode/data/rules/mpl-1.0_or_lgpl-2.0-plus_or_gpl-1.0-plus_and_apache-2.0_and_apache-2.0_and_apache-2.0_and_apache-2.0_and_bsd-new_or_afl-2.1_1.yml @@ -0,0 +1,5 @@ +license_expression: (mpl-1.0 OR lgpl-2.0-plus OR gpl-1.0-plus) AND apache-2.0 AND apache-2.0 + AND apache-2.0 AND apache-2.0 AND (bsd-new OR afl-2.1) +is_license_notice: yes +referenced_filenames: + - LICENSE diff --git a/src/licensedcode/data/rules/mpl-1.1_or_lgpl-2.1-plus_11.RULE b/src/licensedcode/data/rules/mpl-1.1_or_lgpl-2.1-plus_11.RULE index c26a311f654..12dc9de1bc9 100644 --- a/src/licensedcode/data/rules/mpl-1.1_or_lgpl-2.1-plus_11.RULE +++ b/src/licensedcode/data/rules/mpl-1.1_or_lgpl-2.1-plus_11.RULE @@ -6,9 +6,9 @@ - MPL 1.1 + {{MPL 1.1 - http://www.mozilla.org/MPL/MPL-1.1.html + http://www.mozilla.org/MPL/MPL-1.1.html}} @@ -20,9 +20,9 @@ - LGPL 2.1 + {{LGPL 2.1 - https://www.gnu.org/licenses/lgpl-2.1.html + https://www.gnu.org/licenses/lgpl-2.1.html}} diff --git a/src/licensedcode/data/rules/mpl-1.1_or_lgpl-2.1-plus_3.RULE b/src/licensedcode/data/rules/mpl-1.1_or_lgpl-2.1-plus_3.RULE index 75147efc25a..f390d101876 100644 --- a/src/licensedcode/data/rules/mpl-1.1_or_lgpl-2.1-plus_3.RULE +++ b/src/licensedcode/data/rules/mpl-1.1_or_lgpl-2.1-plus_3.RULE @@ -6,9 +6,9 @@ - MPL 1.1 + {{MPL 1.1 - http://www.mozilla.org/MPL/MPL-1.1.html + http://www.mozilla.org/MPL/MPL-1.1.html}} @@ -20,9 +20,9 @@ - LGPL 2.1 + {{LGPL 2.1 - http://www.gnu.org/licenses/lgpl-2.1.html + http://www.gnu.org/licenses/lgpl-2.1.html}} diff --git a/src/licensedcode/data/rules/mpl-1.1_or_lgpl-2.1-plus_3.yml b/src/licensedcode/data/rules/mpl-1.1_or_lgpl-2.1-plus_3.yml index 45d0efca74f..9a1c12efc03 100644 --- a/src/licensedcode/data/rules/mpl-1.1_or_lgpl-2.1-plus_3.yml +++ b/src/licensedcode/data/rules/mpl-1.1_or_lgpl-2.1-plus_3.yml @@ -1,6 +1,7 @@ license_expression: mpl-1.1 OR lgpl-2.1-plus is_license_notice: yes notes: javassist license choice in a maven POM +minimum_coverage: 70 ignorable_urls: - http://www.gnu.org/licenses/lgpl-2.1.html - http://www.mozilla.org/MPL/MPL-1.1.html diff --git a/src/licensedcode/data/rules/ms-pl_8.RULE b/src/licensedcode/data/rules/ms-pl_8.RULE index 6d41b8ea625..dda6dab38d6 100644 --- a/src/licensedcode/data/rules/ms-pl_8.RULE +++ b/src/licensedcode/data/rules/ms-pl_8.RULE @@ -1 +1 @@ - Licensed under Microsoft Public License (Ms-PL) \ No newline at end of file + Licensed under {{Microsoft Public License (Ms-PL)}} diff --git a/src/licensedcode/data/rules/openssl_5.RULE b/src/licensedcode/data/rules/openssl_5.RULE new file mode 100644 index 00000000000..4a1505ff9e8 --- /dev/null +++ b/src/licensedcode/data/rules/openssl_5.RULE @@ -0,0 +1,69 @@ +OpenSSL License: + + + The OpenSSL toolkit stays under a dual license, i.e. both the conditions of + the OpenSSL License and the original SSLeay license apply to the toolkit. + See below for the actual license texts. Actually both licenses are BSD-style + Open Source licenses. In case of any license issues related to OpenSSL + please contact openssl-core@openssl.org. + +/* ==================================================================== + * Copyright (c) 1998-2003 The OpenSSL Project. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * + * 3. All advertising materials mentioning features or use of this + * software must display the following acknowledgment: + * "This product includes software developed by the OpenSSL Project + * for use in the OpenSSL Toolkit. (http://www.openssl.org/)" + * + * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to + * endorse or promote products derived from this software without + * prior written permission. For written permission, please contact + * openssl-core@openssl.org. + * + * 5. Products derived from this software may not be called "OpenSSL" + * nor may "OpenSSL" appear in their names without prior written + * permission of the OpenSSL Project. + * + * 6. Redistributions of any form whatsoever must retain the following + * acknowledgment: + * "This product includes software developed by the OpenSSL Project + * for use in the OpenSSL Toolkit (http://www.openssl.org/)" + * + * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY + * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, + * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED + * OF THE POSSIBILITY OF SUCH DAMAGE. + * ==================================================================== + * + * This product includes cryptographic software written by Eric Young + * (eay@cryptsoft.com). This product includes software written by Tim + * Hudson (tjh@cryptsoft.com). + * + */ + + * + * The licence and distribution terms for any publically available version or + * derivative of this code cannot be changed. i.e. this code cannot simply be + * copied and put under another distribution licence + * [including the GNU Public Licence.] + */ \ No newline at end of file diff --git a/src/licensedcode/data/rules/openssl_5.yml b/src/licensedcode/data/rules/openssl_5.yml new file mode 100644 index 00000000000..6f9d7229407 --- /dev/null +++ b/src/licensedcode/data/rules/openssl_5.yml @@ -0,0 +1,17 @@ +license_expression: openssl +is_license_text: yes +minimum_coverage: 95 +ignorable_copyrights: + - Copyright (c) 1998-2003 The OpenSSL Project +ignorable_holders: + - The OpenSSL Project +ignorable_authors: + - Eric Young (eay@cryptsoft.com) + - Tim Hudson (tjh@cryptsoft.com) + - the OpenSSL Project +ignorable_urls: + - http://www.openssl.org/ +ignorable_emails: + - eay@cryptsoft.com + - openssl-core@openssl.org + - tjh@cryptsoft.com diff --git a/src/licensedcode/data/rules/other-permissive_339.RULE b/src/licensedcode/data/rules/other-permissive_339.RULE new file mode 100644 index 00000000000..17ff27d1838 --- /dev/null +++ b/src/licensedcode/data/rules/other-permissive_339.RULE @@ -0,0 +1,27 @@ +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the “Software”), to deal in +the Software without restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, provided that the above +copyright notice(s) and this permission notice appear in all copies of the Software +and that both the above copyright notice(s) and this permission notice appear in +supporting documentation. + +THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY +KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE +WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PUR- +POSE AND NONINFRINGEMENT OF THIRD PARTY RIGHTS. IN NO EVENT +SHALL THE COPYRIGHT HOLDER OR HOLDERS INCLUDED IN THIS NO- +TICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT OR CON- +SEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING +FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF +CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT +OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS +SOFTWARE. + +Except as contained in this notice, the name of a copyright holder shall not be +used in advertising or otherwise to promote the sale, use or other dealings in this +Software without prior written authorization of the copyright holder. +All source code included in this distribution is covered by this notice, unless +specifically stated otherwise within each file. See each file within each release for +specific copyright holders. \ No newline at end of file diff --git a/src/licensedcode/data/rules/other-permissive_339.yml b/src/licensedcode/data/rules/other-permissive_339.yml new file mode 100644 index 00000000000..c1d04e9cfc4 --- /dev/null +++ b/src/licensedcode/data/rules/other-permissive_339.yml @@ -0,0 +1,3 @@ +license_expression: other-permissive +is_license_text: yes +notes: MIT-like seen in the Fedora license list diff --git a/src/licensedcode/data/rules/other-permissive_340.RULE b/src/licensedcode/data/rules/other-permissive_340.RULE new file mode 100644 index 00000000000..8532cf207df --- /dev/null +++ b/src/licensedcode/data/rules/other-permissive_340.RULE @@ -0,0 +1,5 @@ +Redistribution of this material is permitted so long as this notice and +the corresponding notices within each POSIX manual page are retained on +any distribution, and the nroff source is included. Modifications to +the text are permitted so long as any conflicts with the standard +are clearly marked as such in the text. \ No newline at end of file diff --git a/src/licensedcode/data/rules/other-permissive_340.yml b/src/licensedcode/data/rules/other-permissive_340.yml new file mode 100644 index 00000000000..426d048c52f --- /dev/null +++ b/src/licensedcode/data/rules/other-permissive_340.yml @@ -0,0 +1,2 @@ +license_expression: other-permissive +is_license_notice: yes diff --git a/src/licensedcode/data/rules/perserve2.RULE b/src/licensedcode/data/rules/perserve2.RULE index 68da2fcbca0..ba2191a9e96 100644 --- a/src/licensedcode/data/rules/perserve2.RULE +++ b/src/licensedcode/data/rules/perserve2.RULE @@ -1,2 +1,2 @@ -is available under *either* the terms of the modified BSD license *or* the -Academic Free License version 2.1 \ No newline at end of file +is available under *either* the terms of the {{modified BSD license *or* the +Academic Free License version 2.1}} diff --git a/src/licensedcode/data/rules/proprietary-license_692.RULE b/src/licensedcode/data/rules/proprietary-license_692.RULE new file mode 100644 index 00000000000..2a49fad53ef --- /dev/null +++ b/src/licensedcode/data/rules/proprietary-license_692.RULE @@ -0,0 +1,12 @@ +Terms of Use You may freely use these code charts for personal or internal +business uses only. You may not incorporate them either wholly or in part into +any product or publication, or otherwise distribute them without express written +permission from the Unicode Consortium. However, you may provide links to these +charts.The fonts and font data used in production of these Code Charts may NOT +be extracted, or used in any other way in any product or publication, without +permission or license granted by the typeface owner(s). The Unicode Consortium +is not liable for errors or omissions in this file or the standard itself. +Information on characters added to the Unicode Standard since the publication of +the most recent version of the Unicode Standard, as well as on characters +currently being considered for addition to the Unicode Standard can be found on +the Unicode web site \ No newline at end of file diff --git a/src/licensedcode/data/rules/proprietary-license_692.yml b/src/licensedcode/data/rules/proprietary-license_692.yml new file mode 100644 index 00000000000..c0f57d57ccb --- /dev/null +++ b/src/licensedcode/data/rules/proprietary-license_692.yml @@ -0,0 +1,3 @@ +license_expression: proprietary-license +is_license_notice: yes +notes: Seen in http://www.unicode.org/charts//PDF/Unicode-5.0/U50-2B00.pdf diff --git a/src/licensedcode/data/rules/proprietary-license_693.RULE b/src/licensedcode/data/rules/proprietary-license_693.RULE new file mode 100644 index 00000000000..e50a04094be --- /dev/null +++ b/src/licensedcode/data/rules/proprietary-license_693.RULE @@ -0,0 +1,4 @@ +This publication is protected by copy-right, and permission must be +obtained from the publisher prior to any prohibited reproduction, storage +in a retrieval system, or transmission in any form or by any means, +electronic, mechanical, photocopying, recording, or likewise. \ No newline at end of file diff --git a/src/licensedcode/data/rules/proprietary-license_693.yml b/src/licensedcode/data/rules/proprietary-license_693.yml new file mode 100644 index 00000000000..bd5a862e40a --- /dev/null +++ b/src/licensedcode/data/rules/proprietary-license_693.yml @@ -0,0 +1,3 @@ +license_expression: proprietary-license +is_license_notice: yes +notes: Seen in https://www.unicode.org/versions/Unicode5.0.0/Title.pdf diff --git a/src/licensedcode/data/rules/proprietary-license_694.RULE b/src/licensedcode/data/rules/proprietary-license_694.RULE new file mode 100644 index 00000000000..4788cad551f --- /dev/null +++ b/src/licensedcode/data/rules/proprietary-license_694.RULE @@ -0,0 +1 @@ +END USER LICENSE AGREEMENT LICENSE \ No newline at end of file diff --git a/src/licensedcode/data/rules/proprietary-license_694.yml b/src/licensedcode/data/rules/proprietary-license_694.yml new file mode 100644 index 00000000000..c6d898d464a --- /dev/null +++ b/src/licensedcode/data/rules/proprietary-license_694.yml @@ -0,0 +1,3 @@ +license_expression: proprietary-license +is_license_reference: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/proprietary-license_and_warranty-disclaimer_1.RULE b/src/licensedcode/data/rules/proprietary-license_and_warranty-disclaimer_1.RULE new file mode 100644 index 00000000000..73969179bfa --- /dev/null +++ b/src/licensedcode/data/rules/proprietary-license_and_warranty-disclaimer_1.RULE @@ -0,0 +1,5 @@ +DISCLAIMER OF WARRANTY + +THIS SOFTWARE DEVELOPMENT KIT IS SOLD "AS IS" AND WITHOUT WARRANTIES AS TO PERFORMANCE OR MERCHANTABILITY. + +THIS SOFTWARE DEVELOPMENT KIT IS SOLD WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES WHATSOEVER. BECAUSE OF THE DIVERSITY OF CONDITIONS AND HARDWARE UNDER WHICH THIS SOFTWARE DEVELOPMENT KIT MAY BE USED, NO WARRANTY OF FITNESS FOR A PARTICULAR PURPOSE IS OFFERED. THE USER IS ADVISED TO TEST THE SOFTWARE DEVELOPMENT KIT THOROUGHLY BEFORE RELYING ON IT. THE USER MUST ASSUME THE ENTIRE RISK OF USING THE SOFTWARE DEVELOPMENT KIT. ANY LIABILITY OF SELLER OR MANUFACTURER WILL BE LIMITED EXCLUSIVELY TO PRODUCT REPLACEMENT OR REFUND OF THE PURCHASE PRICE. \ No newline at end of file diff --git a/src/licensedcode/data/rules/proprietary-license_and_warranty-disclaimer_1.yml b/src/licensedcode/data/rules/proprietary-license_and_warranty-disclaimer_1.yml new file mode 100644 index 00000000000..470cf6984e7 --- /dev/null +++ b/src/licensedcode/data/rules/proprietary-license_and_warranty-disclaimer_1.yml @@ -0,0 +1,2 @@ +license_expression: proprietary-license AND warranty-disclaimer +is_license_notice: yes diff --git a/src/licensedcode/data/rules/public-domain-disclaimer_75.RULE b/src/licensedcode/data/rules/public-domain-disclaimer_75.RULE new file mode 100644 index 00000000000..d9c18e2226f --- /dev/null +++ b/src/licensedcode/data/rules/public-domain-disclaimer_75.RULE @@ -0,0 +1,3 @@ +* This implementation is herby placed in the public domain. + * The author offers no warranty. Use at your own risk. + * Please send bug reports to the author. \ No newline at end of file diff --git a/src/licensedcode/data/rules/public-domain-disclaimer_75.yml b/src/licensedcode/data/rules/public-domain-disclaimer_75.yml new file mode 100644 index 00000000000..552355788cc --- /dev/null +++ b/src/licensedcode/data/rules/public-domain-disclaimer_75.yml @@ -0,0 +1,3 @@ +license_expression: public-domain-disclaimer +is_license_notice: yes +notes: See in https://fastcrypto.org/ diff --git a/src/licensedcode/data/rules/public-domain_440.RULE b/src/licensedcode/data/rules/public-domain_440.RULE new file mode 100644 index 00000000000..b77ebc487b3 --- /dev/null +++ b/src/licensedcode/data/rules/public-domain_440.RULE @@ -0,0 +1 @@ +Public Domain -- Use and Enjoy! \ No newline at end of file diff --git a/src/licensedcode/data/rules/public-domain_440.yml b/src/licensedcode/data/rules/public-domain_440.yml new file mode 100644 index 00000000000..95831078f5e --- /dev/null +++ b/src/licensedcode/data/rules/public-domain_440.yml @@ -0,0 +1,3 @@ +license_expression: public-domain +is_license_text: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/public-domain_441.RULE b/src/licensedcode/data/rules/public-domain_441.RULE new file mode 100644 index 00000000000..6694ce487ca --- /dev/null +++ b/src/licensedcode/data/rules/public-domain_441.RULE @@ -0,0 +1 @@ +LicenseRef-PublicDomain \ No newline at end of file diff --git a/src/licensedcode/data/rules/public-domain_441.yml b/src/licensedcode/data/rules/public-domain_441.yml new file mode 100644 index 00000000000..a41446614f6 --- /dev/null +++ b/src/licensedcode/data/rules/public-domain_441.yml @@ -0,0 +1,3 @@ +license_expression: public-domain +is_license_tag: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/public-domain_442.RULE b/src/licensedcode/data/rules/public-domain_442.RULE new file mode 100644 index 00000000000..0ff269c3262 --- /dev/null +++ b/src/licensedcode/data/rules/public-domain_442.RULE @@ -0,0 +1 @@ +All implementations are in the public-domain and can be used for any purpose whatsoever. All I ask is that you send to me any bugs or suggestions you might come across. \ No newline at end of file diff --git a/src/licensedcode/data/rules/public-domain_442.yml b/src/licensedcode/data/rules/public-domain_442.yml new file mode 100644 index 00000000000..0ae1ea452b8 --- /dev/null +++ b/src/licensedcode/data/rules/public-domain_442.yml @@ -0,0 +1,3 @@ +license_expression: public-domain +is_license_text: yes +notes: See in https://fastcrypto.org/ diff --git a/src/licensedcode/data/rules/public-domain_and_warranty-disclaimer_1.RULE b/src/licensedcode/data/rules/public-domain_and_warranty-disclaimer_1.RULE index 3a0362aa36e..58313a1c4b0 100644 --- a/src/licensedcode/data/rules/public-domain_and_warranty-disclaimer_1.RULE +++ b/src/licensedcode/data/rules/public-domain_and_warranty-disclaimer_1.RULE @@ -1,12 +1,12 @@ -In English: is freeware. is distributed with +In English: is freeware. {{is distributed with no warranty whatsoever. The author and any other contributors -take no responsibility for any and all consequences of its use. +take no responsibility for any and all consequences of its use.}} -In Legalese: LIMITATION OF LIABILITY. NEITHER SYSTEMS -NOR ANY OF ITS LICENSORS NOR ANY BTYACC CONTRIBUTOR SHALL BE -LIABLE FOR ANY INDIRECT, INCIDENTAL, SPECIAL OR CONSEQUENTIAL +In Legalese: {{LIMITATION OF LIABILITY.}} NEITHER SYSTEMS +{{NOR ANY OF ITS LICENSORS NOR ANY}} CONTRIBUTOR SHALL BE +LIABLE FOR ANY INDIRECT, INCIDENTAL, {{SPECIAL OR CONSEQUENTIAL DAMAGES, OR DAMAGES FOR LOSS OF PROFITS, REVENUE, DATA OR DATA USE, CAUSED BY AND INCURRED BY CUSTOMER OR ANY THIRD PARTY, WHETHER IN AN ACTION IN CONTRACT OR TORT, EVEN IF SYSTEMS HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH -DAMAGES. \ No newline at end of file +DAMAGES.}} diff --git a/src/licensedcode/data/rules/public-domain_and_warranty-disclaimer_1.yml b/src/licensedcode/data/rules/public-domain_and_warranty-disclaimer_1.yml index a94670bf5a6..b06220e7c8b 100644 --- a/src/licensedcode/data/rules/public-domain_and_warranty-disclaimer_1.yml +++ b/src/licensedcode/data/rules/public-domain_and_warranty-disclaimer_1.yml @@ -1,4 +1,4 @@ -license_expression: public-domain AND warranty-disclaimer +license_expression: other-permissive is_license_notice: yes relevance: 100 notes: https://www.siber.com/btyacc/README.txt diff --git a/src/licensedcode/data/rules/reportbug_1.yml b/src/licensedcode/data/rules/reportbug_1.yml index 55533e0c74f..41d228bf425 100644 --- a/src/licensedcode/data/rules/reportbug_1.yml +++ b/src/licensedcode/data/rules/reportbug_1.yml @@ -1,3 +1,5 @@ license_expression: reportbug is_license_text: yes relevance: 100 +minimum_coverage: 60 + diff --git a/src/licensedcode/data/rules/spdx_license_id_imlib2_for_imlib2.RULE b/src/licensedcode/data/rules/spdx_license_id_imlib2_for_imlib2.RULE deleted file mode 100644 index 1c681089c93..00000000000 --- a/src/licensedcode/data/rules/spdx_license_id_imlib2_for_imlib2.RULE +++ /dev/null @@ -1 +0,0 @@ -imlib2 \ No newline at end of file diff --git a/src/licensedcode/data/rules/spdx_license_id_imlib2_for_imlib2.yml b/src/licensedcode/data/rules/spdx_license_id_imlib2_for_imlib2.yml deleted file mode 100644 index 8f6b50385c7..00000000000 --- a/src/licensedcode/data/rules/spdx_license_id_imlib2_for_imlib2.yml +++ /dev/null @@ -1,6 +0,0 @@ -license_expression: imlib2 -is_license_reference: yes -is_continuous: yes -relevance: 50 -minimum_coverage: 100 -notes: Used to detect a bare SPDX license id diff --git a/src/licensedcode/data/rules/sugarcrm-1.1.3_10.RULE b/src/licensedcode/data/rules/sugarcrm-1.1.3_10.RULE new file mode 100644 index 00000000000..59f4fdfb358 --- /dev/null +++ b/src/licensedcode/data/rules/sugarcrm-1.1.3_10.RULE @@ -0,0 +1,392 @@ +{{SUGARCRM PUBLIC LICENSE}} Applies to Sugar Open Source Edition v1 through v4. +Please note that these releases are no longer supported or distributed. + +{{Version 1.1.3}} + +The {{SugarCRM Public License}} Version ("SPL") consists of the Mozilla Public +License Version 1.1, modified to be specific to SugarCRM, with the Additional +Terms in Exhibit B. The original Mozilla Public License 1.1 can be found at: +http://www.mozilla.org/MPL/MPL-1.1.html + + 1. Definitions. + +1.1. "Contributor" means each entity that creates or contributes to the creation +of Modifications. + +1.2. "Contributor Version" means the combination of the Original Code, prior +Modifications used by a Contributor, and the Modifications made by that particular +Contributor. + +1.3. "Covered Code" means the Original Code or Modifications or the combination +of the Original Code and Modifications, in each case including portions thereof. + +1.4. "Electronic Distribution Mechanism" means a mechanism generally accepted +in the software development community for the electronic transfer of data. + + 1.5. "Executable" means Covered Code in any form other than Source Code. + +1.6. "Initial Developer" means the individual or entity identified as the +Initial Developer in the Source Code notice required by Exhibit A. + +1.7. "Larger Work" means a work which combines Covered Code or portions thereof +with code not governed by the terms of this License. + + 1.8. "License" means this document. + +1.8.1. "Licensable" means having the right to grant, to the maximum extent +possible, whether at the time of the initial grant or subsequently acquired, +any and all of the rights conveyed herein. + +1.9. "Modifications" means any addition to or deletion from the substance +or structure of either the Original Code or any previous Modifications. When +Covered Code is released as a series of files, a Modification is: + +B. Any new file that contains any part of the Original Code or previous Modifications. + +A. Any addition to or deletion from the contents of a file containing Original +Code or previous Modifications. + +1.10. "Original Code" means Source Code of computer software code which is +described in the Source Code notice required by Exhibit A as Original Code, +and which, at the time of its release under this License is not already Covered +Code governed by this License. + +1.10.1. "Patent Claims" means any patent claim(s), now owned or hereafter +acquired, including without limitation, method, process, and apparatus claims, +in any patent Licensable by grantor. + +1.11. "Source Code" means the preferred form of the Covered Code for making +modifications to it, including all modules it contains, plus any associated +interface definition files, scripts used to control compilation and installation +of an Executable, or source code differential comparisons against either the +Original Code or another well known, available Covered Code of the Contributor's +choice. The Source Code can be in a compressed or archival form, provided +the appropriate decompression or de-archiving software is widely available +for no charge. + +1.12. "You" (or "Your") means an individual or a legal entity exercising rights +under, and complying with all of the terms of, this License or a future version +of this License issued under Section 6.1. For legal entities, "You" includes +any entity which controls, is controlled by, or is under common control with +You. For purposes of this definition, "control" means (a) the power, direct +or indirect, to cause the direction or management of such entity, whether +by contract or otherwise, or (b) ownership of more than fifty percent (50%) +of the outstanding shares or beneficial ownership of such entity. + + 2. Source Code License. + + 2.2. Contributor Grant. + +Subject to third party intellectual property claims, each Contributor hereby +grants You a world-wide, royalty-free, non-exclusive license + +(b) under Patent Claims infringed by the making, using, or selling of Modifications +made by that Contributor either alone and/or in combination with its Contributor +Version (or portions of such combination), to make, use, sell, offer for sale, +have made, and/or otherwise dispose of: 1) Modifications made by that Contributor +(or portions thereof); and 2) the combination of Modifications made by that +Contributor with its Contributor Version (or portions of such combination). + +(c) the licenses granted in Sections 2.2(a) and 2.2(b) are effective on the +date Contributor first makes Commercial Use of the Covered Code. + +(d) Notwithstanding Section 2.2(b) above, no patent license is granted: 1) +for any code that Contributor has deleted from the Contributor Version; 2) +separate from the Contributor Version; 3) for infringements caused by: i) +third party modifications of Contributor Version or ii) the combination of +Modifications made by that Contributor with other software (except as part +of the Contributor Version) or other devices; or 4) under Patent Claims infringed +by Covered Code in the absence of Modifications made by that Contributor. + +(a) under intellectual property rights (other than patent or trademark) Licensable +by Contributor, to use, reproduce, modify, display, perform, sublicense and +distribute the Modifications created by such Contributor (or portions thereof) +either on an unmodified basis, with other Modifications, as Covered Code and/or +as part of a Larger Work; and + + 3. Distribution Obligations. + +3.2. Availability of Source Code. Any Modification which You create or to +which You contribute must be made available in Source Code form under the +terms of this License either on the same media as an Executable version or +via an accepted Electronic Distribution Mechanism to anyone to whom you made +an Executable version available; and if made available via Electronic Distribution +Mechanism, must remain available for at least twelve (12) months after the +date it initially became available, or at least six (6) months after a subsequent +version of that particular Modification has been made available to such recipients. +You are responsible for ensuring that the Source Code version remains available +even if the Electronic Distribution Mechanism is maintained by a third party. + +3.3. Description of Modifications. You must cause all Covered Code to which +You contribute to contain a file documenting the changes You made to create +that Covered Code and the date of any change. You must include a prominent +statement that the Modification is derived, directly or indirectly, from Original +Code provided by the Initial Developer and including the name of the Initial +Developer in (a) the Source Code, and (b) in any notice in an Executable version +or related documentation in which You describe the origin or ownership of +the Covered Code. + + 3.4. Intellectual Property Matters + +(b) Contributor APIs. If Contributor's Modifications include an application +programming interface and Contributor has knowledge of patent licenses which +are reasonably necessary to implement that API, Contributor must also include +this information in the LEGAL file. + +(a) Third Party Claims. If Contributor has knowledge that a license under +a third party's intellectual property rights is required to exercise the rights +granted by such Contributor under Sections 2.1 or 2.2, Contributor must include +a text file with the Source Code distribution titled "LEGAL" which describes +the claim and the party making the claim in sufficient detail that a recipient +will know whom to contact. If Contributor obtains such knowledge after the +Modification is made available as described in Section 3.2, Contributor shall +promptly modify the LEGAL file in all copies Contributor makes available thereafter +and shall take other steps (such as notifying appropriate mailing lists or +newsgroups) reasonably calculated to inform those who received the Covered +Code that new knowledge has been obtained. + +(c) Representations. Contributor represents that, except as disclosed pursuant +to Section 3.4(a) above, Contributor believes that Contributor's Modifications +are Contributor's original creation(s) and/or Contributor has sufficient rights +to grant the rights conveyed by this License. + +3.5. Required Notices. You must duplicate the notice in Exhibit A in each +file of the Source Code. If it is not possible to put such notice in a particular +Source Code file due to its structure, then You must include such notice in +a location (such as a relevant directory) where a user would be likely to +look for such a notice. If You created one or more Modification(s) You may +add your name as a Contributor to the notice described in Exhibit A. You must +also duplicate this License in any documentation for the Source Code where +You describe recipients' rights or ownership rights relating to Covered Code. +You may choose to offer, and to charge a fee for, warranty, support, indemnity +or liability obligations to one or more recipients of Covered Code. However, +You may do so only on Your own behalf, and not on behalf of the Initial Developer +or any Contributor. You must make it absolutely clear than any such warranty, +support, indemnity or liability obligation is offered by You alone, and You +hereby agree to indemnify the Initial Developer and every Contributor for +any liability incurred by the Initial Developer or such Contributor as a result +of warranty, support, indemnity or liability terms You offer. + +3.6. Distribution of Executable Versions. You may distribute Covered Code +in Executable form only if the requirements of Section 3.1-3.5 have been met +for that Covered Code, and if You include a notice stating that the Source +Code version of the Covered Code is available under the terms of this License, +including a description of how and where You have fulfilled the obligations +of Section 3.2. The notice must be conspicuously included in any notice in +an Executable version, related documentation or collateral in which You describe +recipients' rights relating to the Covered Code. You may distribute the Executable +version of Covered Code or ownership rights under a license of Your choice, +which may contain terms different from this License, provided that You are +in compliance with the terms of this License and that the license for the +Executable version does not attempt to limit or alter the recipient's rights +in the Source Code version from the rights set forth in this License. If You +distribute the Executable version under a different license You must make +it absolutely clear that any terms which differ from this License are offered +by You alone, not by the Initial Developer or any Contributor. You hereby +agree to indemnify the Initial Developer and every Contributor for any liability +incurred by the Initial Developer or such Contributor as a result of any such +terms You offer. + +3.7. Larger Works. You may create a Larger Work by combining Covered Code +with other code not governed by the terms of this License and distribute the +Larger Work as a single product. In such a case, You must make sure the requirements +of this License are fulfilled for the Covered Code. + + 4. Inability to Comply Due to Statute or Regulation. + +If it is impossible for You to comply with any of the terms of this License +with respect to some or all of the Covered Code due to statute, judicial order, +or regulation then You must: (a) comply with the terms of this License to +the maximum extent possible; and (b) describe the limitations and the code +they affect. Such description must be included in the LEGAL file described +in Section 3.4 and must be included with all distributions of the Source Code. +Except to the extent prohibited by statute or regulation, such description +must be sufficiently detailed for a recipient of ordinary skill to be able +to understand it. + + 5. Application of this License. + +This License applies to code to which the Initial Developer has attached the +notice in Exhibit A and to related Covered Code. + + 6. Versions of the License. + +6.2. Effect of New Versions. Once Covered Code has been published under a +particular version of the License, You may always continue to use it under +the terms of that version. You may also choose to use such Covered Code under +the terms of any subsequent version of the License published by SugarCRM. +No one other than SugarCRM has the right to modify the terms applicable to +Covered Code created under this License. + +6.3. Derivative Works. If You create or use a modified version of this License +(which you may only do in order to apply it to code which is not already Covered +Code governed by this License), You must (a) rename Your license so that the +phrases "SugarCRM", "SPL" or any confusingly similar phrase do not appear +in your license (except to note that your license differs from this License) +and (b) otherwise make it clear that Your version of the license contains +terms which differ from the SugarCRM Public License. (Filling in the name +of the Initial Developer, Original Code or Contributor in the notice described +in Exhibit A shall not of themselves be deemed to be modifications of this +License.) + + 7. DISCLAIMER OF WARRANTY. + +COVERED CODE IS PROVIDED UNDER THIS LICENSE ON AN "AS IS" BASIS, WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, WITHOUT LIMITATION, WARRANTIES +THAT THE COVERED CODE IS FREE OF DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR +PURPOSE OR NON-INFRINGING. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE +OF THE COVERED CODE IS WITH YOU. SHOULD ANY COVERED CODE PROVE DEFECTIVE IN +ANY RESPECT, YOU (NOT THE INITIAL DEVELOPER OR ANY OTHER CONTRIBUTOR) ASSUME +THE COST OF ANY NECESSARY SERVICING, REPAIR OR CORRECTION. THIS DISCLAIMER +OF WARRANTY CONSTITUTES AN ESSENTIAL PART OF THIS LICENSE. NO USE OF ANY COVERED +CODE IS AUTHORIZED HEREUNDER EXCEPT UNDER THIS DISCLAIMER. + + 8. TERMINATION. + +8.2. If You initiate litigation by asserting a patent infringement claim (excluding +declatory judgment actions) against Initial Developer or a Contributor (the +Initial Developer or Contributor against whom You file such action is referred +to as "Participant") alleging that: + +(a) such Participant's Contributor Version directly or indirectly infringes +any patent, then any and all rights granted by such Participant to You under +Sections 2.1 and/or 2.2 of this License shall, upon 60 days notice from Participant +terminate prospectively, unless if within 60 days after receipt of notice +You either: (i) agree in writing to pay Participant a mutually agreeable reasonable +royalty for Your past and future use of Modifications made by such Participant, +or (ii) withdraw Your litigation claim with respect to the Contributor Version +against such Participant. If within 60 days of notice, a reasonable royalty +and payment arrangement are not mutually agreed upon in writing by the parties +or the litigation claim is not withdrawn, the rights granted by Participant +to You under Sections 2.1 and/or 2.2 automatically terminate at the expiration +of the 60 day notice period specified above. + +(b) any software, hardware, or device, other than such Participant's Contributor +Version, directly or indirectly infringes any patent, then any rights granted +to You by such Participant under Sections 2.1(b) and 2.2(b) are revoked effective +as of the date You first made, used, sold, distributed, or had made, Modifications +made by that Participant. + +8.3. If You assert a patent infringement claim against Participant alleging +that such Participant's Contributor Version directly or indirectly infringes +any patent where such claim is resolved (such as by license or settlement) +prior to the initiation of patent infringement litigation, then the reasonable +value of the licenses granted by such Participant under Sections 2.1 or 2.2 +shall be taken into account in determining the amount or value of any payment +or license. + +8.4. In the event of termination under Sections 8.1 or 8.2 above, all end +user license agreements (excluding distributors and resellers) which have +been validly granted by You or any distributor hereunder prior to termination +shall survive termination. + + 9. LIMITATION OF LIABILITY. + +UNDER NO CIRCUMSTANCES AND UNDER NO LEGAL THEORY, WHETHER TORT (INCLUDING +NEGLIGENCE), CONTRACT, OR OTHERWISE, SHALL YOU, THE INITIAL DEVELOPER, ANY +OTHER CONTRIBUTOR, OR ANY DISTRIBUTOR OF COVERED CODE, OR ANY SUPPLIER OF +ANY OF SUCH PARTIES, BE LIABLE TO ANY PERSON FOR ANY INDIRECT, SPECIAL, INCIDENTAL, +OR CONSEQUENTIAL DAMAGES OF ANY CHARACTER INCLUDING, WITHOUT LIMITATION, DAMAGES +FOR LOSS OF GOODWILL, WORK STOPPAGE, COMPUTER FAILURE OR MALFUNCTION, OR ANY +AND ALL OTHER COMMERCIAL DAMAGES OR LOSSES, EVEN IF SUCH PARTY SHALL HAVE +BEEN INFORMED OF THE POSSIBILITY OF SUCH DAMAGES. THIS LIMITATION OF LIABILITY +SHALL NOT APPLY TO LIABILITY FOR DEATH OR PERSONAL INJURY RESULTING FROM SUCH +PARTY'S NEGLIGENCE TO THE EXTENT APPLICABLE LAW PROHIBITS SUCH LIMITATION. +SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OR LIMITATION OF INCIDENTAL +OR CONSEQUENTIAL DAMAGES, SO THIS EXCLUSION AND LIMITATION MAY NOT APPLY TO +YOU. + + 10. U.S. GOVERNMENT END USERS. + +The Covered Code is a "commercial item," as that term is defined in 48 C.F.R. +2.101 (Oct. 1995), consisting of "commercial computer software" and "commercial +computer software documentation," as such terms are used in 48 C.F.R. 12.212 +(Sept. 1995). Consistent with 48 C.F.R. 12.212 and 48 C.F.R. 227.7202-1 through +227.7202-4 (June 1995), all U.S. Government End Users acquire Covered Code +with only those rights set forth herein. + + 11. MISCELLANEOUS. + +This License represents the complete agreement concerning subject matter hereof. +If any provision of this License is held to be unenforceable, such provision +shall be reformed only to the extent necessary to make it enforceable. This +License shall be governed by California law provisions (except to the extent +applicable law, if any, provides otherwise), excluding its conflict-of-law +provisions. With respect to disputes in which at least one party is a citizen +of, or an entity chartered or registered to do business in the United States +of America, any litigation relating to this License shall be subject to the +jurisdiction of the Federal Courts of the Northern District of California, +with venue lying in Santa Clara County, California, with the losing party +responsible for costs, including without limitation, court costs and reasonable +attorneys' fees and expenses. The application of the United Nations Convention +on Contracts for the International Sale of Goods is expressly excluded. Any +law or regulation which provides that the language of a contract shall be +construed against the drafter shall not apply to this License. + + 12. RESPONSIBILITY FOR CLAIMS. + +As between Initial Developer and the Contributors, each party is responsible +for claims and damages arising, directly or indirectly, out of its utilization +of rights under this License and You agree to work with Initial Developer +and Contributors to distribute such responsibility on an equitable basis. +Nothing herein is intended or shall be deemed to constitute any admission +of liability. + + 13. MULTIPLE-LICENSED CODE. + +Initial Developer may designate portions of the Covered Code as "Multiple-Licensed". +"Multiple-Licensed" means that the Initial Developer permits you to utilize +portions of the Covered Code under Your choice of the SPL or the alternative +licenses, if any, specified by the Initial Developer in the file described +in Exhibit A. SugarCRM Public License 1.1.3 - Exhibit A + +The contents of this file are subject to the SugarCRM Public License Version +1.1.3 ("License"); You may not use this file except in compliance with the +License. You may obtain a copy of the License at http://www.sugarcrm.com/SPL +Software distributed under the License is distributed on an "AS IS" basis, +WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for +the specific language governing rights and limitations under the License. + +The Original Code is: SugarCRM Open Source + +The Initial Developer of the Original Code is SugarCRM, Inc. + +Portions created by SugarCRM are Copyright (C) 2004 SugarCRM, Inc.; + +All Rights Reserved. + +Contributor(s): ______________________________________. + +[NOTE: The text of this Exhibit A may differ slightly from the text of the +notices in the Source Code files of the Original Code. You should use the +text of this Exhibit A rather than the text found in the Original Code Source +Code for Your Modifications.] + +SugarCRM Public License 1.1.3 - Exhibit B + +Additional Terms applicable to the SugarCRM Public License. + + I. Effect., + +These additional terms described in this SugarCRM Public License - Additional +Terms shall apply to the Covered Code under this License. + + II. SugarCRM and logo. + +This License does not grant any rights to use the trademarks "SugarCRM" and +the "SugarCRM" logos even if such marks are included in the Original Code +or Modifications. + +However, in addition to the other notice obligations, all copies of the Covered +Code in Executable and Source Code form distributed must, as a form of attribution +of the original author, include on each user interface screen (i) the "Powered +by SugarCRM" logo and (ii) the copyright notice in the same form as the latest +version of the Covered Code distributed by SugarCRM, Inc. at the time of distribution +of such copy. In addition, the "Powered by SugarCRM" logo must be visible +to all users and be located at the very bottom center of each user interface +screen. Notwithstanding the above, the dimensions of the "Powered By SugarCRM" +logo must be at least 106 x 23 pixels. When users click on the "Powered by +SugarCRM" logo it must direct them back to http://www.sugarforge.org. In addition, +the copyright notice must remain visible to all users at all times at the +bottom of the user interface screen. When users click on the copyright notice, +it must direct them back to http://www.sugarcrm.com \ No newline at end of file diff --git a/src/licensedcode/data/rules/sugarcrm-1.1.3_10.yml b/src/licensedcode/data/rules/sugarcrm-1.1.3_10.yml new file mode 100644 index 00000000000..e6c0866d328 --- /dev/null +++ b/src/licensedcode/data/rules/sugarcrm-1.1.3_10.yml @@ -0,0 +1,12 @@ +license_expression: sugarcrm-1.1.3 +is_license_text: yes +minimum_coverage: 95 +ignorable_copyrights: + - Copyright (c) 2004 SugarCRM, Inc. +ignorable_holders: + - SugarCRM, Inc. +ignorable_urls: + - http://www.mozilla.org/MPL/MPL-1.1.html + - http://www.sugarcrm.com/ + - http://www.sugarcrm.com/SPL + - http://www.sugarforge.org/ diff --git a/src/licensedcode/data/rules/sun-rpc_1.RULE b/src/licensedcode/data/rules/sun-rpc_1.RULE new file mode 100644 index 00000000000..38399c9c04c --- /dev/null +++ b/src/licensedcode/data/rules/sun-rpc_1.RULE @@ -0,0 +1,7 @@ +Sun Microsystems ( Sun RPC ) + +Sun RPC is a product of Sun Microsystems, Inc. and is provided for unrestricted use provided that this legend is included on all tape media and as a part of the software program in whole or part. Users may copy or modify Sun RPC without charge, but are not authorized to license or distribute it to anyone else except as part of a product or program developed by the user or with the express written consent of Sun Microsystems, Inc. Sun RPC is provided with no support and without any obligation on the part of Sun Microsystems, Inc. to assist in its use, correction, modification or enhancement. + +SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC OR ANY PART THEREOF. + +In no event will Sun Microsystems, Inc. be liable for any lost revenue or profits or other special, indirect and consequential damages, even if Sun has been advised of the possibility of such damages. Sun Microsystems, Inc. 2550 Garcia Avenue Mountain View, California¬† 94043. \ No newline at end of file diff --git a/src/licensedcode/data/rules/sun-rpc_1.yml b/src/licensedcode/data/rules/sun-rpc_1.yml new file mode 100644 index 00000000000..05177475a55 --- /dev/null +++ b/src/licensedcode/data/rules/sun-rpc_1.yml @@ -0,0 +1,4 @@ +license_expression: sun-rpc +is_license_text: yes +relevance: 95 +notes: adds an extra "or with the express written consent of Sun Microsystems, Inc." permission diff --git a/src/licensedcode/data/rules/unknown-license-reference_341.RULE b/src/licensedcode/data/rules/unknown-license-reference_341.RULE new file mode 100644 index 00000000000..a69ffe5f404 --- /dev/null +++ b/src/licensedcode/data/rules/unknown-license-reference_341.RULE @@ -0,0 +1 @@ +protected by copyright \ No newline at end of file diff --git a/src/licensedcode/data/rules/unknown-license-reference_341.yml b/src/licensedcode/data/rules/unknown-license-reference_341.yml new file mode 100644 index 00000000000..ddd0ee2c1d7 --- /dev/null +++ b/src/licensedcode/data/rules/unknown-license-reference_341.yml @@ -0,0 +1,3 @@ +license_expression: unknown-license-reference +is_license_reference: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/unknown-license-reference_342.RULE b/src/licensedcode/data/rules/unknown-license-reference_342.RULE new file mode 100644 index 00000000000..eefd59c0860 --- /dev/null +++ b/src/licensedcode/data/rules/unknown-license-reference_342.RULE @@ -0,0 +1 @@ +may be copied or reproduced for commercial purposes without the express written permission \ No newline at end of file diff --git a/src/licensedcode/data/rules/unknown-license-reference_342.yml b/src/licensedcode/data/rules/unknown-license-reference_342.yml new file mode 100644 index 00000000000..45999dad3b3 --- /dev/null +++ b/src/licensedcode/data/rules/unknown-license-reference_342.yml @@ -0,0 +1,4 @@ +license_expression: unknown-license-reference +is_license_reference: yes +is_continuous: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/unknown-license-reference_343.RULE b/src/licensedcode/data/rules/unknown-license-reference_343.RULE new file mode 100644 index 00000000000..84e08021874 --- /dev/null +++ b/src/licensedcode/data/rules/unknown-license-reference_343.RULE @@ -0,0 +1 @@ +without the express written permission \ No newline at end of file diff --git a/src/licensedcode/data/rules/unknown-license-reference_343.yml b/src/licensedcode/data/rules/unknown-license-reference_343.yml new file mode 100644 index 00000000000..45999dad3b3 --- /dev/null +++ b/src/licensedcode/data/rules/unknown-license-reference_343.yml @@ -0,0 +1,4 @@ +license_expression: unknown-license-reference +is_license_reference: yes +is_continuous: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/unknown-license-reference_344.RULE b/src/licensedcode/data/rules/unknown-license-reference_344.RULE new file mode 100644 index 00000000000..704bd09d4ba --- /dev/null +++ b/src/licensedcode/data/rules/unknown-license-reference_344.RULE @@ -0,0 +1 @@ +may change these terms from time to time \ No newline at end of file diff --git a/src/licensedcode/data/rules/unknown-license-reference_344.yml b/src/licensedcode/data/rules/unknown-license-reference_344.yml new file mode 100644 index 00000000000..45999dad3b3 --- /dev/null +++ b/src/licensedcode/data/rules/unknown-license-reference_344.yml @@ -0,0 +1,4 @@ +license_expression: unknown-license-reference +is_license_reference: yes +is_continuous: yes +relevance: 100 diff --git a/src/licensedcode/data/rules/unknown-license-reference_345.RULE b/src/licensedcode/data/rules/unknown-license-reference_345.RULE new file mode 100644 index 00000000000..acc7562139b --- /dev/null +++ b/src/licensedcode/data/rules/unknown-license-reference_345.RULE @@ -0,0 +1,3 @@ +All source code included in this distribution is covered by this notice, unless +specifically stated otherwise within each file. See each file within each release for +specific copyright holders. \ No newline at end of file diff --git a/src/licensedcode/data/rules/unknown-license-reference_345.yml b/src/licensedcode/data/rules/unknown-license-reference_345.yml new file mode 100644 index 00000000000..570ff67db4b --- /dev/null +++ b/src/licensedcode/data/rules/unknown-license-reference_345.yml @@ -0,0 +1,2 @@ +license_expression: unknown-license-reference +is_license_reference: yes diff --git a/src/licensedcode/data/rules/us-govt-public-domain_7.RULE b/src/licensedcode/data/rules/us-govt-public-domain_7.RULE index 42e2d8ad8d5..9545c564598 100644 --- a/src/licensedcode/data/rules/us-govt-public-domain_7.RULE +++ b/src/licensedcode/data/rules/us-govt-public-domain_7.RULE @@ -1 +1 @@ -Pursuant to federal law, government-produced materials appearing on this site are not copyright protected. \ No newline at end of file +Pursuant to federal law, {{government-produced materials appearing on this site are not copyright protected.}} diff --git a/src/licensedcode/data/rules/vhfpl-1.1_1.RULE b/src/licensedcode/data/rules/vhfpl-1.1_1.RULE index a0b03122e42..a694e0d8cfb 100644 --- a/src/licensedcode/data/rules/vhfpl-1.1_1.RULE +++ b/src/licensedcode/data/rules/vhfpl-1.1_1.RULE @@ -1,4 +1,4 @@ -Cenon is free software and is licensed under the vhf Public License (vhfPL). +Cenon is free software and is {{licensed under the vhf Public License}} (vhfPL). See the file LICENSE for details. You are allowed to use and distribute Cenon as a whole. You are allowed to use and modify the source codes of Cenon under the @@ -16,4 +16,4 @@ All trademarks are the property of the respective owners. For uses of this software which do not fall under the definitions laid down in the vhf Public License, a commercial license must -be contracted by the developer/distributor with the copyright holder. \ No newline at end of file +be contracted by the developer/distributor with the copyright holder. diff --git a/src/licensedcode/data/rules/warranty-disclaimer_60.RULE b/src/licensedcode/data/rules/warranty-disclaimer_60.RULE index 42cd97f7a88..0e4d51dc31c 100644 --- a/src/licensedcode/data/rules/warranty-disclaimer_60.RULE +++ b/src/licensedcode/data/rules/warranty-disclaimer_60.RULE @@ -1,2 +1,2 @@ -provided "as-is" and without warranty of any kind, express, implied or otherwise, including without limitation, any warranty of merchantability or fitness for a particular purpose. -In no event shall the author of this software be held liable for data loss, damages, loss of profits or any other kind of loss while using or misusing this software. \ No newline at end of file +{{provided "as-is" and without warranty of any kind}}, express, implied or otherwise, including without limitation, any warranty of merchantability or fitness for a particular purpose. +In no event shall the author of this software be held liable for data loss, damages, loss of profits or any other kind of loss while using or misusing this software. diff --git a/src/licensedcode/data/rules/warranty-disclaimer_9.RULE b/src/licensedcode/data/rules/warranty-disclaimer_9.RULE index 96c623832a0..b72b16a06ee 100644 --- a/src/licensedcode/data/rules/warranty-disclaimer_9.RULE +++ b/src/licensedcode/data/rules/warranty-disclaimer_9.RULE @@ -1,4 +1,4 @@ -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +{{THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND}}, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR diff --git a/src/licensedcode/data/rules/x11-bitstream_3.RULE b/src/licensedcode/data/rules/x11-bitstream_3.RULE index 31fb96fdc41..5b3cad07ed0 100644 --- a/src/licensedcode/data/rules/x11-bitstream_3.RULE +++ b/src/licensedcode/data/rules/x11-bitstream_3.RULE @@ -1,9 +1,9 @@ -You are hereby granted permission under all Bitstream propriety rights -to use, copy, modify, sublicense, sell, and redistribute the 4 Bitstream -Charter (r) Type 1 outline fonts and the 4 Courier Type 1 outline fonts -for any purpose and without restriction; provided, that this notice is +You are hereby {{granted permission under all Bitstream propriety rights +to use, copy, modify, sublicense, sell, and redistribute}} the 4 Bitstream +Charter (r) Type 1 outline {{fonts}} and the 4 Courier Type 1 outline fonts +for {{any purpose and without restriction}}; provided, that this notice is left intact on all copies of such fonts and that Bitstream's trademark is acknowledged as shown below on all unmodified copies of the 4 Charter Type 1 fonts. -BITSTREAM CHARTER is a registered trademark of Bitstream Inc. \ No newline at end of file +BITSTREAM CHARTER is a registered trademark of Bitstream Inc. diff --git a/src/licensedcode/data/rules/x11-tiff_4.RULE b/src/licensedcode/data/rules/x11-tiff_4.RULE index f90c0bedfcf..79842cd5de3 100644 --- a/src/licensedcode/data/rules/x11-tiff_4.RULE +++ b/src/licensedcode/data/rules/x11-tiff_4.RULE @@ -1,9 +1,9 @@ -The licence agreement for this file is the same as the rest of the LibTiff +{{The licence agreement for this file is the same as the rest of the LibTiff library. - +}} IN NO EVENT SHALL BE LIABLE FOR ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE -OF THIS SOFTWARE. \ No newline at end of file +OF THIS SOFTWARE. diff --git a/src/licensedcode/detection.py b/src/licensedcode/detection.py index f47509cc3e6..a511b62d6ea 100644 --- a/src/licensedcode/detection.py +++ b/src/licensedcode/detection.py @@ -245,8 +245,8 @@ def matched_text( self, whole_lines=False, highlight=True, - highlight_matched=u'%s', - highlight_not_matched=u'[%s]', + highlight_matched='{}', + highlight_not_matched='[{}]', ): """ Return the matched text for this detection, combining texts from all diff --git a/src/licensedcode/index.py b/src/licensedcode/index.py index 651b81b1b4a..0c9b48332d6 100644 --- a/src/licensedcode/index.py +++ b/src/licensedcode/index.py @@ -28,10 +28,12 @@ from licensedcode import match_seq from licensedcode import match_set from licensedcode import match_spdx_lid +from licensedcode import match_unknown from licensedcode.dmp import match_blocks as match_blocks_dmp from licensedcode.seq import match_blocks as match_blocks_seq from licensedcode import query from licensedcode import tokenize +from licensedcode.spans import Span """ Main license index construction, query processing and matching entry points for @@ -135,6 +137,7 @@ class LicenseIndex(object): 'rules_automaton', 'fragments_automaton', 'starts_automaton', + 'unknown_automaton', 'regular_rids', 'false_positive_rids', @@ -199,6 +202,7 @@ def __init__( self.rules_automaton = match_aho.get_automaton() self.fragments_automaton = USE_AHO_FRAGMENTS and match_aho.get_automaton() self.starts_automaton = USE_RULE_STARTS and match_aho.get_automaton() + self.unknown_automaton = match_unknown.get_automaton() # disjunctive sets of rule ids: regular and false positive @@ -358,12 +362,16 @@ def _add_rules( tids_by_rid_append(rule_token_ids) rule_token_ids_append = rule_token_ids.append + rule_tokens = [] + rule_tokens_append = rule_tokens.append + # A rule is weak if it does not contain at least one legalese word: # we consider all rules to be weak until proven otherwise below. # "weak" rules can only be matched with an automaton. is_weak = True for rts in rule.tokens(): + rule_tokens_append(rts) rtid = dictionary_get(rts) if rtid is None: # we have a never yet seen token, so we assign a new tokenid @@ -376,7 +384,8 @@ def _add_rules( rule_token_ids_append(rtid) - is_tiny = rule.length < TINY_RULE + rule_length = rule.length + is_tiny = rule_length < TINY_RULE # build hashes index and check for duplicates rule texts rule_hash = match_hash_index_hash(rule_token_ids) @@ -408,6 +417,17 @@ def _add_rules( if rule_token_ids[0] in license_tokens: rule.starts_with_license = True + # populate unknown_automaton that only makes sense for rules that + # are also sequence matchable. + #################### + match_unknown.add_ngrams( + automaton=self.unknown_automaton, + tids=rule_token_ids, + tokens=rule_tokens, + len_legalese=len_legalese, + rule_length=rule_length, + ) + # Some rules that cannot be matched as a sequence are "weak" rules # or can require to be matched only as a continuous sequence of # tokens. This includes, tiny, is_continuous or is_license_reference @@ -443,7 +463,7 @@ def _add_rules( #################### if (USE_AHO_FRAGMENTS and rule.minimum_coverage < 100 - and rule.length > ngram_len + and rule_length > ngram_len ): all_ngrams = tokenize.ngrams(rule_token_ids, ngram_length=ngram_len) all_ngrams_with_pos = tokenize.select_ngrams(all_ngrams, with_pos=True) @@ -454,11 +474,11 @@ def _add_rules( #################### # use the start and end of this rule as a break point for query runs #################### - if USE_RULE_STARTS and rule.length > min_len_starts: + if USE_RULE_STARTS and rule_length > min_len_starts: starts_automaton_add_start( tids=rule_token_ids[:len_starts], rule_identifier=rule.identifier, - rule_length=rule.length, + rule_length=rule_length, ) #################### @@ -495,6 +515,11 @@ def _add_rules( ######################################################################## # Finalize index data structures ######################################################################## + # Create the tid -> token string lookup structure. + ######################################################################## + self.tokens_by_tid = tokens_by_tid = [ + ts for ts, _tid in sorted(dictionary.items(), key=itemgetter(1))] + self.len_tokens = len_tokens = len(tokens_by_tid) # some tokens are made entirely of digits and these can create some # worst case behavior when there are long runs on these @@ -502,12 +527,6 @@ def _add_rules( self.digit_only_tids = intbitset([ i for i, s in enumerate(self.tokens_by_tid) if s.isdigit()]) - # Create the tid -> token string lookup structure. - ######################################################################## - self.tokens_by_tid = tokens_by_tid = [ - ts for ts, _tid in sorted(dictionary.items(), key=itemgetter(1))] - self.len_tokens = len_tokens = len(tokens_by_tid) - # Finalize automatons ######################################################################## self.rules_automaton.make_automaton() @@ -515,6 +534,7 @@ def _add_rules( self.fragments_automaton.make_automaton() if USE_RULE_STARTS: match_aho.finalize_starts(self.starts_automaton) + self.unknown_automaton.make_automaton() ######################################################################## # Do some sanity checks @@ -621,7 +641,8 @@ def get_spdx_id_matches( def get_exact_matches(self, query, deadline=sys.maxsize, **kwargs): """ - Extract matching strategy using an automaton for multimatching at once. + Exact matching strategy using an automaton for multimatching many rules + at once. """ wqr = query.whole_query_run() @@ -841,6 +862,7 @@ def match( as_expression=False, expression_symbols=None, approximate=True, + unknown_licenses=False, deadline=sys.maxsize, _skip_hash_match=False, **kwargs, @@ -848,23 +870,26 @@ def match( """ This is the main entry point to match licenses. - Return a sequence of LicenseMatch by matching the file at `location` or - the `query_string` string against this index. Only include matches with - scores greater or equal to `min_score`. + Return a sequence of LicenseMatch by matching the file at ``location`` or + the ``query_string`` string against this index. Only include matches with + scores greater or equal to ``min_score``. - If `as_expression` is True, treat the whole text as a single SPDX + If ``as_expression`` is True, treat the whole text as a single SPDX license expression and use only expression matching. Use the ``expression_symbols`` mapping of {lowered key: LicenseSymbol} if provided. Otherwise use the standard SPDX license symbols mapping. - If `approximate` is True, perform approximate matching as a last + If ``approximate`` is True, perform approximate matching as a last matching step. Otherwise, only do hash, exact and expression matching. - `deadline` is a time.time() value in seconds by which the processing + If ``unknown_licenses`` is True, perform unknown licenses matching after + all regular matching steps. + + ``deadline`` is a time.time() value in seconds by which the processing should stop and return whatever was matched so far. - `_skip_hash_match` is used only for testing. + ``_skip_hash_match`` is used only for testing. """ assert 0 <= min_score <= 100 @@ -891,6 +916,7 @@ def match( as_expression=as_expression, expression_symbols=expression_symbols, approximate=approximate, + unknown_licenses=unknown_licenses, deadline=deadline, _skip_hash_match=_skip_hash_match, **kwargs, @@ -903,12 +929,13 @@ def match_query( as_expression=False, expression_symbols=None, approximate=True, + unknown_licenses=False, deadline=sys.maxsize, _skip_hash_match=False, **kwargs, ): """ - Return a sequence of LicenseMatch by matching the `qry` Query against + Return a sequence of LicenseMatch by matching the ``qry`` Query against this index. See Index.match() for arguments documentation. """ @@ -996,6 +1023,53 @@ def match_query( if time() > deadline: break + # refining matches without filtering false positives + matches, _discarded = match.refine_matches( + matches=matches, + query=qry, + min_score=min_score, + filter_false_positive=False, + merge=True, + ) + + if unknown_licenses: + good_matches, weak_matches = match.split_weak_matches(matches) + # collect the positions that are "good matches" to exclude from + # matching for unknown_licenses. Create a Span to check for unknown + # based on this. + original_qspan = Span(0, len(qry.tokens) - 1) + good_qspans = (m.qspan for m in good_matches) + good_qspan = Span().union(*good_qspans) + + unmatched_qspan = original_qspan.difference(good_qspan) + + # for each subspan, run unknown license detection + unknown_matches = [] + for unspan in unmatched_qspan.subspans(): + unquery_run = query.QueryRun( + query=qry, + start=unspan.start, + end=unspan.end, + ) + + unknown_match = match_unknown.match_unknowns( + idx=self, + query_run=unquery_run, + automaton=self.unknown_automaton, + ) + + if unknown_match: + unknown_matches.append(unknown_match) + + unknown_matches = match.filter_invalid_contained_unknown_matches( + unknown_matches=unknown_matches, + good_matches=good_matches, + ) + + matches.extend(unknown_matches) + # reinject weak matches and let refine matches keep the bests + matches.extend(weak_matches) + if not matches: return [] diff --git a/src/licensedcode/match.py b/src/licensedcode/match.py index bd5601cea69..6de4fbff873 100644 --- a/src/licensedcode/match.py +++ b/src/licensedcode/match.py @@ -14,6 +14,7 @@ from attr import validators from licensedcode import MAX_DIST +from licensedcode import SMALL_RULE from licensedcode import query from licensedcode.spans import Span from licensedcode.stopwords import STOPWORDS @@ -54,6 +55,7 @@ TRACE_REGIONS = False TRACE_FILTER_LICENSE_LIST = False TRACE_FILTER_LICENSE_LIST_DETAILED = False +TRACE_FILTER_INVALID_UNKNOWN = False TRACE_MATCHED_TEXT = False TRACE_MATCHED_TEXT_DETAILS = False @@ -62,6 +64,7 @@ TRACE_REPR_MATCHED_RULE = False TRACE_REPR_SPAN_DETAILS = False TRACE_REPR_THRESHOLDS = False +TRACE_REPR_ALL_MATCHED_TEXTS = False def logger_debug(*args): pass @@ -86,6 +89,7 @@ def logger_debug(*args): pass or TRACE_REGIONS or TRACE_FILTER_LICENSE_LIST or TRACE_FILTER_LICENSE_LIST_DETAILED + or TRACE_FILTER_INVALID_UNKNOWN ): use_print = True @@ -232,6 +236,7 @@ def __repr__( trace_spans=TRACE_REPR_SPAN_DETAILS, trace_thresholds=TRACE_REPR_THRESHOLDS, trace_rule=TRACE_REPR_MATCHED_RULE, + trace_text=TRACE_REPR_ALL_MATCHED_TEXTS, ): spans = '' if trace_spans: @@ -255,6 +260,11 @@ def __repr__( ireg = (self.istart, self.iend) spans = spans thresh = thresh + + if trace_text: + text = f' matched_text: {self.matched_text()!r}\n' + else: + text = '' return ( f'LicenseMatch: ' f'{self.rule.license_expression!r}, ' @@ -269,6 +279,7 @@ def __repr__( f'qreg={qreg!r}, ' f'ireg={ireg!r}' f'{thresh}{spans}' + f'{text}' ) def __eq__(self, other): @@ -703,8 +714,8 @@ def matched_text( self, whole_lines=False, highlight=True, - highlight_matched=u'%s', - highlight_not_matched=u'[%s]', + highlight_matched='{}', + highlight_not_matched='[{}]', _usecache=True ): """ @@ -727,7 +738,7 @@ def matched_text( if whole_lines and query.has_long_lines: whole_lines = False - return u''.join(get_full_matched_text( + return ''.join(get_full_matched_text( match=self, location=query.location, query_string=query.query_string, @@ -1534,7 +1545,7 @@ def filter_matches_to_spurious_single_token( shorts_and_digits = query.shorts_and_digits_pos for match in matches: - if not match.len() == 1: + if match.len() != 1: kept_append(match) continue @@ -1606,12 +1617,7 @@ def filter_too_short_matches( discarded_append = discarded.append for match in matches: - # always keep exact matches - if match.matcher != MATCH_SEQ: - kept_append(match) - continue - - if match.is_small(): + if match.matcher == MATCH_SEQ and match.is_small(): if trace: logger_debug(' ==> DISCARDING SHORT:', match) @@ -1627,6 +1633,34 @@ def filter_too_short_matches( return kept, discarded +def split_weak_matches(matches): + """ + Return a filtered list of kept LicenseMatch matches and a list of weak + matches given a `matches` list of LicenseMatch by considering shorter + sequence matches with a low coverage or match to unknown licenses. These are + set aside before "unknown license" matching. + """ + from licensedcode.match_seq import MATCH_SEQ + + kept = [] + kept_append = kept.append + discarded = [] + discarded_append = discarded.append + + for match in matches: + # always keep exact matches + if (match.matcher == MATCH_SEQ + and match.len() <= SMALL_RULE + and match.coverage() <= 25 + ) or match.rule.has_unknown: + + discarded_append(match) + else: + kept_append(match) + + return kept, discarded + + def filter_spurious_matches( matches, trace=TRACE_FILTER_SPURIOUS, @@ -1641,6 +1675,7 @@ def filter_spurious_matches( tokens are separated by many unmatched tokens.) """ from licensedcode.match_seq import MATCH_SEQ + from licensedcode.match_unknown import MATCH_UNKNOWN kept = [] kept_append = kept.append @@ -1649,7 +1684,7 @@ def filter_spurious_matches( for match in matches: # always keep exact matches - if match.matcher != MATCH_SEQ: + if match.matcher not in (MATCH_SEQ, MATCH_UNKNOWN): kept_append(match) continue @@ -1682,7 +1717,7 @@ def filter_spurious_matches( discarded_append(match) - elif (qdens < 0.5 or idens < 0.5): + elif (qdens < 0.4 or idens < 0.4): if trace: logger_debug(' ==> DISCARDING Spurious5:', match) @@ -1757,6 +1792,33 @@ def filter_invalid_matches_to_single_word_gibberish( return kept, discarded +def filter_invalid_contained_unknown_matches( + unknown_matches, + good_matches, + trace=TRACE_FILTER_INVALID_UNKNOWN, +): + """ + Return a filtered list of good_unknowns LicenseMatch unknown matches given + an ``unknown_matches`` list of LicenseMatch resulting from unknown license + detection by considering their containment in any "qregion" of the + ``good_matches`` list of LicenseMatch. + """ + good_unknowns = [] + good_unknowns_append = good_unknowns.append + + good_matches_qregions = [m.qregion() for m in good_matches] + + for match in unknown_matches: + qspan = match.qspan + if any(qspan in good_qregion for good_qregion in good_matches_qregions): + if trace: + logger_debug(' ==> DISCARDING INVALID UNKNOWN:', match) + else: + good_unknowns_append(match) + + return good_unknowns + + def filter_short_matches_scattered_on_too_many_lines( matches, trace=TRACE_FILTER_SHORT, @@ -2489,14 +2551,14 @@ def refine_matches( def _log(_matches, _discarded, msg): if trace_basic: - logger_debug(' #####refine_matches: ', msg, '#', len(matches)) + logger_debug(' #####refine_matches: KEPT', msg, '#', len(matches)) if trace: for m in matches: logger_debug(m) if trace_basic: - logger_debug(' #####refine_matches: NOT', msg, '#', len(_discarded)) + logger_debug(' #####refine_matches: DISCARDED NOT', msg, '#', len(_discarded)) if trace: for m in matches: @@ -2511,6 +2573,10 @@ def _log(_matches, _discarded, msg): all_discarded_extend(discarded) _log(matches, discarded, 'HAS KEY PHRASES') + matches, discarded = filter_spurious_matches(matches) + all_discarded_extend(discarded) + _log(matches, discarded, 'GOOD') + matches, discarded = filter_below_rule_minimum_coverage(matches) all_discarded_extend(discarded) _log(matches, discarded, 'ABOVE MIN COVERAGE') @@ -2531,10 +2597,6 @@ def _log(_matches, _discarded, msg): all_discarded_extend(discarded) _log(matches, discarded, 'MORE THAN ONE NON INVALID GIBBERISH TOKEN') - matches, discarded = filter_spurious_matches(matches) - all_discarded_extend(discarded) - _log(matches, discarded, 'GOOD') - # TODO: we seem to be always merging? matches = merge_matches(matches) @@ -2754,20 +2816,20 @@ def reportable_tokens( trace=TRACE_MATCHED_TEXT_DETAILS, ): """ - Yield Tokens from a `tokens` iterable of Token objects (built from a query- - side scanned file or string) that are inside a `match_qspan` matched Span - starting at `start_line` and ending at `end_line`. If whole_lines is True, + Yield Tokens from a ``tokens`` iterable of Token objects (built from a query- + side scanned file or string) that are inside a ``match_qspan`` matched Span + starting at `start_line` and ending at ``end_line``. If whole_lines is True, also yield unmatched Tokens that are before and after the match and on the first and last line of a match (unless the lines are very long text lines or the match is from binary content.) - As a side effect, known matched tokens are tagged as is_matched=True if they - are matched. + As a side effect, known matched tokens are tagged as "is_matched=True" if + they are matched. - If `whole_lines` is True, any token within matched lines range is included. - Otherwise, a token is included if its position is within the matched - match_qspan or it is a punctuation token immediately after the matched - match_qspan even though not matched. + If ``whole_lines`` is True, any token within matched lines range is + included. Otherwise, a token is included if its position is within the + matched ``match_qspan`` or it is a punctuation token immediately after the + matched ``match_qspan`` even though not matched. """ start = match_qspan.start end = match_qspan.end @@ -2871,38 +2933,103 @@ def get_full_matched_text( idx=None, whole_lines=False, highlight=True, - highlight_matched=u'%s', - highlight_not_matched=u'[%s]', + highlight_matched='{}', + highlight_not_matched='[{}]', + only_matched=False, + stopwords=STOPWORDS, + _usecache=True, + trace=TRACE_MATCHED_TEXT, +): + """ + Yield strings corresponding to the full matched query text given a ``match`` + LicenseMatch detected with an `idx` LicenseIndex in a query file at + ``location`` or a ``query_string``. + + See get_full_qspan_matched_text() for other arguments documentation + """ + if trace: + logger_debug('get_full_matched_text: match:', match) + + return get_full_qspan_matched_text( + match_qspan=match.qspan, + match_query_start_line=match.query.start_line, + match_start_line=match.start_line, + match_end_line=match.end_line, + location=location, + query_string=query_string, + idx=idx, + whole_lines=whole_lines, + highlight=highlight, + highlight_matched=highlight_matched, + highlight_not_matched=highlight_not_matched, + only_matched=only_matched, + stopwords=stopwords, + _usecache=_usecache, + trace=trace, + ) + + +def get_full_qspan_matched_text( + match_qspan, + match_query_start_line, + match_start_line, + match_end_line, + location=None, + query_string=None, + idx=None, + whole_lines=False, + highlight=True, + highlight_matched='{}', + highlight_not_matched='[{}]', + only_matched=False, stopwords=STOPWORDS, _usecache=True, trace=TRACE_MATCHED_TEXT, ): """ - Yield unicode strings corresponding to the full matched query text given a - ``match`` LicenseMatch detected in an `idx` LicenseIndex given a query file - at ``location`` or a ``query_string``. + Yield strings corresponding to words of the matched query text given a + ``match_qspan`` LicenseMatch qspan Span detected with an `idx` LicenseIndex + in a query file at ``location`` or a ``query_string``. + + - ``match_query_start_line`` is the match query.start_line + - ``match_start_line`` is the match start_line + - ``match_end_line`` is the match= end_line - This contains the full text including punctuations and spaces that are not - participating in the match proper including leading and trailing punctuations. + The returned strings contains the full text including punctuations and + spaces that are not participating in the match proper including punctuations. - If `whole_lines` is True, the unmatched part at the start of the first + If ``whole_lines`` is True, the unmatched part at the start of the first matched line and the unmatched part at the end of the last matched lines are also included in the returned text (unless the line is very long). - If `highlight` is True, each token is formatted for "highlighting" and - emphasis with the `highlight_matched` format string for matched tokens or to - the `highlight_not_matched` for tokens not matched. The default is to + If ``highlight`` is True, each token is formatted for "highlighting" and + emphasis with the ``highlight_matched`` format string for matched tokens or to + the ``highlight_not_matched`` for tokens not matched. The default is to enclose an unmatched token sequence in [] square brackets. Punctuation is not highlighted. - """ + if ``only_matched`` is True, only matched tokens are returned and + ``whole_lines`` and ``highlight`` are ignored. Unmatched words are replaced + by a "dot". + + If ``_usecache`` is True, the tokenized text is cached for efficiency. + """ if trace: - logger_debug('get_full_matched_text: match:', match) - logger_debug('get_full_matched_text: location:', location) - logger_debug('get_full_matched_text: query_string :', query_string) + logger_debug('get_full_qspan_matched_text: match_qspan:', match_qspan) + logger_debug('get_full_qspan_matched_text: location:', location) + logger_debug('get_full_qspan_matched_text: query_string :', query_string) assert location or query_string assert idx + + if only_matched: + # use highlighting to skip the reporting of unmatched entirely + whole_lines = False + highlight = True + highlight_matched = '{}' + highlight_not_matched = '.' + highlight = True + # Create and process a stream of Tokens if not _usecache: # for testing only, reset cache on each call @@ -2910,7 +3037,7 @@ def get_full_matched_text( location=location, query_string=query_string, dictionary=idx.dictionary, - start_line=match.query.start_line, + start_line=match_query_start_line, _cache={}, ) else: @@ -2918,28 +3045,28 @@ def get_full_matched_text( location=location, query_string=query_string, dictionary=idx.dictionary, - start_line=match.query.start_line, + start_line=match_query_start_line, ) if trace: tokens = list(tokens) print() - logger_debug('get_full_matched_text: tokens:') + logger_debug('get_full_qspan_matched_text: tokens:') for t in tokens: print(' ', t) print() tokens = reportable_tokens( tokens=tokens, - match_qspan=match.qspan, - start_line=match.start_line, - end_line=match.end_line, + match_qspan=match_qspan, + start_line=match_start_line, + end_line=match_end_line, whole_lines=whole_lines, ) if trace: tokens = list(tokens) - logger_debug('get_full_matched_text: reportable_tokens:') + logger_debug('get_full_qspan_matched_text: reportable_tokens:') for t in tokens: print(t) print() @@ -2952,9 +3079,9 @@ def get_full_matched_text( else: if token.is_text and val.lower() not in stopwords: if token.is_matched: - yield highlight_matched % val + yield highlight_matched.format(val) else: - yield highlight_not_matched % val + yield highlight_not_matched.format(val) else: # we do not highlight punctuation and stopwords. yield val diff --git a/src/licensedcode/match_aho.py b/src/licensedcode/match_aho.py index 7021593d044..ec6e2216ac1 100644 --- a/src/licensedcode/match_aho.py +++ b/src/licensedcode/match_aho.py @@ -19,7 +19,7 @@ Matching strategy for exact matching using Aho-Corasick automatons. """ -# Set to False to enable debug tracing +# Set to True to enable debug tracing TRACE = False TRACE_FRAG = False TRACE_DEEP = False @@ -155,9 +155,9 @@ def get_matched_positions(tokens, qbegin, automaton): def get_matches(tokens, qbegin, automaton): """ - Yield tuples of automaton matches positions as (match end, match value) from - matching `tokens` sequence of token ids starting at the `qbegin` absolute - query start position position using the `automaton`. + Yield tuples of automaton matches as (match end, match value) from matching + the ``tokens`` sequence of token ids starting at the `qbegin` absolute query + start position position using the `automaton`. """ # iterate over matched strings: the matched value is (rule id, index start # pos, index end pos) diff --git a/src/licensedcode/match_unknown.py b/src/licensedcode/match_unknown.py new file mode 100644 index 00000000000..8719d49d669 --- /dev/null +++ b/src/licensedcode/match_unknown.py @@ -0,0 +1,249 @@ +# +# Copyright (c) nexB Inc. and others. All rights reserved. +# ScanCode is a trademark of nexB Inc. +# SPDX-License-Identifier: Apache-2.0 +# See http://www.apache.org/licenses/LICENSE-2.0 for the license text. +# See https://github.com/nexB/scancode-toolkit for support or download. +# See https://aboutcode.org for more information about nexB OSS projects. +# + +import ahocorasick + +from licensedcode import tokenize +from licensedcode.models import UnknownRule +from licensedcode.match import get_full_qspan_matched_text +from licensedcode.match import LicenseMatch +from licensedcode.spans import Span + +""" +Matching strategy for unknown license detection using ngrams. +""" + +# Set to True to enable debug tracing +TRACE = False + +if TRACE: + import logging + import sys + + logger = logging.getLogger(__name__) + + def logger_debug(*args): + return logger.debug(' '.join(isinstance(a, str) and a or repr(a) for a in args)) + + logging.basicConfig(stream=sys.stdout) + logger.setLevel(logging.DEBUG) + +else: + + def logger_debug(*args): + pass + +MATCH_UNKNOWN = '6-unknown' + +UNKNOWN_NGRAM_LENGTH = 6 + + +def get_automaton(): + """ + Return a new empty automaton. + """ + return ahocorasick.Automaton(ahocorasick.STORE_INTS, ahocorasick.KEY_SEQUENCE) # NOQA + + +def add_ngrams( + automaton, + tids, + tokens, + rule_length, + len_legalese, + unknown_ngram_length=UNKNOWN_NGRAM_LENGTH, +): + """ + Add the `tids` sequence of token ids to an unknown ngram automaton. + """ + if rule_length >= unknown_ngram_length: + tids_ngrams = tokenize.ngrams(tids, ngram_length=unknown_ngram_length) + toks_ngrams = tokenize.ngrams(tokens, ngram_length=unknown_ngram_length) + for tids_ngram, toks_ngram in zip(tids_ngrams, toks_ngrams): + if is_good_tokens_ngram(toks_ngram, tids_ngram, len_legalese): + # note that we do not store positions as values, only the ngram + # since we do not keep the rule origin of an ngram + automaton.add_word(tids_ngram) + + +markers = set([ + 'copyright', 'c', 'copyrights', + 'rights', + 'reserved', + 'trademark', + 'foundation', 'government', 'institute', 'university', + 'inc', 'corp', 'co', + 'author', + 'com', 'org', 'net', 'uk', 'fr', 'be', 'de', + 'http', 'https', 'www', +]) + +def is_good_tokens_ngram( + tokens_ngram, + tids_ngram, + len_legalese, + markers=markers, +): + """ + Return True if the ``tokens_ngram`` ngram of token strings or ``tids_ngram`` ngram of + token ids is a "good" ngram. + """ + min_good = 3 + + # too many digits + if sum(t.isdigit() for t in tokens_ngram) >= min_good: + return False + + # a year is a sign of copyright + if any(t.isdigit() and len(t) == 4 for t in tokens_ngram): + return False + + # too many single chars + if sum(len(t) == 1 for t in tokens_ngram) >= min_good: + return False + + # too little token diversity, e.g. this is a repeat + if len(set(tids_ngram)) <= 2: + return False + + # we want at least one high token + if not any(tid < len_legalese for tid in tids_ngram): + return False + + # copyright and similar markers + if any(t in markers for t in tokens_ngram): + return False + + return True + + +def match_unknowns( + idx, + query_run, + automaton, + unknown_ngram_length=UNKNOWN_NGRAM_LENGTH, + **kwargs, +): + """ + Return a LicenseMatch (or None) by matching the ``query_run`` against the + ``automaton`` and ``idx`` index. + """ + matched_ngrams = get_matched_ngrams( + tokens=query_run.tokens, + qbegin=query_run.start, + automaton=automaton, + unknown_ngram_length=unknown_ngram_length, + ) + + if TRACE: + tokens_by_tid = idx.tokens_by_tid + + def get_tokens(_toks): + return (' '.join(tokens_by_tid[t] for t in _toks)) + + print('match_unknowns: matched_ngrams') + for qstart, qend, matched_toks in matched_ngrams: + print( + ' ', 'qstart', qstart, + 'qend', qend, + 'matched_toks', get_tokens(matched_toks)) + + # build match from merged matched ngrams + qspans = (Span(qstart, qend) for qstart, qend in matched_ngrams) + qspan = Span().union(*qspans) + + if not qspan: + return + + query = query_run.query + query_tokens = query.tokens + + matched_tokens = [query_tokens[qpos] for qpos in qspan] + match_len = len(qspan) + + if TRACE: + print('match_unknowns: matched_span:', get_tokens(matched_tokens)) + + # we use the query side to build the ispans + ispan = Span(0, match_len) + + # build synthetic rule text for "only_matched" text + line_by_pos = query.line_by_pos + + try: + match_start_line = line_by_pos[qspan.start] + match_end_line = line_by_pos[qspan.end] + except: + print('empty span:', qspan) + raise + + text = ''.join(get_full_qspan_matched_text( + match_qspan=qspan, + match_query_start_line=query.start_line, + match_start_line=match_start_line, + match_end_line=match_end_line, + location=query.location, + query_string=query.query_string, + idx=idx, + only_matched=True, + )) + + if TRACE: + print('match_unknowns: text', text) + + # ... and use this in a synthetic UnknownRule + rule = UnknownRule(stored_text=text, length=match_len) + + # finally craft a LicenseMatch and return + len_legalese = idx.len_legalese + hispan = Span( + ipos for ipos, tok in zip(ispan, matched_tokens) + if tok < len_legalese + ) + + if len(qspan) < unknown_ngram_length * 4 or len(hispan) < 5: + if TRACE: + print('match_unknowns: Skipping weak unkown match', text) + return + + match = LicenseMatch( + rule=rule, + qspan=qspan, + ispan=ispan, + hispan=hispan, + query_run_start=query_run.start, + matcher=MATCH_UNKNOWN, + query=query, + ) + + if TRACE: + print('match_unknowns: match:', match) + + return match + + +def get_matched_ngrams( + tokens, + qbegin, + automaton, + unknown_ngram_length=UNKNOWN_NGRAM_LENGTH, +): + """ + Yield tuples of automaton matching positions as (qstart, qend) + from matching the ``tokens`` sequence of query token ids starting at the + `qbegin` absolute query start position position using the `automaton`. + """ + # iterate over matched strings: the matched value is the matching ngram + # which is an n-tuple of token ids + qtokens = tuple(tokens) + offset = unknown_ngram_length - 1 + for qend, _ in automaton.iter(qtokens): + qend = qbegin + qend + qstart = qend - offset + yield qstart, qend diff --git a/src/licensedcode/models.py b/src/licensedcode/models.py index 2da2a1d6d5c..2fd522f2cd2 100644 --- a/src/licensedcode/models.py +++ b/src/licensedcode/models.py @@ -39,6 +39,7 @@ from licensedcode.tokenize import KEY_PHRASE_OPEN from licensedcode.tokenize import KEY_PHRASE_CLOSE from textcode.analysis import numbered_text_lines +import hashlib """ Reference License and license Rule structures persisted as a combo of a YAML @@ -178,7 +179,14 @@ class License: default=False, repr=False, metadata=dict( - help='Flag set to True, if this license is for some unknown license') + help='Flag set to True if this license is for some unknown licensing') + ) + + is_generic = attr.ib( + default=False, + repr=False, + metadata=dict( + help='Flag set to True if this license if for a generic, unnamed license') ) spdx_license_key = attr.ib( @@ -524,7 +532,7 @@ def validate(licenses, verbose=False, no_dupe_urls=False): error('No name') if not lic.category: - error('No category') + error('No category: Use "Unstated License" if not known.') if lic.category and lic.category not in CATEGORIES: cats = '\n'.join(sorted(CATEGORIES)) error( @@ -537,8 +545,11 @@ def validate(licenses, verbose=False, no_dupe_urls=False): if lic.is_unknown: if not 'unknown' in lic.key: - error( - 'is_unknown is true only for unknown licenses') + error('is_unknown can be true only for licenses with ' + '"unknown " in their key string.') + + if lic.is_generic and lic.is_unknown: + error('is_generic and is_unknown are incompatible') # URLS dedupe and consistency if no_dupe_urls: @@ -1215,7 +1226,8 @@ class BasicRule: metadata=dict( help='Internal field with the text of this rule for special cases ' 'where the rule is not backed by a file, such as with SPDX license ' - 'identifier expressions dynamically generated rules or testing convenience') + 'identifier expressions dynamically generated rules or for testing ' + 'convenience') ) key_phrase_spans = attr.ib( @@ -1336,13 +1348,13 @@ def setup(self): if self.license_expression: try: expression = self.licensing.parse(self.license_expression) - except: + except Exception as e: exp = self.license_expression trace = traceback.format_exc() raise InvalidRule( - f'Unable to parse rule License expression: {exp!r} ' + f'Unable to parse Rule license expression: {exp!r} ' f'for: file://{self.data_file}\n{trace}' - ) + ) from e if expression is None: raise InvalidRule( @@ -1825,9 +1837,8 @@ def set_relevance(self): - false positive or SPDX rules have 100 relevance. - relevance is computed based on the rule length """ - # false positive rules with no license and their matches are never returned - if isinstance(self, SpdxRule) or self.is_false_positive: - # use the default max relevance of 100 + + if self.is_false_positive: self.relevance = 100 self.has_stored_relevance = True return @@ -2023,24 +2034,11 @@ class SpdxRule(Rule): def __attrs_post_init__(self, *args, **kwargs): self.identifier = f'spdx-license-identifier: {self.license_expression}' - expression = None - try: - expression = self.licensing.parse(self.license_expression) - except: - raise InvalidRule( - 'Unable to parse License rule expression: ' - f'{self.license_expression!r} for: SPDX rule: ' - f'{self.stored_text}\n' + traceback.format_exc() - ) + self.setup() - if expression is None: - raise InvalidRule( - 'Unable to parse License rule expression: ' - f'{self.license_expression!r} for: {self.data_file!r}' - ) + if not self.license_expression: + raise InvalidRule(f'Empty license expression: {self.identifier}') - self.license_expression = expression.render() - self.license_expression_object = expression self.is_license_tag = True self.is_small = False self.relevance = 100 @@ -2053,6 +2051,49 @@ def dump(self): raise NotImplementedError +UNKNOWN_LICENSE_KEY = 'unknown' + + +@attr.s(slots=True, repr=False) +class UnknownRule(Rule): + """ + A specialized rule object that is used for the special case of unknown + license detection. + + Since we may have an infinite number of possible unknown licenses and these + are not backed by a traditional rule text file, we use this class to handle + the specifics of these how such rules are built at matching time: one new + synthetic rule is created for each detected unknown license match. + """ + + def __attrs_post_init__(self, *args, **kwargs): + # We craft a UNIQUE identifier for the matched content + self.identifier = f'unknown-license-detection:{self.compute_unique_id()}' + + self.license_expression = UNKNOWN_LICENSE_KEY + # note that this could be shared across rules as an optimization + self.license_expression_object = self.licensing.parse(UNKNOWN_LICENSE_KEY) + self.is_license_notice = True + self.notes = 'Unknown license based on a composite of license words.' + self.setup() + + # called only for it's side effects + self.tokens() + + def load(self): + raise NotImplementedError + + def dump(self): + raise NotImplementedError + + def compute_unique_id(self): + """ + Return a a unique id string based on this rule content. (Today this is + a MD5 of the text, but that's an implementation detail) + """ + return hashlib.md5(self.stored_text.encode('utf-8')).hexdigest() + + def _print_rule_stats(): """ Print rules statistics. @@ -2255,6 +2296,7 @@ def get_key_phrase_spans(text): >>> check_exception('{{}}') >>> check_exception('{{This is') >>> check_exception('{{This is{{') + >>> check_exception('{{This is{{ }}') >>> check_exception('{{{{This}}}}') >>> check_exception('}}This {{is}}') >>> check_exception('This }} {{is}}') @@ -2270,6 +2312,8 @@ def get_key_phrase_spans(text): key_phrase = [] for token in key_phrase_tokenizer(text): if token == KEY_PHRASE_OPEN: + if in_key_phrase: + raise InvalidRule('Invalid rule with nested key phrase {{ {{ braces', text) in_key_phrase = True elif token == KEY_PHRASE_CLOSE: diff --git a/src/licensedcode/plugin_license.py b/src/licensedcode/plugin_license.py index 9b1f90d6fdc..8722475b7fe 100644 --- a/src/licensedcode/plugin_license.py +++ b/src/licensedcode/plugin_license.py @@ -145,6 +145,7 @@ def get_scanner( license_text=False, license_text_diagnostics=False, license_url_template=SCANCODE_LICENSEDB_URL, + unknown_licenses=False, **kwargs ): @@ -153,7 +154,8 @@ def get_scanner( min_score=license_score, include_text=license_text, license_text_diagnostics=license_text_diagnostics, - license_url_template=license_url_template + license_url_template=license_url_template, + unknown_licenses=unknown_licenses, ) def process_codebase(self, codebase, unknown_licenses, **kwargs): diff --git a/src/licensedcode/tracing.py b/src/licensedcode/tracing.py index c13dd805f2b..aeacbc76160 100644 --- a/src/licensedcode/tracing.py +++ b/src/licensedcode/tracing.py @@ -10,9 +10,8 @@ from functools import partial import textwrap - """ -Utility function to trace matched texts. +Utility function to trace matched texts used for tracing and testing. """ @@ -28,8 +27,10 @@ def get_texts(match, width=80, margin=0): """ qtokens = match.matched_text(whole_lines=False).split() mqt = format_text(tokens=qtokens, width=width, margin=margin) - - itokens = matched_rule_tokens_str(match) + if match.matcher == '6-unknown': + itokens = match.rule.text().split() + else: + itokens = matched_rule_tokens_str(match) mit = format_text(tokens=itokens, width=width, margin=margin) return mqt, mit @@ -54,12 +55,13 @@ def format_text(tokens, width=80, margin=4): def matched_rule_tokens_str(match): """ Return an iterable of matched rule token strings given a match. - Punctuation is removed, spaces are normalized (new line is replaced by a space), - case is preserved. + + Punctuation is removed, spaces are normalized (new line is replaced by a + space), case is not preserved. """ for pos, token in enumerate(match.rule.tokens()): if match.ispan.start <= pos <= match.ispan.end: if pos in match.ispan: yield token else: - yield '<%s>' % token + yield '<{}>'.format(token) diff --git a/src/scancode/api.py b/src/scancode/api.py index 6b8e9a64df7..259a1c7a635 100644 --- a/src/scancode/api.py +++ b/src/scancode/api.py @@ -157,6 +157,7 @@ def get_licenses( include_text=False, license_text_diagnostics=False, license_url_template=SCANCODE_LICENSEDB_URL, + unknown_licenses=False, deadline=sys.maxsize, **kwargs, ): @@ -178,6 +179,8 @@ def get_licenses( indicate the overall proportion of detected license text and license notice words in the file. This is used to determine if a file contains mostly licensing information. + + If ``unknown_licenses`` is True, also detect unknown licenses. """ from licensedcode import cache from licensedcode.spans import Span @@ -188,7 +191,11 @@ def get_licenses( detected_expressions = [] matches = idx.match( - location=location, min_score=min_score, deadline=deadline, **kwargs + location=location, + min_score=min_score, + deadline=deadline, + unknown_licenses=unknown_licenses, + **kwargs, ) qspans = [] diff --git a/tests/licensedcode/data/datadriven/external/atarashi/CPAL-1.0.php.yml b/tests/licensedcode/data/datadriven/external/atarashi/CPAL-1.0.php.yml index 22df5f86f80..e7bfd327afb 100644 --- a/tests/licensedcode/data/datadriven/external/atarashi/CPAL-1.0.php.yml +++ b/tests/licensedcode/data/datadriven/external/atarashi/CPAL-1.0.php.yml @@ -1,2 +1,4 @@ license_expressions: - cpal-1.0 + - cpal-1.0 + diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/realnetworks-eula.txt.yml b/tests/licensedcode/data/datadriven/external/fossology-licenses/realnetworks-eula.txt.yml index 0f0bc6f590e..f8cd391ec2a 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-licenses/realnetworks-eula.txt.yml +++ b/tests/licensedcode/data/datadriven/external/fossology-licenses/realnetworks-eula.txt.yml @@ -1,5 +1,5 @@ license_expressions: - commercial-license - - proprietary-license + - generic-trademark notes: this is a license from fossology license reference RealNetworks-EULA (RealNetworks Real Licensing Program License Supplement) http://www.realnetworks.com/uploadedFiles/Support/helix-support/eula-Real-LicProg-Perp-Supp.pdf diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/wintertree.txt.yml b/tests/licensedcode/data/datadriven/external/fossology-licenses/wintertree.txt.yml index d725e7f1bb9..7774f01c2cc 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-licenses/wintertree.txt.yml +++ b/tests/licensedcode/data/datadriven/external/fossology-licenses/wintertree.txt.yml @@ -4,6 +4,7 @@ license_expressions: - unknown-license-reference - unknown-license-reference - unknown-license-reference - - warranty-disclaimer + - proprietary-license AND warranty-disclaimer + - proprietary-license AND warranty-disclaimer notes: this is a license from fossology license reference Wintertree (Wintertree License Agreement) http://www.wintertree-software.com/dev/thesdb/license.html diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/zonealarm-eula.txt.yml b/tests/licensedcode/data/datadriven/external/fossology-licenses/zonealarm-eula.txt.yml index 9d76bd85170..652cbb023f5 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-licenses/zonealarm-eula.txt.yml +++ b/tests/licensedcode/data/datadriven/external/fossology-licenses/zonealarm-eula.txt.yml @@ -1,5 +1,5 @@ license_expressions: - proprietary-license - - proprietary-license + - generic-trademark - proprietary-license notes: this is a license from fossology license reference ZoneAlarm-EULA (ZoneAlarm EULA) http://www.zonealarm.com/security/en-us/end-user-license-agreement-zonealarm.htm diff --git a/tests/licensedcode/data/datadriven/external/fossology-tests/BSD/BSD-2-Clause_AND_Imlib2.txt.yml b/tests/licensedcode/data/datadriven/external/fossology-tests/BSD/BSD-2-Clause_AND_Imlib2.txt.yml index d648bc0d5bd..56ce7141255 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-tests/BSD/BSD-2-Clause_AND_Imlib2.txt.yml +++ b/tests/licensedcode/data/datadriven/external/fossology-tests/BSD/BSD-2-Clause_AND_Imlib2.txt.yml @@ -1,6 +1,4 @@ license_expressions: - - imlib2 - - bsd-simplified - - imlib2 - - bsd-simplified - - imlib2 + - bsd-simplified AND imlib2 + - bsd-simplified AND imlib2 + diff --git a/tests/licensedcode/data/datadriven/external/fossology-tests/CPAL/abstract.php.yml b/tests/licensedcode/data/datadriven/external/fossology-tests/CPAL/abstract.php.yml index 22df5f86f80..18cbb242f8b 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-tests/CPAL/abstract.php.yml +++ b/tests/licensedcode/data/datadriven/external/fossology-tests/CPAL/abstract.php.yml @@ -1,2 +1,3 @@ license_expressions: - cpal-1.0 + - cpal-1.0 diff --git a/tests/licensedcode/data/datadriven/external/fossology-tests/Dual-license/Oracle+Sun_oracle_index.html.yml b/tests/licensedcode/data/datadriven/external/fossology-tests/Dual-license/Oracle+Sun_oracle_index.html.yml index d1ae53269d2..0bc9e97f18f 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-tests/Dual-license/Oracle+Sun_oracle_index.html.yml +++ b/tests/licensedcode/data/datadriven/external/fossology-tests/Dual-license/Oracle+Sun_oracle_index.html.yml @@ -1,2 +1,5 @@ license_expressions: - sleepycat + - generic-trademark + - generic-trademark + diff --git a/tests/licensedcode/data/datadriven/external/fossology-tests/Princeton/adj.dat.yml b/tests/licensedcode/data/datadriven/external/fossology-tests/Princeton/adj.dat.yml index 4aaeb7be802..4e0f6097c0e 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-tests/Princeton/adj.dat.yml +++ b/tests/licensedcode/data/datadriven/external/fossology-tests/Princeton/adj.dat.yml @@ -1,3 +1,4 @@ license_expressions: - wordnet - proprietary-license + - unknown-license-reference diff --git a/tests/licensedcode/data/datadriven/external/glc/OpenSSL.t4.yml b/tests/licensedcode/data/datadriven/external/glc/OpenSSL.t4.yml index bef7f7f842d..cb2b4acd5ff 100644 --- a/tests/licensedcode/data/datadriven/external/glc/OpenSSL.t4.yml +++ b/tests/licensedcode/data/datadriven/external/glc/OpenSSL.t4.yml @@ -1,5 +1,4 @@ license_expressions: - - openssl-ssleay - openssl notes: | License test derived from a file of the BSD-licensed repository at: diff --git a/tests/licensedcode/data/datadriven/external/glc/SugarCRM-1.1.3.t1.yml b/tests/licensedcode/data/datadriven/external/glc/SugarCRM-1.1.3.t1.yml index 514625ce75a..bc136ec73ad 100644 --- a/tests/licensedcode/data/datadriven/external/glc/SugarCRM-1.1.3.t1.yml +++ b/tests/licensedcode/data/datadriven/external/glc/SugarCRM-1.1.3.t1.yml @@ -1,9 +1,4 @@ license_expressions: - - zimbra-1.3 - - mpl-1.1 - - proprietary-license - - mpl-1.1 - - mpl-1.1 - sugarcrm-1.1.3 notes: | License test derived from a file of the BSD-licensed repository at: diff --git a/tests/licensedcode/data/datadriven/external/licensecheck/fedora/MIT.yml b/tests/licensedcode/data/datadriven/external/licensecheck/fedora/MIT.yml index 7e50a3621e8..34b51b2bca7 100644 --- a/tests/licensedcode/data/datadriven/external/licensecheck/fedora/MIT.yml +++ b/tests/licensedcode/data/datadriven/external/licensecheck/fedora/MIT.yml @@ -29,7 +29,7 @@ license_expressions: - adobe-glyph - mit-xfig - x11-tiff - - x11 + - other-permissive - x11 AND other-permissive - other-permissive - other-permissive diff --git a/tests/licensedcode/data/datadriven/external/spdx/complex-readme.txt.yml b/tests/licensedcode/data/datadriven/external/spdx/complex-readme.txt.yml index 09cb1a31e3c..b43a5365789 100644 --- a/tests/licensedcode/data/datadriven/external/spdx/complex-readme.txt.yml +++ b/tests/licensedcode/data/datadriven/external/spdx/complex-readme.txt.yml @@ -1,7 +1,7 @@ license_expressions: - ((epl-2.0 OR apache-2.0) OR (gpl-2.0 WITH classpath-exception-2.0 AND gpl-2.0 WITH openjdk-exception)) AND unicode AND public-domain AND mit AND zlib AND zlib - - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR unknown-spdx WITH unknown-spdx + - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception - epl-2.0 OR apache-2.0 - unicode - unicode diff --git a/tests/licensedcode/data/datadriven/external/spdx/complex-short.html.yml b/tests/licensedcode/data/datadriven/external/spdx/complex-short.html.yml index 1f8ce3536d3..cab3238a980 100644 --- a/tests/licensedcode/data/datadriven/external/spdx/complex-short.html.yml +++ b/tests/licensedcode/data/datadriven/external/spdx/complex-short.html.yml @@ -1,8 +1,7 @@ license_expressions: - - epl-2.0 OR apache-2.0 OR (gpl-2.0 WITH classpath-exception-2.0 AND gpl-2.0 WITH openjdk-exception) - - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR unknown-spdx WITH unknown-spdx - - epl-2.0 OR apache-2.0 OR (gpl-2.0 WITH classpath-exception-2.0 AND gpl-2.0 WITH openjdk-exception) - - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR unknown-spdx WITH unknown-spdx + - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception + - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception + - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception - gpl-3.0 WITH autoconf-simple-exception-2.0 - epl-2.0 OR apache-2.0 - bsd-new diff --git a/tests/licensedcode/data/datadriven/external/spdx/complex1.c.yml b/tests/licensedcode/data/datadriven/external/spdx/complex1.c.yml index 2bb8634bcb6..ae4585c03e7 100644 --- a/tests/licensedcode/data/datadriven/external/spdx/complex1.c.yml +++ b/tests/licensedcode/data/datadriven/external/spdx/complex1.c.yml @@ -1,3 +1,3 @@ license_expressions: - - epl-2.0 OR apache-2.0 OR (gpl-2.0 WITH classpath-exception-2.0 AND gpl-2.0 WITH openjdk-exception) - - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR unknown-spdx WITH unknown-spdx + - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception + - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception diff --git a/tests/licensedcode/data/datadriven/external/spdx/complex2.html.yml b/tests/licensedcode/data/datadriven/external/spdx/complex2.html.yml index 2bb8634bcb6..10aee0e7ff7 100644 --- a/tests/licensedcode/data/datadriven/external/spdx/complex2.html.yml +++ b/tests/licensedcode/data/datadriven/external/spdx/complex2.html.yml @@ -1,3 +1,2 @@ license_expressions: - - epl-2.0 OR apache-2.0 OR (gpl-2.0 WITH classpath-exception-2.0 AND gpl-2.0 WITH openjdk-exception) - - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR unknown-spdx WITH unknown-spdx + - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception diff --git a/tests/licensedcode/data/datadriven/external/spdx/expression-with-notice-complex.java.yml b/tests/licensedcode/data/datadriven/external/spdx/expression-with-notice-complex.java.yml index 2bb8634bcb6..ae4585c03e7 100644 --- a/tests/licensedcode/data/datadriven/external/spdx/expression-with-notice-complex.java.yml +++ b/tests/licensedcode/data/datadriven/external/spdx/expression-with-notice-complex.java.yml @@ -1,3 +1,3 @@ license_expressions: - - epl-2.0 OR apache-2.0 OR (gpl-2.0 WITH classpath-exception-2.0 AND gpl-2.0 WITH openjdk-exception) - - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR unknown-spdx WITH unknown-spdx + - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception + - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception diff --git a/tests/licensedcode/data/datadriven/lic1/COPYING_complex2.html.yml b/tests/licensedcode/data/datadriven/lic1/COPYING_complex2.html.yml index ff9d305ed9b..5d315927a1c 100644 --- a/tests/licensedcode/data/datadriven/lic1/COPYING_complex2.html.yml +++ b/tests/licensedcode/data/datadriven/lic1/COPYING_complex2.html.yml @@ -2,4 +2,10 @@ license_expressions: - gpl-2.0-plus - gpl-2.0-plus - lgpl-2.1-plus - - gpl-2.0-plus AND lgpl-2.1-plus AND cc-by-sa-4.0 AND bsd-new + - cc-by-sa-4.0 + - bsd-new + +notes: this is based on the HTML page of https://github.com/ClusterLabs/pacemaker/blob/main/COPYING + and is by design somtheing atypical + It should return gpl-2.0-plus AND lgpl-2.1-plus AND cc-by-sa-4.0 AND bsd-new + diff --git a/tests/licensedcode/data/datadriven/lic1/COPYING_complex2.txt b/tests/licensedcode/data/datadriven/lic1/COPYING_complex2.txt new file mode 100644 index 00000000000..7936df300ac --- /dev/null +++ b/tests/licensedcode/data/datadriven/lic1/COPYING_complex2.txt @@ -0,0 +1,14 @@ +Except where noted otherwise in the file itself, the source code for all +Pacemaker programs is licensed under version 2 or later of the GNU General +Public License (GPLv2+), its headers and libraries under version 2.1 or +later of the less restrictive GNU Lesser General Public License (LGPLv2.1+), +its documentation under version 4.0 or later of the Creative Commons +Attribution-ShareAlike International Public License (CC-BY-SA v4.0+), +and its init scripts under the Revised BSD license. + +The text of these licenses are provided in the "licenses" subdirectory. + +If you find any deviations from this policy, or wish to inquire about alternate +licensing arrangements, please e-mail the developers@ClusterLabs.org mailing +list. Licensing issues are further discussed on the ClusterLabs wiki +(at https://wiki.clusterlabs.org/wiki/License). diff --git a/tests/licensedcode/data/datadriven/lic1/COPYING_complex2.txt.yml b/tests/licensedcode/data/datadriven/lic1/COPYING_complex2.txt.yml new file mode 100644 index 00000000000..de7131c427a --- /dev/null +++ b/tests/licensedcode/data/datadriven/lic1/COPYING_complex2.txt.yml @@ -0,0 +1,3 @@ +license_expressions: + - gpl-2.0-plus AND lgpl-2.1-plus AND cc-by-sa-4.0 AND bsd-new +notes: seen in https://raw.githubusercontent.com/ClusterLabs/pacemaker/main/COPYING diff --git a/tests/licensedcode/data/datadriven/lic1/d-zlib_and_gfdl-1.2_and_gpl_and_gpl_and_other.txt.yml b/tests/licensedcode/data/datadriven/lic1/d-zlib_and_gfdl-1.2_and_gpl_and_gpl_and_other.txt.yml index 4b2157219d2..2f3d60a8340 100644 --- a/tests/licensedcode/data/datadriven/lic1/d-zlib_and_gfdl-1.2_and_gpl_and_gpl_and_other.txt.yml +++ b/tests/licensedcode/data/datadriven/lic1/d-zlib_and_gfdl-1.2_and_gpl_and_gpl_and_other.txt.yml @@ -1,27 +1,20 @@ license_expressions: - - gpl-2.0-plus AND gpl-3.0-plus - - gpl-1.0-plus - - mif-exception - - gpl-1.0-plus - - ada-linking-exception - - gpl-1.0-plus - - gpl-1.0-plus - - gpl-1.0-plus - - gcc-compiler-exception-2.0 - - gpl-1.0-plus - - classpath-exception-2.0 - - gpl-1.0-plus WITH gcc-compiler-exception-2.0 AND gpl-1.0-plus WITH gcc-linking-exception-2.0 - - linking-exception-2.0-plus - - gpl-1.0-plus - - gpl-1.0-plus WITH gcc-linking-exception-2.0 - - gpl-1.0-plus - - linking-exception-2.0-plus - - gpl-2.0-plus - - unknown-license-reference - - d-zlib - - lgpl-2.1-plus - - linking-exception-2.0-plus - - unknown-license-reference - - mit - - gfdl-1.2 -notes: TODO refine expectations + - gpl-2.0-plus AND gpl-3.0-plus + - gpl-1.0-plus WITH mif-exception + - gpl-1.0-plus WITH ada-linking-exception + - gpl-1.0-plus + - gpl-1.0-plus + - gpl-1.0-plus WITH gcc-compiler-exception-2.0 + - gpl-1.0-plus WITH classpath-exception-2.0 + - gpl-1.0-plus WITH gcc-linking-exception-2.0 + - linking-exception-2.0-plus + - gpl-1.0-plus WITH gcc-linking-exception-2.0 + - gpl-1.0-plus WITH linking-exception-2.0-plus + - gpl-2.0-plus + - unknown-license-reference + - d-zlib + - lgpl-2.0-plus WITH linking-exception-2.0-plus + - unknown-license-reference + - mit + - gfdl-1.2 + diff --git a/tests/licensedcode/data/datadriven/lic1/eclipse-openj9_html.html.yml b/tests/licensedcode/data/datadriven/lic1/eclipse-openj9_html.html.yml index f5c1046be3a..3d623fd0278 100644 --- a/tests/licensedcode/data/datadriven/lic1/eclipse-openj9_html.html.yml +++ b/tests/licensedcode/data/datadriven/lic1/eclipse-openj9_html.html.yml @@ -1,6 +1,5 @@ license_expressions: - - epl-2.0 OR apache-2.0 OR (gpl-2.0 WITH classpath-exception-2.0 AND gpl-2.0 WITH openjdk-exception) - - epl-2.0 OR apache-2.0 + - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception - (epl-2.0 OR apache-2.0 OR (gpl-2.0 WITH classpath-exception-2.0 AND gpl-2.0 WITH openjdk-exception)) AND bsd-new AND mit AND gpl-3.0-plus WITH autoconf-simple-exception - epl-2.0 OR apache-2.0 diff --git a/tests/licensedcode/data/datadriven/lic1/eclipse-openj9_html2.html.yml b/tests/licensedcode/data/datadriven/lic1/eclipse-openj9_html2.html.yml index 02f620e3772..10aee0e7ff7 100644 --- a/tests/licensedcode/data/datadriven/lic1/eclipse-openj9_html2.html.yml +++ b/tests/licensedcode/data/datadriven/lic1/eclipse-openj9_html2.html.yml @@ -1,2 +1,2 @@ license_expressions: - - epl-2.0 OR apache-2.0 OR (gpl-2.0 WITH classpath-exception-2.0 AND gpl-2.0 WITH openjdk-exception) + - epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception diff --git a/tests/licensedcode/data/datadriven/lic1/erlware-relx.txt.yml b/tests/licensedcode/data/datadriven/lic1/erlware-relx.txt.yml index 4a7047a6dfa..a9e02b1a85a 100644 --- a/tests/licensedcode/data/datadriven/lic1/erlware-relx.txt.yml +++ b/tests/licensedcode/data/datadriven/lic1/erlware-relx.txt.yml @@ -1,4 +1,2 @@ license_expressions: - apache-2.0 - - apache-2.0 - - apache-2.0 \ No newline at end of file diff --git a/tests/licensedcode/data/datadriven/lic2/aes-128-3.0_and_bsd-new_and_bsd-original-uc_and_bsd-simplified_and_other.txt.yml b/tests/licensedcode/data/datadriven/lic2/aes-128-3.0_and_bsd-new_and_bsd-original-uc_and_bsd-simplified_and_other.txt.yml index 3a1139685ba..10906ec27db 100644 --- a/tests/licensedcode/data/datadriven/lic2/aes-128-3.0_and_bsd-new_and_bsd-original-uc_and_bsd-simplified_and_other.txt.yml +++ b/tests/licensedcode/data/datadriven/lic2/aes-128-3.0_and_bsd-new_and_bsd-original-uc_and_bsd-simplified_and_other.txt.yml @@ -49,6 +49,7 @@ license_expressions: - bsd-new - isc - json + - mit-old-style-no-advert - warranty-disclaimer - ijg - x11-tiff @@ -71,6 +72,7 @@ license_expressions: - bzip2-libbzip-2010 - bsd-new - sunpro + - sun-rpc - bsd-new - unicode-mappings - netcdf diff --git a/tests/licensedcode/data/datadriven/lic2/afl-2.1_and_apache_and_bsd-new_and_gpl_and_other.txt.yml b/tests/licensedcode/data/datadriven/lic2/afl-2.1_and_apache_and_bsd-new_and_gpl_and_other.txt.yml index 18c45d16fbb..32c192c6cd2 100644 --- a/tests/licensedcode/data/datadriven/lic2/afl-2.1_and_apache_and_bsd-new_and_gpl_and_other.txt.yml +++ b/tests/licensedcode/data/datadriven/lic2/afl-2.1_and_apache_and_bsd-new_and_gpl_and_other.txt.yml @@ -1,10 +1,6 @@ license_expressions: - bsd-new OR afl-2.1 - - mpl-1.0 OR lgpl-2.0-plus OR gpl-1.0-plus - - apache-2.0 - - apache-2.0 - - apache-2.0 - - afl-2.1 OR bsd-new + - (mpl-1.0 OR lgpl-2.0-plus OR gpl-1.0-plus) AND apache-2.0 AND apache-2.0 AND apache-2.0 AND apache-2.0 AND (bsd-new OR afl-2.1) - afl-2.1 OR bsd-new - bsd-new - bsd-new diff --git a/tests/licensedcode/data/datadriven/lic2/apache-1.1_and_apache-2.0_and_beerware_and_bsd-simplified-darwin_and_darwin-file_and_other.label.yml b/tests/licensedcode/data/datadriven/lic2/apache-1.1_and_apache-2.0_and_beerware_and_bsd-simplified-darwin_and_darwin-file_and_other.label.yml index d870f7c74f5..9000ce6a3a7 100644 --- a/tests/licensedcode/data/datadriven/lic2/apache-1.1_and_apache-2.0_and_beerware_and_bsd-simplified-darwin_and_darwin-file_and_other.label.yml +++ b/tests/licensedcode/data/datadriven/lic2/apache-1.1_and_apache-2.0_and_beerware_and_bsd-simplified-darwin_and_darwin-file_and_other.label.yml @@ -1,7 +1,7 @@ license_expressions: - apache-2.0 - apache-2.0 - - unknown-license-reference + - apache-2.0 AND other-permissive - apache-2.0 - hs-regexp - bsd-simplified-darwin diff --git a/tests/licensedcode/data/datadriven/lic2/apache-1.1_and_apache-2.0_and_cpl-1.0_and_epl-1.0_and_other.txt.yml b/tests/licensedcode/data/datadriven/lic2/apache-1.1_and_apache-2.0_and_cpl-1.0_and_epl-1.0_and_other.txt.yml index d7be8f53971..b2524969391 100644 --- a/tests/licensedcode/data/datadriven/lic2/apache-1.1_and_apache-2.0_and_cpl-1.0_and_epl-1.0_and_other.txt.yml +++ b/tests/licensedcode/data/datadriven/lic2/apache-1.1_and_apache-2.0_and_cpl-1.0_and_epl-1.0_and_other.txt.yml @@ -1,6 +1,6 @@ license_expressions: - apache-2.0 - - unknown-license-reference + - apache-2.0 AND other-permissive - mx4j - epl-1.0 - zlib diff --git a/tests/licensedcode/data/datadriven/lic2/newlib/newlib_license.txt.yml b/tests/licensedcode/data/datadriven/lic2/newlib/newlib_license.txt.yml index 80adc6e8370..a0cf833d22f 100644 --- a/tests/licensedcode/data/datadriven/lic2/newlib/newlib_license.txt.yml +++ b/tests/licensedcode/data/datadriven/lic2/newlib/newlib_license.txt.yml @@ -1,5 +1,5 @@ license_expressions: - - free-unknown + - bsd-new AND other-permissive AND other-copyleft - bsd-new - bsd-new - x11-lucent diff --git a/tests/licensedcode/data/datadriven/lic2/newlib/newlib_license_0.txt.yml b/tests/licensedcode/data/datadriven/lic2/newlib/newlib_license_0.txt.yml index d6e72bb422f..99b4ff63523 100644 --- a/tests/licensedcode/data/datadriven/lic2/newlib/newlib_license_0.txt.yml +++ b/tests/licensedcode/data/datadriven/lic2/newlib/newlib_license_0.txt.yml @@ -1,2 +1,2 @@ license_expressions: - - free-unknown + - bsd-new AND other-permissive AND other-copyleft diff --git a/tests/licensedcode/data/datadriven/lic3/man-pages-3.35-4.fc17.noarch.rpm.POSIX-COPYRIGHT.txt.yml b/tests/licensedcode/data/datadriven/lic3/man-pages-3.35-4.fc17.noarch.rpm.POSIX-COPYRIGHT.txt.yml index 1a1110c6cea..3ae72119e47 100644 --- a/tests/licensedcode/data/datadriven/lic3/man-pages-3.35-4.fc17.noarch.rpm.POSIX-COPYRIGHT.txt.yml +++ b/tests/licensedcode/data/datadriven/lic3/man-pages-3.35-4.fc17.noarch.rpm.POSIX-COPYRIGHT.txt.yml @@ -1,3 +1,4 @@ license_expressions: - other-permissive - - free-unknown + - other-permissive + diff --git a/tests/licensedcode/data/datadriven/lic3/nvidia-cuda.txt.yml b/tests/licensedcode/data/datadriven/lic3/nvidia-cuda.txt.yml index e6274a39cf7..70074d6adaf 100644 --- a/tests/licensedcode/data/datadriven/lic3/nvidia-cuda.txt.yml +++ b/tests/licensedcode/data/datadriven/lic3/nvidia-cuda.txt.yml @@ -1,3 +1,4 @@ license_expressions: - proprietary-license + - generic-trademark notes: From http://docs.nvidia.com/cuda/cuda-samples/index.html diff --git a/tests/licensedcode/data/datadriven/lic4/sun-jsr-spec-01-2006.txt.yml b/tests/licensedcode/data/datadriven/lic4/sun-jsr-spec-01-2006.txt.yml index 3ddcfe0bf39..d5f45cf929a 100644 --- a/tests/licensedcode/data/datadriven/lic4/sun-jsr-spec-01-2006.txt.yml +++ b/tests/licensedcode/data/datadriven/lic4/sun-jsr-spec-01-2006.txt.yml @@ -1,2 +1,3 @@ license_expressions: + - proprietary-license - sun-jsr-spec-04-2006 diff --git a/tests/licensedcode/data/datadriven/lic4/sun-jsr-spec-04-2006_2.txt.yml b/tests/licensedcode/data/datadriven/lic4/sun-jsr-spec-04-2006_2.txt.yml index 2f50742e3aa..8f47144a465 100644 --- a/tests/licensedcode/data/datadriven/lic4/sun-jsr-spec-04-2006_2.txt.yml +++ b/tests/licensedcode/data/datadriven/lic4/sun-jsr-spec-04-2006_2.txt.yml @@ -1,3 +1,4 @@ license_expressions: + - proprietary-license - sun-jsr-spec-04-2006 notes: this is not really the exact same license but is very close and arcane enough diff --git a/tests/licensedcode/data/datadriven/lic4/sun-jta-spec-1.0.1B.txt.yml b/tests/licensedcode/data/datadriven/lic4/sun-jta-spec-1.0.1B.txt.yml index d7d956c3f94..b6729491fe6 100644 --- a/tests/licensedcode/data/datadriven/lic4/sun-jta-spec-1.0.1B.txt.yml +++ b/tests/licensedcode/data/datadriven/lic4/sun-jta-spec-1.0.1B.txt.yml @@ -1,4 +1,5 @@ license_expressions: + - proprietary-license - unknown-license-reference - unknown-license-reference - sun-jta-spec-1.0.1 diff --git a/tests/licensedcode/data/datadriven/unknown/README.md b/tests/licensedcode/data/datadriven/unknown/README.md new file mode 100644 index 00000000000..be5030cbf5a --- /dev/null +++ b/tests/licensedcode/data/datadriven/unknown/README.md @@ -0,0 +1,51 @@ +# Metafour’s Logistics Applications Terms of Use + +## 1. Terms of use +These terms of use apply to all Metafour applications and by using the applications you agree to abide by them. Metafour may change these terms from time to time. +## 2. Copyright +The applications are owned or licensed by Metafour and are protected by copyright. None of the application may be copied or reproduced for commercial purposes without Metafour’s prior written consent. +## 3. Your use of the software +You may only use the application for lawful purposes. + +You may not use the application to process offensive, obscene, discriminatory or indecent material. You may not use the application to send unsolicited “nuisance” emails. You must use the application in accordance with applicable legislation, including the GDPR. + +Metafour may suspend or terminate access at its sole discretion without prior notice if we determine that you have violated these terms of use or guidelines which may be associated with your use of the application. +## 4. Accounts, passwords and security +Use of the application requires you to have a user account protected by authentication (for example, a user name and password). + +You are responsible for maintaining the confidentiality of the authentication and for all activity that occurs under your account as a result of your failing to keep these details secure. You may not allow anybody else to user your account. You must notify Metafour immediately of any unauthorised use of your account or any other breach of security. + +Metafour is not liable for loss or damage arising from your failure to comply with these obligations and you may be held liable for losses incurred by Metafour as a result of your failing to keep your account authentication confidential. +## 5. Privacy +Metafour takes the privacy of your data seriously and works hard to ensure that it is protected in accordance with the GDPR. + +Data is stored and processed to facilitate the processing of logistics shipments and is retained only for as long as Metafour deems necessary for that purpose. + +Metafour transfers data to individuals and organisations in your supply chain, including the sender and consignee. The data recipients may be located in another country. + +The application utilises automated decision making and profiling to facilitate efficient and cost-effective processing. + +We may use cookies to collect information about your computer (including your IP address, operating system and browser type) for system administration and in order to create reports. This is statistical data about our user’s browsing actions and patterns and does not identify any individual. + +Metafour may disclose information we have about you if we determine that: a) such disclosure is necessary in connection with any investigation or complaint regarding your use of the application; or b) applicable law requires or permits such disclosure, including exchanging information with other companies and organisations for fraud protection purposes. +## 6. Links to external sites +The application may contain links to independent third-party sites. Such linked sites are not under Metafour’s control and Metafour is not responsible for and does not endorse their content. +## 7. Disclaimers +Metafour works continually to improve the application and we publish enhancements without notice. + +We implement strong test procedures before software is released but cannot guarantee that the application is error-free; the application is provided on an "as-is" and “as-available" basis. + +Metafour cannot guarantee that any data you download from the software will be free of viruses, contamination or destructive features. + +Metafour’s liability for damage caused by any failure of performance, omission, interruption, deletion, defect, delay, computer virus or unauthorised access, whether for breach of contract, tort, negligence or any other cause of action, is limited to the remedies set out in Metafour’s Terms & Conditions of Supply with the organisation who pays for the use of the application. +## 8. Feedback and Information +Any feedback you provide to Metafour shall be deemed to be non-confidential and Metafour shall be free to use such information on an unrestricted basis unless you request otherwise. +## 9. Governing law +All matters relating to your use of the application shall be governed by the laws of the UK. Any claim under these terms of use must be brought within one year after the cause of action arises. + + +Copyright © 2018. All rights reserved. + +Metafour UK Ltd, 2 Berghem Mews, London W14 0HN, UK + +Created on 02/05/2018 \ No newline at end of file diff --git a/tests/licensedcode/data/datadriven/unknown/README.md.yml b/tests/licensedcode/data/datadriven/unknown/README.md.yml new file mode 100644 index 00000000000..4a6f36c08b6 --- /dev/null +++ b/tests/licensedcode/data/datadriven/unknown/README.md.yml @@ -0,0 +1,4 @@ +license_expressions: + - unknown-license-reference + - unknown-license-reference + diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/cclrc.txt b/tests/licensedcode/data/datadriven/unknown/cclrc.txt similarity index 100% rename from tests/licensedcode/data/datadriven/external/fossology-licenses/cclrc.txt rename to tests/licensedcode/data/datadriven/unknown/cclrc.txt diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/cclrc.txt.yml b/tests/licensedcode/data/datadriven/unknown/cclrc.txt.yml similarity index 93% rename from tests/licensedcode/data/datadriven/external/fossology-licenses/cclrc.txt.yml rename to tests/licensedcode/data/datadriven/unknown/cclrc.txt.yml index 4863aee120e..08c47be739c 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-licenses/cclrc.txt.yml +++ b/tests/licensedcode/data/datadriven/unknown/cclrc.txt.yml @@ -1,3 +1,4 @@ license_expressions: + - unknown - warranty-disclaimer notes: this is a license from fossology license reference CCLRC (CCLRC License) http://www2-pcmdi.llnl.gov/cdat/docs/cdat-license diff --git a/tests/licensedcode/data/datadriven/unknown/cigna-go-you-mobile-app-eula.txt b/tests/licensedcode/data/datadriven/unknown/cigna-go-you-mobile-app-eula.txt new file mode 100644 index 00000000000..1a98ef70975 --- /dev/null +++ b/tests/licensedcode/data/datadriven/unknown/cigna-go-you-mobile-app-eula.txt @@ -0,0 +1,141 @@ +APPLE END USER LICENSE AGREEMENT +This End User License Agreement (the “Agreement”) for the Cigna GO YOU Mobile Application (together with any +updates, upgrades or patches, the “Application”) is a legal agreement between user (“You” or “Your”), and Cigna +Corporate Services, LLC, its successors and/or assigns (“Cigna”). By accessing, downloading, copying or otherwise +using the Application, You acknowledge that You have read this Agreement, understand it, and agree to be +bound by its terms and conditions. If You do not agree to the terms and conditions of this Agreement, do not +access, download, copy or use the Application. Cigna will not and does not grant You access to the Application +unless You agree to the terms of this Agreement. +In consideration of the promises and covenants described below, and other good and valuable consideration, You +agree as follows: +1. +License Grant; Compliance with Terms of Use. The Application is licensed, not sold, and Cigna reserves all rights +not expressly granted in this Agreement. Subject to the terms and conditions hereof, Cigna grants You a personal, +nonexclusive, nontransferable, non-sublicenseable, limited license to download and use the Application on an iPhone or +iPod touch that You own or control. +2. +License Restrictions. Except as specifically provided herein, You may not: (i) distribute or make the Application +available over a network where it could be used by multiple devices at the same time; (ii) copy the Application; (iii) modify, +adapt, translate, reverse engineer, make alterations, decompile, disassemble or make derivative works based on the +Application, except as otherwise permitted by law; or (iv) rent, loan, sub-license, lease, distribute or attempt to grant other +rights to the Application to third parties. +3. +Ownership. All of the content featured or displayed in or through the Application, including without limitation text, +graphics, photographs, images, moving images, sound, and illustrations ("Content") and all trademarks, service marks +and trade names included therein, are owned by Cigna, or its licensors, vendors, agents and/or its Content providers. All +elements of the Application, including without limitation the general design and the Content, are protected by trade dress, +copyright, moral rights, trademark and other laws relating to intellectual property rights. Any text that You include with any +Content (“Messages”), are owned by You. All Content and Messages are subject to Cigna’s Terms of Use, as may be +amended from time to time, and as incorporated herein by this reference (available on the platform where You download +the Application and via the information link on the Application welcome screen). ALL RIGHTS NOT EXPRESSLY +GRANTED HEREIN ARE RESERVED TO CIGNA. +4. +Your Warranty to Cigna. You represent and warrant that: (i) You have the authority to bind Yourself to this +Agreement; (ii) Your use of the Application will be solely for purposes that are permitted by this Agreement; (iii) You are +not located in a country that is subject to a U.S. government embargo, or that has been designated by the U.S. +government as a “terrorist supporting” country; (iv) You are not listed on any U.S. government list of prohibited or +restricted parties; and (v) Your use of the Application will comply with all local, state and federal laws, rules, and +regulations (“Laws”). +5. +Privacy. By using the Application, you agree that Cigna and its agents, contractors, affiliates and promotional +partners may collect and use certain information about you, your mobile device, your use of the Application and the +Application’s performance in accordance with the Privacy Policy, as may be amended from time to time and incorporated +herein by this reference (available on the platform where You download the Application and via the information link on the +Application welcome screen). +6. +Apple Store. In the event that You download this Application from Apple, Inc. (“Apple”): (i) You agree that Apple +and its subsidiaries are third party beneficiaries of this Agreement, and that, upon Your acceptance of this Agreement, +Apple will have the right to (and will be deemed to have accepted the right) to enforce this Agreement against You as the +third party beneficiary thereof; (ii) You acknowledge and agree that Cigna, and not Apple, are responsible for addressing +any claims You or any third party may have in relation to the Application; and (iii) in the event of any failure of the +Application to conform to any applicable warranty, as Your sole and exclusive remedy with Apple, You may notify Apple of +such failure. Upon notification Apple will refund the purchase price for the Application (if any) to You. + +DWT 19339983v3 0062274-000284 + + 7. +Maintenance and Support. Neither Cigna nor Apple have any obligation whatsoever to furnish any maintenance +and support service with respect to the Application. +8. +Disclaimer of Warranties and Indemnification. Neither Cigna nor any of its parents, affiliates, franchisees, +suppliers, agents, promotional partners, vendors or contractors, any of their successors, or any of their respective officers, +directors or employees (collectively the “Cigna Parties”) will be liable for losses or damages arising from or in any way +related to Your access to or use of the Application. TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, +CIGNA AND THE CIGNA PARTIES ARE LICENSING THE APPLICATION “AS IS,” “AS AVAILABLE,” AND “WITH ALL +FAULTS.” NEITHER CIGNA NOR THE CIGNA PARTIES MAKE ANY REPRESENTATIONS OR WARRANTIES ABOUT +THE SUITABILITY, RELIABILITY, TIMELINESS, AND ACCURACY, FOR ANY PURPOSE, OF THE APPLICATION, THE +OPERATION OF THE APPLICATION ALONE OR IN CONJUNCTION WITH ANY DEVICE, OR THE CONTENT +CONTAINED HEREIN. CIGNA AND THE CIGNA PARTIES DISCLAIM ALL WARRANTIES, EITHER EXPRESS OR +IMPLIED, REGARDING THE APPLICATION AND ITS OPERATION AND EXPRESSLY DISCLAIMS THE IMPLIED +WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. +9. +Limitation of Liability. TO THE MAXIMUM EXTENT NOT PROHIBITED BY LAW, IN NO EVENT SHALL CIGNA +OR THE CIGNA PARTIES BE LIABLE FOR ANY CONSEQUENTIAL, INDIRECT, INCIDENTAL, PUNITIVE, SPECIAL +OR OTHER RELATED OR SIMILAR DAMAGES WHATSOEVER, INCLUDING WITHOUT LIMITATION, DAMAGES FOR +LOSS OF BUSINESS PROFITS, BUSINESS INTERRUPTION, LOSS OF BUSINESS INFORMATION, AND THE LIKE +CONNECTED WITH THE USE OF OR INABILITY TO USE THE APPLICATION, AND FOR ANY CAUSE OF ACTION, +INCLUDING CONTRACT, TORT (INCLUDING NEGLIGENCE) OR OTHERWISE, EVEN IF CIGNA OR THE CIGNA +PARTIES HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. ANY DAMAGES ARISING UNDER THIS +AGREEMENT OR THE USE OF THE APPLICATION THAT CIGNA OR THE CIGNA PARTIES IS REQUIRED TO PAY +FOR ANY PURPOSE WHATSOEVER, INCLUDING WITHOUT LIMITATION, CONTRACT, TORT (INCLUDING +NEGLIGENCE) OR OTHERWISE, SHALL BE LIMITED TO TWENTY FIVE DOLLARS ($25.00). SOME STATES DO +NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES, +SO THE ABOVE LIMITATION MAY NOT APPLY TO YOU UNDER THE LAWS OF THOSE STATES. No action, +regardless of form, whether in court or through arbitration, arising out of any transaction under this Agreement, may be +brought by You more than one year after You have knowledge of the occurrence which gives rise to the cause of such +action. +10. +Indemnity. You agree to indemnify and hold harmless Cigna, the Cigna Parties, and their affiliates, officers, +directors, employees, consultants, agents and anyone providing information or software used in the Application from any +and all claims arising from, related to, or incidental to Your use of the Application. +11. +Termination. This Agreement is effective until terminated. Cigna may immediately terminate this Agreement at +any time at its sole discretion with or without notice to You. Additionally, Your rights under this Agreement will terminate +automatically if You fail to comply with any term(s) of this Agreement. Upon termination, all legal rights and licenses +granted to You hereunder shall terminate immediately and You shall cease all use of the Application and destroy all +copies of the Application. All sections that may be reasonably interpreted to or are intended to survive this Agreement will +survive this Agreement. +12. +Governing Law. This Agreement shall be governed by the laws of the Commonwealth of Pennsylvania in the +United States, without giving effect to the Commonwealth of Pennsylvania’s choice of law principles. You irrevocably +consent to the exclusive jurisdiction and venue of the state or federal courts in Philadelphia, Pennsylvania for all disputes +arising out of or relating to this Agreement. If any action is brought to enforce, or arises out of, the Agreement or any +term, clause, or provision hereof, the prevailing party shall be awarded its reasonable attorney’s fees together with +expenses and costs incurred with such action. +13. +Acknowledgment of Understanding/Entire Agreement. You acknowledge that You have read this Agreement, +understand it and agree to be bound by its terms and conditions. You also agree that this Agreement is the complete and +exclusive statement of the Agreement between Cigna and You and supersedes all proposals, representations or prior +agreements, oral or written, and any other communications between Cigna and You relating to the subject matter of this +Agreement. + +2 +DWT 19339983v3 0062274-000284 + + 14. +Severability. You agree that the terms and conditions stated in this Agreement are severable. If any paragraph, +provision, or clause in this Agreement shall be found or be held to be invalid or unenforceable in any jurisdiction, the +remainder of this Agreement shall be valid and enforceable. +15. +Assignment and Transfer. Cigna may assign, transfer, sell, rent or lend this Agreement, in whole or in part, at any +time without notice to You. You may not assign this Agreement or any part of it or any rights to use the Application, in +whole or in part, either temporarily or permanently, to any other party. Any attempt to do so is void. +16. +Additional Assistance. If You have any questions, complaints, or claims with respect to the Application or this +Agreement, You may contact us at Cigna, 900 Cottage Grove Road, B4MKT, Bloomfield, CT 06152 or by sending an +email to LetUsHelpU@Cigna.com. +17. +Amendment of this Agreement. CIGNA RESERVES THE RIGHT TO MODIFY OR AMEND THIS AGREEMENT +FROM TIME TO TIME WITHOUT NOTICE. YOUR CONTINUED USE OF THE APPLICATION FOLLOWING THE +POSTING OF CHANGES TO THE AGREEMENT WILL MEAN YOU ACCEPT THOSE CHANGES. + +IF YOU ACCEPT AND AGREE TO THESE TERMS AND CONDITIONS YOU MAY USE AND DOWNLOAD THE +APPLICATION. + +IF YOU DO NOT ACCEPT AND AGREE TO THESE TERMS AND CONDITIONS DO NOT DOWNLOAD OR USE THE +APPLICATION. + +3 +DWT 19339983v3 0062274-000284 + + \ No newline at end of file diff --git a/tests/licensedcode/data/datadriven/unknown/cigna-go-you-mobile-app-eula.txt.yml b/tests/licensedcode/data/datadriven/unknown/cigna-go-you-mobile-app-eula.txt.yml new file mode 100644 index 00000000000..36499863193 --- /dev/null +++ b/tests/licensedcode/data/datadriven/unknown/cigna-go-you-mobile-app-eula.txt.yml @@ -0,0 +1,9 @@ +license_expressions: + - proprietary-license + - proprietary-license + - unknown-license-reference + - unknown-license-reference + - warranty-disclaimer + - warranty-disclaimer + - warranty-disclaimer +notes: this is using unknwown license detection diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/cisco.txt b/tests/licensedcode/data/datadriven/unknown/cisco.txt similarity index 100% rename from tests/licensedcode/data/datadriven/external/fossology-licenses/cisco.txt rename to tests/licensedcode/data/datadriven/unknown/cisco.txt diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/cisco.txt.yml b/tests/licensedcode/data/datadriven/unknown/cisco.txt.yml similarity index 76% rename from tests/licensedcode/data/datadriven/external/fossology-licenses/cisco.txt.yml rename to tests/licensedcode/data/datadriven/unknown/cisco.txt.yml index b74b9167209..eee0e3eee18 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-licenses/cisco.txt.yml +++ b/tests/licensedcode/data/datadriven/unknown/cisco.txt.yml @@ -1,6 +1,6 @@ license_expressions: - - unknown-license-reference - - unknown-license-reference + - unknown - warranty-disclaimer + - unknown notes: this is a license from fossology license reference Cisco (Cisco Software License Agreement) http://www.cisco.com/public/sw-license-agreement.html diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/citrix.txt b/tests/licensedcode/data/datadriven/unknown/citrix.txt similarity index 100% rename from tests/licensedcode/data/datadriven/external/fossology-licenses/citrix.txt rename to tests/licensedcode/data/datadriven/unknown/citrix.txt diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/citrix.txt.yml b/tests/licensedcode/data/datadriven/unknown/citrix.txt.yml similarity index 91% rename from tests/licensedcode/data/datadriven/external/fossology-licenses/citrix.txt.yml rename to tests/licensedcode/data/datadriven/unknown/citrix.txt.yml index fbc737bb66b..89b7f757c6e 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-licenses/citrix.txt.yml +++ b/tests/licensedcode/data/datadriven/unknown/citrix.txt.yml @@ -1,10 +1,11 @@ license_expressions: - - unknown-license-reference + - unknown - gpl-1.0-plus - free-unknown - warranty-disclaimer - free-unknown - free-unknown - commercial-license + - unknown notes: this is a license from fossology license reference Citrix (CITRIX LICENSE AGREEMENT) http://www.citrix.com/content/dam/citrix/en_us/documents/buy/XS_EULA_English.pdf diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/majordomo-1.1.txt b/tests/licensedcode/data/datadriven/unknown/majordomo-1.1.txt similarity index 100% rename from tests/licensedcode/data/datadriven/external/fossology-licenses/majordomo-1.1.txt rename to tests/licensedcode/data/datadriven/unknown/majordomo-1.1.txt diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/majordomo-1.1.txt.yml b/tests/licensedcode/data/datadriven/unknown/majordomo-1.1.txt.yml similarity index 94% rename from tests/licensedcode/data/datadriven/external/fossology-licenses/majordomo-1.1.txt.yml rename to tests/licensedcode/data/datadriven/unknown/majordomo-1.1.txt.yml index a0df14b1779..7f99306c75e 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-licenses/majordomo-1.1.txt.yml +++ b/tests/licensedcode/data/datadriven/unknown/majordomo-1.1.txt.yml @@ -1,5 +1,6 @@ license_expressions: - unknown-license-reference - warranty-disclaimer + - unknown notes: this is a license from fossology license reference Majordomo-1.1 (Majordomo License Agreement) http://www.greatcircle.com/majordomo/LICENSE diff --git a/tests/licensedcode/data/datadriven/external/fossology-tests/MPL/opl-1.0.txt b/tests/licensedcode/data/datadriven/unknown/opl-1.0.txt similarity index 100% rename from tests/licensedcode/data/datadriven/external/fossology-tests/MPL/opl-1.0.txt rename to tests/licensedcode/data/datadriven/unknown/opl-1.0.txt diff --git a/tests/licensedcode/data/datadriven/external/fossology-tests/MPL/opl-1.0.txt.yml b/tests/licensedcode/data/datadriven/unknown/opl-1.0.txt.yml similarity index 90% rename from tests/licensedcode/data/datadriven/external/fossology-tests/MPL/opl-1.0.txt.yml rename to tests/licensedcode/data/datadriven/unknown/opl-1.0.txt.yml index db0083dd223..3a7648a4787 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-tests/MPL/opl-1.0.txt.yml +++ b/tests/licensedcode/data/datadriven/unknown/opl-1.0.txt.yml @@ -2,8 +2,10 @@ license_expressions: - mpl-1.1 - mpl-1.1 - unknown-license-reference + - unknown - free-unknown - warranty-disclaimer + - unknown - unknown-license-reference - generic-trademark notes: this is an mpl-1.1 derivative which is very rare. diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/qt.commercial.txt b/tests/licensedcode/data/datadriven/unknown/qt.commercial.txt similarity index 100% rename from tests/licensedcode/data/datadriven/external/fossology-licenses/qt.commercial.txt rename to tests/licensedcode/data/datadriven/unknown/qt.commercial.txt diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/qt.commercial.txt.yml b/tests/licensedcode/data/datadriven/unknown/qt.commercial.txt.yml similarity index 86% rename from tests/licensedcode/data/datadriven/external/fossology-licenses/qt.commercial.txt.yml rename to tests/licensedcode/data/datadriven/unknown/qt.commercial.txt.yml index f74a22977f3..efb2f8caeb8 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-licenses/qt.commercial.txt.yml +++ b/tests/licensedcode/data/datadriven/unknown/qt.commercial.txt.yml @@ -1,15 +1,22 @@ license_expressions: - commercial-license - commercial-license + - unknown - unknown-license-reference - lgpl-2.1 AND gpl-2.0 AND gpl-3.0 - lgpl-2.0-plus AND gpl-1.0-plus - lgpl-2.1 AND gpl-2.0 AND gpl-3.0 + - unknown - commercial-license + - unknown - commercial-license + - unknown - commercial-license + - unknown - commercial-license + - unknown - commercial-license - commercial-license + - unknown notes: this is a license from fossology license reference QT.Commercial (QT Commercial License Agreement 3.8) http://qt.nokia.com/files/pdf/licenses/qtdesktop_us_v3_8.pdf diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/scea.txt b/tests/licensedcode/data/datadriven/unknown/scea.txt similarity index 100% rename from tests/licensedcode/data/datadriven/external/fossology-licenses/scea.txt rename to tests/licensedcode/data/datadriven/unknown/scea.txt diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/scea.txt.yml b/tests/licensedcode/data/datadriven/unknown/scea.txt.yml similarity index 76% rename from tests/licensedcode/data/datadriven/external/fossology-licenses/scea.txt.yml rename to tests/licensedcode/data/datadriven/unknown/scea.txt.yml index c04914f5978..d8c5b03fac5 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-licenses/scea.txt.yml +++ b/tests/licensedcode/data/datadriven/unknown/scea.txt.yml @@ -2,9 +2,8 @@ license_expressions: - scea-1.0 - unknown-license-reference - scea-1.0 - - unknown-license-reference - - unknown-license-reference - - unknown-license-reference + - unknown + - unknown notes: this is a license from fossology license reference SCEA (SCEA Shared Source License) http://research.scea.com/scea_shared_source_license.html This is a rather moot tests where the text was truncated and modified diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/ucware-eula.txt b/tests/licensedcode/data/datadriven/unknown/ucware-eula.txt similarity index 100% rename from tests/licensedcode/data/datadriven/external/fossology-licenses/ucware-eula.txt rename to tests/licensedcode/data/datadriven/unknown/ucware-eula.txt diff --git a/tests/licensedcode/data/datadriven/external/fossology-licenses/ucware-eula.txt.yml b/tests/licensedcode/data/datadriven/unknown/ucware-eula.txt.yml similarity index 96% rename from tests/licensedcode/data/datadriven/external/fossology-licenses/ucware-eula.txt.yml rename to tests/licensedcode/data/datadriven/unknown/ucware-eula.txt.yml index d33e0b511c2..650f8d38a53 100644 --- a/tests/licensedcode/data/datadriven/external/fossology-licenses/ucware-eula.txt.yml +++ b/tests/licensedcode/data/datadriven/unknown/ucware-eula.txt.yml @@ -1,6 +1,7 @@ license_expressions: - unknown-license-reference - unknown-license-reference + - unknown - warranty-disclaimer - warranty-disclaimer notes: this is a license from fossology license reference UCWare-EULA (UCWare Software License diff --git a/tests/licensedcode/data/datadriven/unknown_about/unknown.origins b/tests/licensedcode/data/datadriven/unknown_about/unknown.origins new file mode 100644 index 00000000000..5e7b1333520 --- /dev/null +++ b/tests/licensedcode/data/datadriven/unknown_about/unknown.origins @@ -0,0 +1,3 @@ +date: 2022-01-07 +download_url: https://raw.githubusercontent.com/Metafour-Int/netcourier-terms-of-use/master/README.md +download_url: https://www.cigna.com/pdf/cigna-go-you-mobile-app-eula.pdf diff --git a/tests/licensedcode/licensedcode_test_utils.py b/tests/licensedcode/licensedcode_test_utils.py index a25e25504b2..68e4c67b04b 100644 --- a/tests/licensedcode/licensedcode_test_utils.py +++ b/tests/licensedcode/licensedcode_test_utils.py @@ -147,7 +147,7 @@ def load_from(test_dir): ] -def build_tests(test_dir, clazz, regen=False): +def build_tests(test_dir, clazz, unknown_detection=False, regen=False): """ Dynamically build license_test methods from a sequence of LicenseTest and attach these method to the clazz license test class. @@ -162,7 +162,11 @@ def build_tests(test_dir, clazz, regen=False): test_file = license_test.test_file # closure on the license_test params - test_method = make_test(license_test, regen=regen) + test_method = make_test( + license_test, + unknown_detection=unknown_detection, + regen=regen, + ) # avoid duplicated test method if hasattr(clazz, test_name): @@ -175,7 +179,7 @@ def build_tests(test_dir, clazz, regen=False): setattr(clazz, test_name, test_method) -def make_test(license_test, regen=False): +def make_test(license_test, unknown_detection=False, regen=False): """ Build and return a test function closing on tests arguments for a license_test LicenseTest object. @@ -193,7 +197,11 @@ def make_test(license_test, regen=False): def closure_test_function(*args, **kwargs): idx = cache.get_index() - matches = idx.match(location=test_file, min_score=0) + matches = idx.match( + location=test_file, + min_score=0, + unknown_licenses=unknown_detection, + ) if not matches: matches = [] @@ -210,7 +218,11 @@ def closure_test_function(*args, **kwargs): # On failure, we compare against more result data to get additional # failure details, including the test_file and full match details expected = expected_expressions + ['======================', ''] - results_failure_trace = detected_expressions[:] + ['======================', ''] + results_failure_trace = ( + detected_expressions[:] + +['======================', ''] + ) + for match in matches: qtext, itext = get_texts(match) rule_text_file = match.rule.text_file diff --git a/tests/licensedcode/test_detection_datadriven1.py b/tests/licensedcode/test_detection_datadriven1.py index fbabb0aea3c..ec1cc52d022 100644 --- a/tests/licensedcode/test_detection_datadriven1.py +++ b/tests/licensedcode/test_detection_datadriven1.py @@ -18,7 +18,6 @@ pytestmark = pytest.mark.scanslow - """ Data-driven tests using expectations stored in YAML files. Test functions are attached to test classes at module import time @@ -26,9 +25,11 @@ TEST_DIR = abspath(join(dirname(__file__), 'data')) + class TestLicenseDataDriven1(unittest.TestCase): pass + build_tests( join(TEST_DIR, 'datadriven/lic1'), clazz=TestLicenseDataDriven1, regen=False) diff --git a/tests/licensedcode/test_detection_datadriven2.py b/tests/licensedcode/test_detection_datadriven2.py index 95a9d9f1e70..ebc050ceef6 100644 --- a/tests/licensedcode/test_detection_datadriven2.py +++ b/tests/licensedcode/test_detection_datadriven2.py @@ -18,7 +18,6 @@ pytestmark = pytest.mark.scanslow - """ Data-driven tests using expectations stored in YAML files. Test functions are attached to test classes at module import time @@ -26,9 +25,11 @@ TEST_DIR = abspath(join(dirname(__file__), 'data')) + class TestLicenseDataDriven2(unittest.TestCase): pass + build_tests( join(TEST_DIR, 'datadriven/lic2'), clazz=TestLicenseDataDriven2, regen=False) diff --git a/tests/licensedcode/test_detection_datadriven3.py b/tests/licensedcode/test_detection_datadriven3.py index ccef4057a0f..354483485e8 100644 --- a/tests/licensedcode/test_detection_datadriven3.py +++ b/tests/licensedcode/test_detection_datadriven3.py @@ -18,7 +18,6 @@ pytestmark = pytest.mark.scanslow - """ Data-driven tests using expectations stored in YAML files. Test functions are attached to test classes at module import time @@ -26,9 +25,11 @@ TEST_DIR = abspath(join(dirname(__file__), 'data')) + class TestLicenseDataDriven3(unittest.TestCase): pass + build_tests( join(TEST_DIR, 'datadriven/lic3'), clazz=TestLicenseDataDriven3, regen=False) diff --git a/tests/licensedcode/test_detection_datadriven4.py b/tests/licensedcode/test_detection_datadriven4.py index 7036e9b1b5a..008cd053def 100644 --- a/tests/licensedcode/test_detection_datadriven4.py +++ b/tests/licensedcode/test_detection_datadriven4.py @@ -18,7 +18,6 @@ pytestmark = pytest.mark.scanslow - """ Data-driven tests using expectations stored in YAML files. Test functions are attached to test classes at module import time @@ -26,9 +25,11 @@ TEST_DIR = abspath(join(dirname(__file__), 'data')) + class TestLicenseDataDriven4(unittest.TestCase): pass + build_tests( join(TEST_DIR, 'datadriven/lic4'), clazz=TestLicenseDataDriven4, regen=False) diff --git a/tests/licensedcode/test_detection_datadriven_external.py b/tests/licensedcode/test_detection_datadriven_external.py index 99f5b23fa8f..d26b8386bf4 100644 --- a/tests/licensedcode/test_detection_datadriven_external.py +++ b/tests/licensedcode/test_detection_datadriven_external.py @@ -18,7 +18,6 @@ pytestmark = pytest.mark.scanslow - """ Data-driven tests using expectations stored in YAML files. Test functions are attached to test classes at module import time @@ -30,6 +29,7 @@ class TestDataDrivenExternal(unittest.TestCase): pass + build_tests( join(TEST_DIR, 'datadriven/external'), clazz=TestDataDrivenExternal, regen=False) diff --git a/tests/licensedcode/test_detection_datadriven_unknown.py b/tests/licensedcode/test_detection_datadriven_unknown.py new file mode 100644 index 00000000000..903d0acd91a --- /dev/null +++ b/tests/licensedcode/test_detection_datadriven_unknown.py @@ -0,0 +1,38 @@ +# +# Copyright (c) nexB Inc. and others. All rights reserved. +# ScanCode is a trademark of nexB Inc. +# SPDX-License-Identifier: Apache-2.0 +# See http://www.apache.org/licenses/LICENSE-2.0 for the license text. +# See https://github.com/nexB/scancode-toolkit for support or download. +# See https://aboutcode.org for more information about nexB OSS projects. +# + +from os.path import abspath +from os.path import join +from os.path import dirname +import unittest + +import pytest + +from licensedcode_test_utils import build_tests # NOQA + +pytestmark = pytest.mark.scanslow + +""" +Data-driven tests using expectations stored in YAML files for unknown license. +Test functions are attached to test classes at module import time. +""" + +TEST_DIR = abspath(join(dirname(__file__), 'data')) + + +class TestLicenseDataDrivenUnknown(unittest.TestCase): + pass + + +build_tests( + join(TEST_DIR, 'datadriven/unknown'), + clazz=TestLicenseDataDrivenUnknown, + unknown_detection=True, + regen=False, +) diff --git a/tests/licensedcode/test_match.py b/tests/licensedcode/test_match.py index 5d7394fc529..b4a41ed2f53 100644 --- a/tests/licensedcode/test_match.py +++ b/tests/licensedcode/test_match.py @@ -1405,7 +1405,7 @@ def test_get_full_matched_text_base(self): match, query_string=querys, idx=idx, - highlight_not_matched=u'%s', + highlight_not_matched='{}', )) assert origin_matched_text == expected_origin_text @@ -1450,7 +1450,7 @@ def test_get_full_matched_text(self): IN NO EVENT SHALL THE
best
CODEHAUS OR ITS CONTRIBUTORS BE LIABLE EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. """ matched_text = u''.join(get_full_matched_text( - match, query_string=querys, idx=idx, highlight_not_matched=u'
%s
', _usecache=False)) + match, query_string=querys, idx=idx, highlight_not_matched='
{}
', _usecache=False)) assert matched_text == expected # test again using whole_lines @@ -1459,7 +1459,7 @@ def test_get_full_matched_text(self): IN NO EVENT SHALL THE best CODEHAUS OR ITS CONTRIBUTORS BE LIABLE EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. chabada DAMAGE 12 ABC\n""" matched_text = u''.join(get_full_matched_text( - match, query_string=querys, idx=idx, highlight_not_matched=u'%s', whole_lines=True)) + match, query_string=querys, idx=idx, highlight_not_matched='{}', whole_lines=True)) assert matched_text == expected def test_get_full_matched_text_does_not_munge_underscore(self): diff --git a/tests/licensedcode/test_match_spdx_lid.py b/tests/licensedcode/test_match_spdx_lid.py index 50a6826da0c..5d8040d0644 100644 --- a/tests/licensedcode/test_match_spdx_lid.py +++ b/tests/licensedcode/test_match_spdx_lid.py @@ -363,7 +363,7 @@ def test_get_expression_without_lid(self): assert all(s.wrapped for s in licensing.license_symbols(expression, decompose=True)) - def test_get_expression_complex_with_unknown_symbols_and_refs(self): + def test_get_expression_complex_with_other_spdx_symbols_and_refs(self): licensing = Licensing() spdx_symbols = get_spdx_symbols() unknown_symbol = get_unknown_spdx_symbol() @@ -374,10 +374,10 @@ def test_get_expression_complex_with_unknown_symbols_and_refs(self): expression = get_expression(line_text, licensing, spdx_symbols, unknown_symbol) - expected = 'epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR unknown-spdx WITH unknown-spdx' + expected = 'epl-2.0 OR apache-2.0 OR gpl-2.0 WITH classpath-exception-2.0 OR gpl-2.0 WITH openjdk-exception' assert expression.render() == expected - expected = ['epl-2.0', 'apache-2.0', 'gpl-2.0', 'classpath-exception-2.0', 'unknown-spdx', 'unknown-spdx'] + expected = ['epl-2.0', 'apache-2.0', 'gpl-2.0', 'classpath-exception-2.0', 'gpl-2.0', 'openjdk-exception'] assert licensing.license_keys(expression, unique=False) == expected assert all(s.wrapped for s in licensing.license_symbols(expression, decompose=True)) diff --git a/tests/licensedcode/test_models.py b/tests/licensedcode/test_models.py index ba6da09d021..80fc96eebe9 100644 --- a/tests/licensedcode/test_models.py +++ b/tests/licensedcode/test_models.py @@ -131,7 +131,7 @@ def test_validate_license_library_can_return_errors(self): 'bsd-ack-carrot2': [ 'No short name', 'No name', - 'No category', + 'No category: Use "Unstated License" if not known.', 'No owner: Use "Unspecified" if not known.', 'No SPDX license key'], 'gpl-1.0': [ @@ -271,7 +271,7 @@ def test_spdxrule_with_invalid_expression(self): ) except Exception as e: ex = str(e) - assert 'Unable to parse License rule expression: ' in ex + assert 'Unable to parse Rule license expression:' in ex assert 'ExpressionError: AND requires two or more licenses as in: MIT AND BSD' in ex def test_template_rule_is_loaded_correctly(self): diff --git a/tests/licensedcode/test_query.py b/tests/licensedcode/test_query.py index 6c073a49260..c75f80c5844 100644 --- a/tests/licensedcode/test_query.py +++ b/tests/licensedcode/test_query.py @@ -705,7 +705,6 @@ def test_QueryRun_with_all_digit_lines(self): {'end': 5, 'start': 0, 'tokens': '1 80 0 256 1568 1953'}, {'end': 12, 'start': 6, 'tokens': '406 1151 1 429 368 634 8'}, {'end': 17, 'start': 13, 'tokens': '1955 724 2 932 234'}, - {'end': 20, 'start': 18, 'tokens': '694 634 110'}, ] assert result == expected diff --git a/tests/packagedcode/data/debian/copyright/debian-2019-11-15/main/p/perl/copyright-detailed.expected.yml b/tests/packagedcode/data/debian/copyright/debian-2019-11-15/main/p/perl/copyright-detailed.expected.yml index dee0a1495be..ededa00aab9 100644 --- a/tests/packagedcode/data/debian/copyright/debian-2019-11-15/main/p/perl/copyright-detailed.expected.yml +++ b/tests/packagedcode/data/debian/copyright/debian-2019-11-15/main/p/perl/copyright-detailed.expected.yml @@ -1316,15 +1316,15 @@ matches: LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - - score: '96.49' + - score: '98.25' start_line: 2398 end_line: 2424 matcher: 1-hash - rule_length: 220 - matched_length: 220 + rule_length: 224 + matched_length: 224 match_coverage: '100.0' rule_relevance: 100 - identifier: bsd-original_48.RULE + identifier: bsd-original_80.RULE license_expression: bsd-original is_license_text: yes is_license_notice: no @@ -1343,15 +1343,15 @@ matches: distribution. 3. All advertising materials mentioning features or use of this software must display the following acknowledgement: - This product includes software developed by [Powerdog] [Industries]. - 4. The name of [Powerdog] [Industries] may not be used to endorse or + This product includes software developed by [Powerdog] Industries. + 4. The name of [Powerdog] Industries may not be used to endorse or promote products derived from this software without specific prior written permission. - THIS SOFTWARE IS PROVIDED BY [POWERDOG] [INDUSTRIES] ``AS IS'' AND ANY + THIS SOFTWARE IS PROVIDED BY [POWERDOG] INDUSTRIES ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR - PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE [POWERDOG] [INDUSTRIES] BE + PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE [POWERDOG] INDUSTRIES BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR diff --git a/tests/packagedcode/data/debian/copyright/debian-2019-11-15/non-free/f/firmware-nonfree/stable_firmware-intel-sound.copyright-detailed.expected.yml b/tests/packagedcode/data/debian/copyright/debian-2019-11-15/non-free/f/firmware-nonfree/stable_firmware-intel-sound.copyright-detailed.expected.yml index 14a9b48f5e9..45325a6864f 100644 --- a/tests/packagedcode/data/debian/copyright/debian-2019-11-15/non-free/f/firmware-nonfree/stable_firmware-intel-sound.copyright-detailed.expected.yml +++ b/tests/packagedcode/data/debian/copyright/debian-2019-11-15/non-free/f/firmware-nonfree/stable_firmware-intel-sound.copyright-detailed.expected.yml @@ -3,13 +3,14 @@ declared_license: - Binary redistribution (Intel 1) - Binary redistribution (Intel 2) - Binary redistribution (Intel 3) -license_expression: intel AND intel AND (intel AND free-unknown AND bsd-new AND bsd-new AND - x11-lucent AND standard-ml-nj AND amd-historical AND sunpro AND osf-1990 AND nilsson-historical - AND newlib-historical AND bsd-new AND amd-historical AND bsd-new AND bsd-simplified AND bsd-simplified - AND bsd-simplified AND x11-hanson AND bsd-simplified AND bsd-new AND delorie-historical AND - intel-osl-1993 AND osf-1990 AND bsd-simplified AND bsd-simplified AND bsd-simplified AND bsd-new - AND bsd-simplified AND bsd-simplified AND bsd-simplified AND bsd-simplified AND bsd-simplified - AND bsd-new AND bsd-new AND bsd-new AND newlib-historical AND bsd-new AND bsd-new AND bsd-simplified) +license_expression: intel AND intel AND (intel AND (bsd-new AND other-permissive AND other-copyleft) + AND bsd-new AND bsd-new AND x11-lucent AND standard-ml-nj AND amd-historical AND sunpro AND + osf-1990 AND nilsson-historical AND newlib-historical AND bsd-new AND amd-historical AND bsd-new + AND bsd-simplified AND bsd-simplified AND bsd-simplified AND x11-hanson AND bsd-simplified + AND bsd-new AND delorie-historical AND intel-osl-1993 AND osf-1990 AND bsd-simplified AND + bsd-simplified AND bsd-simplified AND bsd-new AND bsd-simplified AND bsd-simplified AND bsd-simplified + AND bsd-simplified AND bsd-simplified AND bsd-new AND bsd-new AND bsd-new AND newlib-historical + AND bsd-new AND bsd-new AND bsd-simplified) copyright: | 2014, Intel Corporation. 2014, Intel Corporation @@ -177,21 +178,23 @@ matches: ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - score: '100.0' - start_line: 141 + start_line: 139 end_line: 143 matcher: 2-aho - rule_length: 38 - matched_length: 38 + rule_length: 48 + matched_length: 48 match_coverage: '100.0' rule_relevance: 100 - identifier: free-unknown_47.RULE - license_expression: free-unknown + identifier: license-intro_55.RULE + license_expression: bsd-new AND other-permissive AND other-copyleft is_license_text: no is_license_notice: no is_license_reference: no is_license_tag: no is_license_intro: yes matched_text: | + The newlib subdirectory is a collection of software from several sources. + Each file may have its own copyright/license that is embedded in the source file. Unless otherwise noted in the body of the source file(s), the following copyright notices will apply to the contents of the newlib subdirectory: diff --git a/tests/packagedcode/data/debian/copyright/debian-slim-2021-04-07/usr/share/doc/perl-base/copyright-detailed.expected.yml b/tests/packagedcode/data/debian/copyright/debian-slim-2021-04-07/usr/share/doc/perl-base/copyright-detailed.expected.yml index 355804ffa7b..06aa2b3203d 100644 --- a/tests/packagedcode/data/debian/copyright/debian-slim-2021-04-07/usr/share/doc/perl-base/copyright-detailed.expected.yml +++ b/tests/packagedcode/data/debian/copyright/debian-slim-2021-04-07/usr/share/doc/perl-base/copyright-detailed.expected.yml @@ -1278,15 +1278,15 @@ matches: LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - - score: '96.49' + - score: '98.25' start_line: 2323 end_line: 2349 matcher: 1-hash - rule_length: 220 - matched_length: 220 + rule_length: 224 + matched_length: 224 match_coverage: '100.0' rule_relevance: 100 - identifier: bsd-original_48.RULE + identifier: bsd-original_80.RULE license_expression: bsd-original is_license_text: yes is_license_notice: no @@ -1305,15 +1305,15 @@ matches: distribution. 3. All advertising materials mentioning features or use of this software must display the following acknowledgement: - This product includes software developed by [Powerdog] [Industries]. - 4. The name of [Powerdog] [Industries] may not be used to endorse or + This product includes software developed by [Powerdog] Industries. + 4. The name of [Powerdog] Industries may not be used to endorse or promote products derived from this software without specific prior written permission. - THIS SOFTWARE IS PROVIDED BY [POWERDOG] [INDUSTRIES] ``AS IS'' AND ANY + THIS SOFTWARE IS PROVIDED BY [POWERDOG] INDUSTRIES ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR - PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE [POWERDOG] [INDUSTRIES] BE + PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE [POWERDOG] INDUSTRIES BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR diff --git a/tests/packagedcode/test_conda.py b/tests/packagedcode/test_conda.py index cab1efb0f8f..bff7041904e 100644 --- a/tests/packagedcode/test_conda.py +++ b/tests/packagedcode/test_conda.py @@ -35,7 +35,7 @@ def test_parse(self): test_file = self.get_test_loc('conda/meta.yaml') package = conda.Condayml.recognize(test_file) expected_loc = self.get_test_loc('conda/meta.yaml.expected.json') - self.check_packages(package, expected_loc, regen=True) + self.check_packages(package, expected_loc, regen=False) def test_root_dir(self): test_file = self.get_test_loc('conda/requests-kerberos-0.8.0-py35_0.tar.bz2-extract/info/recipe.tar-extract/recipe/meta.yaml') diff --git a/tests/packagedcode/test_pypi.py b/tests/packagedcode/test_pypi.py index 8fccfd3216b..3db0fcf1637 100644 --- a/tests/packagedcode/test_pypi.py +++ b/tests/packagedcode/test_pypi.py @@ -477,7 +477,7 @@ def test_parse_setup_py_arpy(self): test_file = self.get_test_loc('pypi/setup.py/arpy_setup.py') package = pypi.SetupPy.recognize(test_file) expected_loc = self.get_test_loc('pypi/setup.py/arpy_setup.py-expected.json') - self.check_packages(package, expected_loc, regen=True) + self.check_packages(package, expected_loc, regen=False) @expectedFailure def test_parse_setup_py_pluggy(self):