Open-source Licensing 101

By Alireza Alavi13 minutes read


Disclaimer

This isn't legal advice. I'm not a lawyer.

Table of Contents

  1. Types of licenses
    1. Permissive Licenses (Lax)
    2. Intermediate (Weak copyleft)
    3. Copyleft
  2. Compatibility and re-licensing
    1. Permissive licenses (Lax)
    2. Intermediate licenses (Weak copyleft)
    3. Copyleft
    4. Dual licensing
  3. Combining code with different licenses
  4. Choosing a license
    1. Permissive licenses
    2. Intermediate licenses (Weak copyleft)
    3. Copyleft
  5. Other good resources
  6. References

A license on your software determines your legal duties and boundaries on:

You must take care when licensing your product, since it can affect:

This is a legal matter, you can't just read a 10min blog post on it and be all set.
Take your time, read through established guides (like those on fsf.org), and most importantly, read your final candidate licenses (I know it's boring to death but it's a must)

Types of licenses

Permissive Licenses (Lax)

Permissive licenses or as Richard Stallman and Free Software Foundation(FSF) likes to call them: pushover licenses.

we call them “pushover licenses” because they can't say “no” when one user tries to deny freedom to others.

Intermediate (Weak copyleft)

Intermediate licenses are those which have substantive requirements on redistribution but are not copyleft licenses.1

Copyleft

Copyleft is a general method for making a program (or other work) free (in the sense of freedom, not “zero price”), and requiring all modified and extended versions of the program to be free as well.2

Compatibility and re-licensing

Permissive licenses (Lax)

In general, they are all compatible with each other and with other licenses, since they don't prohibit anything and allow everything (There are some exceptions1)

In a combination of programs under lax licenses, each part carries the license it came with. When the code is merged to the point that the parts can't be distinguished any more, that merged code should carry all the licenses of the merged parts. Since all the licenses are lax anyway, this causes no practical problem except that the list of licenses gets long.3

Intermediate licenses (Weak copyleft)

Intermediate licenses tend to be incompatible with any copyleft licenses because their requirements don't permit the combined program to be under the copyleft license.1

Copyleft

In general, two different copyleft licenses are unavoidably incompatible unless they have explicit compatibility provisions. This is not due to a mistake in the details; it's inherent in the idea of copyleft.1

Dual licensing

it means that the same program carries a choice of two or more different licenses.1

Combining code with different licenses

When a set of licenses are compatible, that means you can legally combine or merge a number of programs each licensed under one of those licenses.3

Choosing a license

This post from gnu.org is a really great guide, But here is a summary:

Permissive licenses

MIT License is a very common permissive license today. It's one of the most common licenses for open source projects.

I advise to not use permissive licenses for your projects unless you have good reasons. They take away the freedom from your users and make exploitation of volunteer work very easy, since big corporations and proprietary software can take their work and never contribute back, making users pay the price for things that otherwise could be free (both as in price and as in freedom). That's why all big corporations heavily push permissive licenses.

In summary, choose permissive license:

Among the weak (pushover) licenses, Apache 2.0 is best; so if you are going to use a weak license, whatever the reason, we recommend using that one.6

Intermediate licenses (Weak copyleft)

FSF recommends:7

The most common case is when a free library's features are readily available for proprietary software through other libraries (No unique capability or advantage). In that case, the library cannot give free software any particular advantage, so it is better to use the Lesser GPL(weak copyleft) for that library.

When a library provides significant unique capability, Releasing it under a copyleft license forces either proprietary software to go FOSS or not use it. Which gives advantage to FOSS.

I would also add, when you are developing software for a company to use in proprietary software, and out of goodwill or other reasons you decide to make it FOSS, you can use weak copyleft licenses, so your company can use the software in their proprietary products, but also the software stays FOSS and any change(derivative) to the code has to be released under the same license.
This keeps the software freedom moving forward, while allowing it to be used verbatim in other products.
Of course, you can license your product with copyright for yourself and your company, but that adds complications that I'm not sure about, and also it's kind of against the FOSS spirit I think.

With good weak copyleft licenses, you attract more businesses to use your product and you can create a better financial model of sponsors and such for your product than copyleft software. But if they want to modify it, they must open source their work and contribute back.
I think this is a great balance.

In summary, choose intermediate license:

Copyleft

Proprietary software developers have the advantage of money; free software developers need to make advantages for each other.
Using the ordinary GPL for a library gives free software developers an advantage over proprietary developers: a library that they can use, while proprietary developers cannot use it.7

When a library provides significant unique capability, Releasing it under a copyleft license forces either proprietary software to go FOSS or not use it. Which gives advantage to FOSS.

If we amass a collection of powerful GPL-covered libraries that have no parallel available to proprietary software, they will provide a range of useful modules to serve as building blocks in new free programs. This will be a significant advantage for further free software development, and some projects will decide to make software free in order to use these libraries.7

In summary, choose intermediate license:

Advocating Copyleft

Imagine if Linux, Blender, GIMP, ffmpeg, GNU coreutils (cat, cp, tee etc.), gcc, wordpress, openJDK, GNU R (R lang), VLC, ClamAV, and so on, didn't use copyleft, which meant they would be overtaken by big corporations much more simply and nobody had to contribute their improvements back to the projects. Therefore I would argue we wouldn't have the larger portion of the software that is actually good and valuable, especially free open source software (How many actually good non-FOSS software do we really have?).

We have seen it, and it's been proven that corps like Microsoft, Meta, Google hate user freedom (Who are they basically owned by, again?) and try to take away freedom from users, destroy their general computing rights and rights to their own privacy and hardware.
One of the latest examples is Googles' efforts in recent years to lock down android as much as possible and slowly getting rid of the GPL parts of their code (Android is based on the Linux kernel). Basically making the AOSP useless .
One has to be really blind to the truth not to see how hostile these entities are and how much of a safe barrier FOSS has been for us to prevent their greed from devouring us whole.

So if you have a good idea, please consider choosing a copyleft, or at least weak copyleft license for it, for the sake of humanity and freedom.

Other good resources


Discuss this post on HackerNews

References

  1. https://www.gnu.org/licenses/license-compatibility.html ↩2 ↩3 ↩4 ↩5 ↩6 ↩7 ↩8 ↩9 ↩10 ↩11

  2. https://www.gnu.org/licenses/copyleft.html

  3. https://www.gnu.org/licenses/license-compatibility.html#combining ↩2

  4. https://www.gnu.org/licenses/lgpl-3.0.html

  5. https://www.eclipse.org/legal/epl-2.0/

  6. https://www.gnu.org/licenses/license-recommendations.html ↩2 ↩3

  7. https://www.gnu.org/licenses/why-not-lgpl.html ↩2 ↩3