Revert "Imported Upstream version 7.53.1"
[platform/upstream/curl.git] / docs / LICENSE-MIXING.md
1 License Mixing
2 ==============
3
4 libcurl can be built to use a fair amount of various third party libraries,
5 libraries that are written and provided by other parties that are distributed
6 using their own licenses. Even libcurl itself contains code that may cause
7 problems to some. This document attempts to describe what licenses libcurl and
8 the other libraries use and what possible dilemmas linking and mixing them all
9 can lead to for end users.
10
11 I am not a lawyer and this is not legal advice!
12
13 One common dilemma is that [GPL](https://www.gnu.org/licenses/gpl.html)
14 licensed code is not allowed to be linked with code licensed under the
15 [Original BSD license](https://spdx.org/licenses/BSD-4-Clause.html) (with the
16 announcement clause). You may still build your own copies that use them all,
17 but distributing them as binaries would be to violate the GPL license - unless
18 you accompany your license with an
19 [exception](https://www.gnu.org/licenses/gpl-faq.html#GPLIncompatibleLibs). This
20 particular problem was addressed when the [Modified BSD
21 license](https://opensource.org/licenses/BSD-3-Clause) was created, which does
22 not have the announcement clause that collides with GPL.
23
24 ## libcurl
25
26  Uses an [MIT style license](https://curl.haxx.se/docs/copyright.html) that is
27  very liberal.
28
29 ## OpenSSL
30
31  (May be used for SSL/TLS support) Uses an Original BSD-style license with an
32  announcement clause that makes it "incompatible" with GPL. You are not
33  allowed to ship binaries that link with OpenSSL that includes GPL code
34  (unless that specific GPL code includes an exception for OpenSSL - a habit
35  that is growing more and more common). If OpenSSL's licensing is a problem
36  for you, consider using another TLS library.
37
38 ## GnuTLS
39
40  (May be used for SSL/TLS support) Uses the
41  [LGPL](https://www.gnu.org/licenses/lgpl.html) license. If this is a problem
42  for you, consider using another TLS library. Also note that GnuTLS itself
43  depends on and uses other libs (libgcrypt and libgpg-error) and they too are
44  LGPL- or GPL-licensed.
45
46 ## WolfSSL
47
48  (May be used for SSL/TLS support) Uses the GPL license or a propietary
49  license. If this is a problem for you, consider using another TLS library.
50
51 ## NSS
52
53  (May be used for SSL/TLS support) Is covered by the
54  [MPL](https://www.mozilla.org/MPL/) license, the GPL license and the LGPL
55  license. You may choose to license the code under MPL terms, GPL terms, or
56  LGPL terms. These licenses grant you different permissions and impose
57  different obligations. You should select the license that best meets your
58  needs.
59
60 ## axTLS
61
62  (May be used for SSL/TLS support) Uses a Modified BSD-style license.
63
64 ## mbedTLS
65
66  (May be used for SSL/TLS support) Uses the GPL license or a propietary
67  license. If this is a problem for you, consider using another TLS library.
68
69 ## BoringSSL
70
71  (May be used for SSL/TLS support) As an OpenSSL fork, it has the same
72  license as that.
73
74 ## libressl
75
76  (May be used for SSL/TLS support) As an OpenSSL fork, it has the same
77  license as that.
78
79 ## c-ares
80
81  (Used for asynchronous name resolves) Uses an MIT license that is very
82  liberal and imposes no restrictions on any other library or part you may link
83  with.
84
85 ## zlib
86
87  (Used for compressed Transfer-Encoding support) Uses an MIT-style license
88  that shouldn't collide with any other library.
89
90 ## MIT Kerberos
91
92  (May be used for GSS support) MIT licensed, that shouldn't collide with any
93  other parts.
94
95 ## Heimdal
96
97  (May be used for GSS support) Heimdal is Original BSD licensed with the
98  announcement clause.
99
100 ## GNU GSS
101
102  (May be used for GSS support) GNU GSS is GPL licensed. Note that you may not
103  distribute binary curl packages that uses this if you build curl to also link
104  and use any Original BSD licensed libraries!
105
106 ## libidn
107
108  (Used for IDNA support) Uses the GNU Lesser General Public License [3]. LGPL
109  is a variation of GPL with slightly less aggressive "copyleft". This license
110  requires more requirements to be met when distributing binaries, see the
111  license for details. Also note that if you distribute a binary that includes
112  this library, you must also include the full LGPL license text. Please
113  properly point out what parts of the distributed package that the license
114  addresses.
115
116 ## OpenLDAP
117
118  (Used for LDAP support) Uses a Modified BSD-style license. Since libcurl uses
119  OpenLDAP as a shared library only, I have not heard of anyone that ships
120  OpenLDAP linked with libcurl in an app.
121
122 ## libssh2
123
124  (Used for scp and sftp support) libssh2 uses a Modified BSD-style license.