Skip to content

Commit a9f6aa4

Browse files
authored
license-update: update website with new license info (#1762)
RFC: https://wiki.php.net/rfc/php_license_update
1 parent 5da9ceb commit a9f6aa4

File tree

6 files changed

+225
-69
lines changed

6 files changed

+225
-69
lines changed

license/3_01.txt

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,21 @@
1+
============= An example PHP License, version 3.01 file ============
2+
3+
This is the original PHP License, version 3.01, which applies only to
4+
old versions of PHP software (such as versions 8.5 and earlier).
5+
6+
The PHP License, version 3.01, is an Open Source Initiative approved
7+
license, available at <https://opensource.org/license/php-3-01>. This
8+
license is provided for historical purposes only.
9+
10+
This license has been superseded by the PHP License, version 4,
11+
available at <https://www.php.net/license/>. The PHP License, version 4
12+
is the Modified BSD License (BSD-3-Clause). All new works using the PHP
13+
License should use the Modified BSD License.
14+
15+
116
--------------------------------------------------------------------
217
The PHP License, version 3.01
3-
Copyright (c) 1999 - 2019 The PHP Group. All rights reserved.
18+
Copyright (c) 1999 - 2026 The PHP Group. All rights reserved.
419
--------------------------------------------------------------------
520

621
Redistribution and use in source and binary forms, with or without

license/4_0.txt

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
Copyright © The PHP Group and Contributors.
2+
Copyright © Zend Technologies Ltd., a subsidiary company of Perforce Software, Inc.
3+
4+
Redistribution and use in source and binary forms, with or without
5+
modification, are permitted provided that the following conditions are met:
6+
7+
1. Redistributions of source code must retain the above copyright notice, this
8+
list of conditions and the following disclaimer.
9+
10+
2. Redistributions in binary form must reproduce the above copyright notice,
11+
this list of conditions and the following disclaimer in the documentation
12+
and/or other materials provided with the distribution.
13+
14+
3. Neither the name of the copyright holder nor the names of its
15+
contributors may be used to endorse or promote products derived from
16+
this software without specific prior written permission.
17+
18+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
19+
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20+
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
21+
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
22+
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
23+
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
24+
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
25+
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
26+
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
27+
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

license/contrib-guidelines-code.php

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,31 @@
11
<?php
22
$_SERVER['BASE_PAGE'] = 'license/contrib-guidelines-code.php';
33
include_once __DIR__ . '/../include/prepend.inc';
4-
site_header("License Information", ["current" => "help"]);
4+
site_header("Contributor Guidelines", ["current" => "help"]);
55
?>
66
<h2>PHP Contributor Guidelines for Code Developers</h2>
77

88
<p>
9-
Before you complete the form to request a Git account, you must understand and accept the principles under which PHP
9+
Before you contribute code to PHP, you must understand and accept the principles under which PHP
1010
itself is developed. These are summarised in the next paragraph.
1111
</p>
1212
<p>
13-
Any code contributed to PHP must be contributed under the PHP license (or a compatible BSD-style license).
14-
PHP will be redistributed under the PHP license (currently
15-
<a href="http://www.php.net/license/3_01.txt">version 3.01</a>).
13+
Any code contributed to PHP must be contributed under the Modified BSD License or other, compatible permissive license.
14+
PHP is distributed under the <a href="/license/#bsd-3-clause">Modified BSD License</a>.
1615
This includes implementation code, test cases, utility scripts and tools - that is, all code associated
1716
with the PHP project. If you contribute code that isn't entirely your own
1817
(for example it may be partially derived from other Open Source software) you are asked to add a comment
1918
into the source code to indicate the origin and the license of the original code.
20-
If you are unsure of the license you are asked to confirm with the owner of the code that they are
21-
happy for it to be contributed to PHP under the PHP license.
19+
If you are unsure of the license, you are asked to confirm with the owner of the code that they
20+
grant permission for it to be contributed to PHP under the
21+
terms of the Modified BSD License or other compatible license.
2222
</p>
2323
<p>
24-
Specifically regarding GPL and LGPL source code:
24+
Specifically regarding source code licensed under the GNU General Public License (GPL):
2525
</p>
2626
<ul>
27-
<li>GPL or LGPL licensed code cannot be used as a basis for any derived work contributed to PHP.</li>
28-
<li>Extensions which link GPL'd libraries will not be accepted.</li>
29-
<li>Extensions which link to LGPL libraries will be strongly discouraged.</li>
27+
<li>GPL-licensed code cannot be used as a basis for any work contributed to PHP.</li>
28+
<li>Extensions linking to GPL-licensed libraries will not be accepted.</li>
3029
</ul>
3130

3231

Lines changed: 9 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,13 @@
11
<?php
22
$_SERVER['BASE_PAGE'] = 'license/distrib-guidelines-code.php';
33
include_once __DIR__ . '/../include/prepend.inc';
4-
site_header("License Information", ["current" => "help"]);
4+
site_header("Distribution Guidelines", ["current" => "help"]);
55
?>
66
<h2>PHP Distribution Guidelines</h2>
77

88
<p>
9-
The PHP code can be redistributed in source or binary form provided that
10-
the terms of the PHP license are respected (see
11-
<a href="http://www.php.net/license/3_01.txt">version 3.01</a>).
9+
You may redistribute PHP in source or binary form, provided
10+
you respect the terms of the <a href="/license/">license</a>.
1211
</p>
1312
<p>
1413
In plain English, this means that you have to include the full license text
@@ -18,25 +17,27 @@
1817
distribution. This ensures that the license information can be read
1918
properly even when a binary is shipped.
2019
A text file containing license and copyright information is sometimes
21-
given the filename "Notices", and may be referred to as a "Notices file".
20+
given the filename "Notice" or "NOTICE" and may be referred to as a "notice file".
2221
</p>
2322
<p>
2423
Some files in the PHP codebase have been contributed under other licenses.
2524
If you want to distribute these files, you also need to respect the terms
2625
of those licenses.
2726
To check, look for the terms indicated in the license + copyright comment
2827
block at the top of the source file.
28+
Keep in mind, sometimes the license terms are included in a separate license file in the
29+
same directory as the source file.
2930
</p>
3031
<p>
3132
The license terms for such a file may require that its own license and copyright
3233
information must be included with every distributed copy (including binaries).
3334
This is quite a common requirement, which can be satisfied by adding the
3435
appropriate license text into a text file for distribution purposes, like the
35-
"Notices"-type of file suggested above.
36+
notice file suggested above.
3637
</p>
3738
<p>
38-
A single "Notices" file could be used to hold the collection of license
39-
and copyright information that applies to PHP in general (the PHP license) and
39+
A single notice file could be used to hold the collection of license
40+
and copyright information that applies to PHP in general and
4041
any files with additional licenses that you want to distribute (for example
4142
Zend, TSRM etc.)
4243
It is good practice to indicate which source file(s) a particular license
@@ -54,12 +55,6 @@
5455
the PHP codebase are distributed in human-readable form with
5556
every copy, as described above.
5657
</li>
57-
<li>
58-
you don't use the name "PHP" without permission, either
59-
to promote your own product or within your product's name
60-
(see clauses #3 and #4 in the PHP license
61-
<a href="http://www.php.net/license/3_01.txt">version 3.01</a>).
62-
</li>
6358
</ul>
6459

6560
<?php site_footer();

license/index.php

Lines changed: 162 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -25,34 +25,107 @@
2525
<a id="code-lic"></a>
2626
<h2>PHP Codebase</h2>
2727

28-
<ul>
28+
<p>
29+
PHP is available for use under the terms of the
30+
<a href="#bsd-3-clause">Modified BSD License</a>, also known as the PHP
31+
License, version 4.
32+
</p>
33+
34+
<p>
35+
The Modified BSD License is an <a href="https://opensource.org/osd">Open
36+
Source license</a>,
37+
<a href="https://opensource.org/license/bsd-3-clause">approved by the Open
38+
Source Initiative</a>, and
39+
<a href="https://directory.fsf.org/wiki/License:BSD-3-Clause">compatible with
40+
the GNU General Public License (GPL)</a>. It is a
41+
<a href="https://en.wikipedia.org/wiki/Permissive_software_license">permissive</a>
42+
software license that does not have the
43+
<a href="https://en.wikipedia.org/wiki/Copyleft">copyleft</a> restrictions
44+
associated with licenses like the GNU GPL. Its SPDX identifier is
45+
<a href="https://spdx.org/licenses/BSD-3-Clause.html"><code>BSD-3-Clause</code></a>.
46+
</p>
47+
48+
<p>
49+
Some files in PHP software have been contributed under other compatible
50+
licenses and may carry additional requirements and copyright information.
51+
This is indicated in the license/copyright comment block at the top of each
52+
source file. Sometimes the license terms are included in a separate license
53+
file in the same directory as the source file.
54+
</p>
55+
56+
<a id="bsd-3-clause"></a>
57+
<h3>License</h3>
58+
59+
<p>
60+
Copyright &copy; The PHP Group and Contributors.<br>
61+
Copyright &copy; Zend Technologies Ltd., a subsidiary company of Perforce
62+
Software, Inc.
63+
</p>
64+
65+
<p>
66+
Redistribution and use in source and binary forms, with or without
67+
modification, are permitted provided that the following conditions are met:
68+
</p>
69+
70+
<ol>
2971
<li>
30-
Starting with PHP 4, versions of the PHP software are distributed under the
31-
<a href="http://www.php.net/license/3_01.txt">PHP License v3.01</a>, copyright (c) the <a href="/credits.php">PHP Group</a>.
32-
<ul>
33-
<li>
34-
This is an <a href="http://www.opensource.org/docs/osd">Open Source license</a>,
35-
certified by the Open Source Initiative.
36-
</li>
37-
<li>
38-
The PHP license is a BSD-style license which does not have the "copyleft"
39-
restrictions associated with GPL.
40-
</li>
41-
</ul>
72+
Redistributions of source code must retain the above copyright notice,
73+
this list of conditions and the following disclaimer.
4274
</li>
4375
<li>
44-
Some files have been contributed under other (compatible) licenses and carry
45-
additional requirements and copyright information.<br>
46-
This is indicated in the license + copyright comment block at the top of the source file.
76+
Redistributions in binary form must reproduce the above copyright notice,
77+
this list of conditions and the following disclaimer in the documentation
78+
and/or other materials provided with the distribution.
4779
</li>
4880
<li>
49-
Practical Guidelines:
81+
Neither the name of the copyright holder nor the names of its
82+
contributors may be used to endorse or promote products derived from
83+
this software without specific prior written permission.
84+
</li>
85+
</ol>
86+
87+
<p>
88+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
89+
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
90+
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
91+
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
92+
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
93+
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
94+
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
95+
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
96+
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
97+
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
98+
POSSIBILITY OF SUCH DAMAGE.
99+
</p>
100+
101+
<h3>Practical Guidelines</h3>
102+
50103
<ul>
51104
<li><a href="/license/distrib-guidelines-code.php">Distributing PHP</a></li>
52105
<li><a href="/license/contrib-guidelines-code.php">Contributing to PHP</a></li>
53106
</ul>
54-
</li>
55-
</ul>
107+
108+
<h3>Earlier Versions</h3>
109+
110+
<p>
111+
Earlier versions of PHP software were distributed under the terms of
112+
versions <a href="/license/2_01.txt">2.01</a>,
113+
<a href="/license/2_02.txt">2.02</a>, <a href="/license/3_0.txt">3.0</a>, and
114+
<a href="/license/3_01.txt">3.01</a> of the PHP License. At your option, you
115+
may choose to use any earlier version of PHP software under the terms of the
116+
<a href="/license/4_0.txt">PHP License, version 4</a>. This is in accordance
117+
with section 5 of the PHP License, versions 3.0 and 3.01, and section 4 of
118+
the PHP License, versions 2.01 and 2.02 (emphasis added):
119+
</p>
120+
121+
<blockquote>
122+
<p>
123+
Once covered code has been published under a particular version of the
124+
license, you may always continue to use it under the terms of that version.
125+
<b>You may also choose to use such covered code under the terms of any
126+
subsequent version</b> of the license published by the PHP Group.
127+
</p>
128+
</blockquote>
56129

57130
<a id="doc-lic"></a>
58131
<h2>PHP Documentation</h2>
@@ -97,35 +170,82 @@
97170
<p>
98171
<strong>A.</strong>
99172
We cannot really stop you from using PHP in the name of
100-
your project unless you include any code from the PHP distribution, in
101-
which case you would be violating the license.
102-
See Clause 4 in the <a href="http://www.php.net/license/3_01.txt">
103-
PHP License v3.01</a>.
104-
<br>But we would really prefer if people would come up with their own names
173+
your project,
174+
but we would prefer you come up with your own name
105175
independent of the PHP name.
106176
</p>
107177

108178
<p>
109-
"Why?" you ask. You are only trying to contribute to the PHP
110-
community. That may be true, but by using the PHP name you are
111-
explicitly linking your efforts to those of the entire PHP development
179+
"PHP" is the PHP project's unique brand. When others see the name "PHP," they
180+
associate it with this project. When you use "PHP" as part of your software's
181+
name, you are linking your efforts to those of the entire PHP development
112182
community and the years of work that has gone into the PHP project.
113-
Every time a flaw is found in one of the thousands of applications out
114-
there that call themselves "PHP-Something" the negative karma that
115-
generates reflects unfairly on the entire PHP project. We had nothing
116-
to do with PHP-Nuke, for example, and every bugtraq posting on that
117-
says "PHP" in it. Your particular project may in fact be the greatest
118-
thing ever, but we have to be consistent in how we handle these
119-
requests and we honestly have no way of knowing whether your project
120-
is actually the greatest thing ever.
121183
</p>
122184

123185
<p>
124-
So, please, pick a name that stands on its own merits. If your
125-
stuff is good, it will not take long to establish a reputation for
126-
yourselves. Look at Zope, for example, that is a framework for Python
127-
that doesn't have Python in the name. Smarty as well doesn't have PHP
128-
in the name and does quite well.
186+
Additionally, using "PHP" in your project's name causes a lot of confusion,
187+
making it more difficult for people to find your project or get help with it.
188+
Inevitably, people looking for your project will open issues on the PHP
189+
project's issue tracker, taking up the valuable time of our volunteers.
190+
</p>
191+
192+
<p>
193+
So, please, pick a name that stands on its own merits. If others find your
194+
project useful, it will not take long to establish a reputation for
195+
yourself.
196+
</p>
197+
198+
<h3>Change in licensing from PHP 8.6 and later</h3>
199+
200+
<p>
201+
<strong>Q.</strong> What are the differences between the PHP License, version
202+
3.01, and the PHP License, version 4?
203+
</p>
204+
205+
<p>
206+
<strong>A.</strong> The PHP License, version 4 removes clauses 4, 5, and 6 of
207+
the PHP License, version 3.01. This makes it effectively identical to the
208+
Modified BSD License (<code>BSD-3-Clause</code>).
209+
</p>
210+
211+
<p>
212+
While the Open Source Initiative (OSI) approved versions 3.0 and 3.01 of the
213+
PHP License through their legacy approval process, the licenses were not
214+
compatible with the GPL. Additionally, clauses 4 and 6 were challenging or
215+
impossible to enforce, and various readings and interpretations sometimes
216+
caused confusion among distributors. As a result, the PHP Group decided to
217+
invoke clause 5 of the PHP License to publish a new version. The new version
218+
resolves all problems with the PHP License (perceived or actual) while
219+
preserving the rights granted by contributors and the rights granted to users.
220+
</p>
221+
222+
<p>
223+
<strong>Q.</strong> Is the source code in the <code>Zend/</code> directory
224+
still licensed under the separate Zend Engine License?
225+
</p>
226+
227+
<p>
228+
<strong>A.</strong> No. At the same time the PHP Group published a new version
229+
of the PHP License, Zend Technologies Ltd., a subsidiary of Perforce Software,
230+
Inc., invoked clause 4 of the Zend Engine License, version 2.00, to publish a
231+
new version of the Zend Engine License. The Zend Engine License, version 3.0,
232+
removes clauses 4, 5, and 6 of the Zend Engine License, making it effectively
233+
identical to the Modified BSD License (<code>BSD-3-Clause</code>).
234+
</p>
235+
236+
<p>
237+
<strong>Q.</strong> Can I still use the PHP License or Zend Engine License for
238+
my own projects?
239+
</p>
240+
241+
<p>
242+
<strong>A.</strong> You can, but you shouldn't. The PHP License and Zend
243+
Engine License are deprecated and considered legacy licenses. They are not
244+
recommended for use in new projects. Instead, consider using a similar
245+
license, like the Apache License, Modified BSD License, GNU Lesser General
246+
Public License (LGPL), or MIT License. <em>This is not legal advice; please
247+
consult with a lawyer before adopting or making any changes to your
248+
license.</em>
129249
</p>
130250

131251
<h3>Change in licensing from PHP 4 onwards</h3>
@@ -137,8 +257,8 @@
137257
<p>
138258
<strong>A.</strong> GPL enforces many restrictions on what can and cannot
139259
be done with the licensed code. The PHP developers decided to
140-
release PHP under a much more loose license (Apache-style), to help
141-
PHP become as popular as possible.
260+
release PHP under a much more permissive license (BSD-style) to allow
261+
broader uses of PHP by more people.
142262
</p>
143263

144264
<a id="other-lic"></a>

0 commit comments

Comments
 (0)