# Open Source Software (OSS)
Open source software (OSS), not to be confused with **free** software, is software that has been released under a license that grants people the ability to do a number of things such as change, distribute, study, update, break, or any other thing they want to do with it for any purpose. This differs greatly from closed-source or proprietary software where its users are prohibited from doing many, if not all, of those things.
Understanding what makes OSS important requires a basic understanding of concepts such as copyrights, licensing, and how they work together to form the basis for OSS.
# Copyrights
Put simply, a copyright is an exclusive right granted to the creator that creates a given work. A creator can be almost anything, including: a person, an entity, or a group. The works covered can include things such as books, articles, music, photos, drawings, and in our case code. The copyright grants the creator the ability to control rights, either granting or prohibiting them, such as:
* reproductions
* distribution
* public performances
* broadcasting or other forms of communication
* translation into other languages
* adaptions on the work
Generally speaking, most countries today grant copyright upon creation without the need to register the copyright with any governmental bodies. We won't get into what copyright registration means or what benefits it may have but know that it's a thing when you're asked to put on a suit to go to the office.
A copyright is important as the owner, as stated above, can grant none, some, or all of the rights afforded to them to other people. Some may even license the use of the work to others for their own gain. That's not what we're here for though.
# Licensing
When a creator of a copyrighted work wishes to grant another party the ability to perform any of the rights they have, this is done via licensing. Without a license granted by the creator, even if you can easily reproduce, distribute, or any of the other rights above, you are violating the creator's copyright. This is why licensing is important to understand whether you are working on your own project(s) or helping with another project.
## License Types
There are a wide variety of license types out there that a developer or group of developers can choose from. Generally speaking, they fall into just a few different categories though. We'll break these categories down a bit and then take you through a few of the most popular licenses out there.
### Public Domain
Public domain, or public domain-like licenses, is where the creator of the work waives, gives away, or otherwise relinquishes the copyright granted to them for the work. Anyone can do whatever they want with it, no attribution is required, and you can use the code in whatever project you'd like.
### Permissive Licenses
Permissive licenses generally grant use rights including the ability to reproduce, alter, distribute, and the ability to relicense the work into other licenses as long as certain conditions are met (such as keeping the copyright header in place). Developers love permissive licenses because they are able to pretty much do whatever they want with the code.
### Copyleft Licenses
Copyleft licenses generally grant the same use rights as permissive licenses such as the ability to reproduce, alter, and distribute the work; however, they explicitly forbid the ability to relicense the work. Just as in permissive licensing, any copyright headers generally need to remain intact. Most developers don't mind copyleft licenses; however, due to the fact that relicensing is prohibited, some organizations (notably some businesses) forbid use of copyleft licensed software in their development environments.
### Proprietary Licenses
Proprietary licenses generally reflect a traditional use of copyright rights and no rights are granted or conveyed to anyone that gets their hand on the covered work. You'll find proprietary licenses almost everywhere as organizations work to protect their intellectual property.
## No License?
What if there is no license either stated in a work, on a work, in a code repository or the like? Simple. Treat it as if it has a proprietary license. This is easy enough to arrive at via the following:
1. Creator is granted copyright upon creation of the work
2. Creator has not chosen to license it (by omission of a license stating otherwise)
3. Creator retains all rights granted to them via the copyright
**If it has no license, it is not OSS, you are not permitted to copy, distribute, reproduce, or alter it.**
This is why licensing, no matter what type of license is used, is important to software development. Without some form of OSS license, no one besides the creator is be able to use, distribute, or reproduce it (among other things) without their explicit consent (via a license).
## License Compatability
While OSS licenses generally permit developers to use the licensed work however they want developers have to keep in mind how a mixture of licenses work together. Different rules may apply in how different works can be combined depending on if they are dyanmically or statically linked. There are also different requirements on how copyrights may be disabled in different licenses. Your best bet is to always check the license requirements of any software or dependencies that you are working with.

Taking a look at the chart above, you can see how difference licenses can be used together. Generally speaking, there is no problem moving left to right in the chart; however, moving right to left will generally result in a license compatability issue.
# OSS License Traits
OSS License rights are generally broken down into six distinct classifications.
### Linking
Using the licensed code as a library with code under a different license (ie. node modules, .dll files, or .so files)
### Distribution
The ability to distribute the source code to other parties
### Modification
The ability to modify the source code to your liking
### Patent Grant
Provides protection from patent infringement claims by code contributors regarding their portions and the protection of contributors from claims by you
### Private Use
Defines whether you are able to keep your changes to the code secret and never publish it for the rest of the world to enjoy
### Sublicensing
Whether the modified version of the code you maintain may be licensed under a different license
### Trademark Grant
Defines whether you can use any trademarks associated with the licensed code or the contributors as part of your use of the code
It is important to understand how each of these license traits may permit or prevent you from doing what you'd like to do. Knowing how these applies makes you a stronger developer.
# Apache License 2.0
The [Apache License 2.0](https://opensource.org/licenses/Apache-2.0) has the following traits.
|Trait|Status|
|---|---|
|Linking|Permissive|
|Distribution|Permissive|
|Modification|Permissive|
|Patent Grant|Yes|
|Private Use|Yes|
|Sublicensing|Permissive|
|Trademark Grant|No|
# The BSD-2 Clause License
The [BSD-2 Clause](https://opensource.org/licenses/BSD-2-Clause) has the following traits.
|Trait|Status|
|---|---|
|Linking|Permissive|
|Distribution|Permissive|
|Modification|Permissive|
|Patent Grant|Yes|
|Private Use|Yes|
|Sublicensing|Permissive|
|Trademark Grant|No|
# The BSD-3 Clause License
The [BSD-3 Clause](https://opensource.org/licenses/BSD-3-Clause) has the following traits.
|Trait|Status|
|---|---|
|Linking|Permissive|
|Distribution|Permissive|
|Modification|Permissive|
|Patent Grant|Consent required|
|Private Use|Yes|
|Sublicensing|Permissive|
|Trademark Grant|Consent required|
# GNU Affero General Public License v3 (AGPL-3.0)
The [GNU Affero General Public License v3](https://opensource.org/licenses/AGPL-3.0) has the following traits.
|Trait|Status|
|---|---|
|Linking|GPL-3.0 Only|
|Distribution|Copyleft|
|Modification|Copyleft|
|Patent Grant|Yes|
|Private Use|No network usage without publishing the source|
|Sublicensing|Copyleft|
|Trademark Grant|No|
# GNU General Public License v3 (GPL-3.0)
The [GNU General Public License v3](https://opensource.org/licenses/GPL-2.0) has the following traits.
|Trait|Status|
|---|---|
|Linking|GPL-3.0 Only|
|Distribution|Copyleft|
|Modification|Copyleft|
|Patent Grant|Yes|
|Private Use|Yes|
|Sublicensing|Copyleft|
|Trademark Grant|No|
# The GNU Lesser General Public License v3 (LGPLv3)
The [GNU Lesser General Public License v3](https://opensource.org/licenses/LGPL-3.0) has the following traits.
|Trait|Status|
|---|---|
|Linking|Some Restrictions|
|Distribution|Copyleft|
|Modification|Copyleft|
|Patent Grant|Yes|
|Private Use|Yes|
|Sublicensing|Copyleft|
|Trademark Grant|Yes|
# The MIT License
The [MIT License](https://opensource.org/licenses/MIT) has the following traits.
|Trait|Status|
|---|---|
|Linking|Permissive|
|Distribution|Permissive|
|Modification|Permissive|
|Patent Grant|Consent required|
|Private Use|Yes|
|Sublicensing|Permissive|
|Trademark Grant|Consent required|
# The Mozilla Public License v2.0 (MPL-2.0)
The [The Mozilla Public License v2.0](https://opensource.org/licenses/MPL-2.0) has the following traits.
|Trait|Status|
|---|---|
|Linking|Permissive|
|Distribution|Copyleft|
|Modification|Copyleft|
|Patent Grant|Yes|
|Private Use|Yes|
|Sublicensing|Copyleft|
|Trademark Grant|No|
# Public Domain, WTFPL, and Unlicense
Public Domain, WTFPL, and Unlicense are all different variants of ways to release software into the public domain.
### Public Domain
A public domain release grants all rights to anyone that gets a copy and thus there are no restrictions on its use. Typically this is provided by a simple statement such as:
```
Public Domain
```
or
```
This code is in the public domain
```
Unfortunately, not all countries honor simple statments such as this and thus licenses such as WTFPL and Unlicense were created.
### WTFPL
Similiar to a public domain release, the [WTFPL License](http://www.wtfpl.net/about/) also grants all rights to anyone that gets a copy and thus there are no restrictions on its use.
It's short, and sweet, and gets the point across pretty quickly.
```
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2004 Sam Hocevar <sam@hocevar.net>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. You just DO WHAT THE FUCK YOU WANT TO.
```
### Unlicense
For those of us that want to make it clear that we are forever giving away our rights to the works we create and would prefer something a little more mature and generally recognized the Unlicense was created.
```
This is free and unencumbered software released into the public domain.
Anyone is free to copy, modify, publish, use, compile, sell, or
distribute this software, either in source code form or as a compiled
binary, for any purpose, commercial or non-commercial, and by any
means.
In jurisdictions that recognize copyright laws, the author or authors
of this software dedicate any and all copyright interest in the
software to the public domain. We make this dedication for the benefit
of the public at large and to the detriment of our heirs and
successors. We intend this dedication to be an overt act of
relinquishment in perpetuity of all present and future rights to this
software under copyright law.
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
OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.
For more information, please refer to <http://unlicense.org/>
```