I would like to allow users of my code to make derivatives, but disallow derivatives from imposing any restrictions on the usage of my code. Is there an existing license that would fit this specification?
Are there any software licenses that allow for everything but changing the license or dual-licensing?
Firstly, you need a copyleft license, so that you can ensure derivatives would be subject to the same license conditions.
Secondly, the license must prevent imposition of additional restrictions that are not found in the license.
Both of these are fulfilled by the GPLv2. Section 6 states:
You may not impose any further restrictions on the recipients' exercise of the rights granted herein.
And also Section 10 of the GPLv3:
You may not impose any further restrictions on the exercise of the rights granted or affirmed under this License.
The same conditions can be found in LGPLv2.1 and LGPLv3.
Or cc-sa and any variants– TrishJan 5 at 11:23
2@Trish though those are not generally recommended for code.– MadHatter ♦Jan 5 at 12:05
1The GPL forces derivatives to be open source. While it almost fits the specifications, it does too much. Jan 5 at 16:51
2This. I found over the years that its best to stick to the following license progression, from least to most permissive: GPL < GPL w/ linking exceptions < CC0. Few other "Open Source" licenses provide any benefits over all of these 3 worth the effort of learning their limitations. What the OQ asked for is a job for GPL.– T.E.D.Jan 5 at 21:03
4@linklinklink If you consider taking away the source code as a kind of restriction, then it's actually a good fit, because without the source code you can't do a lot of things, no matter what the license says! Jan 5 at 21:09
I voted up Ruben's answer, but also noticed a possible confusion in the question:
allow users of my code to make derivatives, but disallow derivatives from imposing any restrictions on the usage of my code
If you meant "disallow the copyright holder of the derivates from imposing any restrictions on the usage of their derivatives", Ruben is correct; use the GPL. This is exactly what it was designed for.
If you meant "disallow the copyright holder of the derivatives from imposing any restriction on my use of my own code", that just can't happen. If you own the copyright, licenses don't limit you. You can do whatever you want with your own code. That includes continuing to license it however you want. Your users will remain quite free to continue to use your code in accordance with the license(s) you gave them, no matter what someone else does with a "derivative" copy they made.
Where the GPL comes in is if you don't want someone with resources swooping in, improving your code (or perhaps building a great product using it), and then requiring different license terms you had no input into in order to use their new improved "derivative" code.
I think the Ms-PL license follows the exact specifications listed.
Under section 3 (D): (D) If you distribute any portion of the software in source code form, you may do so only under this license by including a complete copy of this license with your distribution. If you distribute any portion of the software in compiled or object code form, you may only do so under a license that complies with this license.
Note that this still would allow someone to compile the code "in object form" and then include that in a different project with a different license, as long as that other license "complies" with the Ms-PL license, and as long as the other license allows including object-only code in the project. Personally I think that makes it compatible with Apache, for example, but one would have to specifically compile your Ms-PL part before including it in her Apache project. See opensource.stackexchange.com/questions/13087/…– BrandinJan 5 at 9:28
CC BY-SA or its non-commercial cousin, CC BY-NC-SA, do not allow changing out of the license for derivates as altering the license is violating the SA Part, unless it is essentially reworded. There is no compatible license for the 3.0 version.
For your application, the CC BY-SA 4.0 compatible GNU GPL v3 might be the better choice: it shares the force to stay in the license scheme and is worded even stronger in this regard, disallowing to put any different license on it. It is also very common in software projects.
3It's not recommended to apply any CC license to software: creativecommons.org/faq/…– kapexJan 5 at 15:50
@kapex yeah, because of the source code thing, but the asker didn't say they wanted to share source code, which does make me wonder why this is on Open Source Stack Exchange Jan 5 at 16:32
@user253751 it was transferred from LAW.SE to here, imho erroneously. I n the migration, a paragraph I wrote about GPLv3 being similar and possibly better was lost...– TrishJan 5 at 20:49
Apache License 2.0 is one that should achieve what you need. https://opensource.org/licenses/Apache-2.0
2I notice the following clause defies my requirements: 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– linklinklinkJan 5 at 2:45
1@linklinklink I think you're mistaken on what sublicensing means. It does not mean to use a different license. It means to give somebody else the rights that were given to you. Jan 5 at 6:23
@usee71659 you are correct. I did find that the Ms-PL license meets my specifications more than the Apache 2.0 license however.– linklinklinkJan 5 at 6:32
5I think this is not right since Apache License 2.0 states "You ... 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." Jan 5 at 10:15
Ato someone and license
Aforces that person to use license
B != Ato distribute any changes? Where license
Bforces anyone else who obtained the product with that license to keep using license