28

I'm currently working on a software which uses another software under the GPL version 3 license: https://github.com/ViaVersion/ViaVersion/blob/dev/LICENSE

Now someone just came to me and said I have to Open Source my project or I can get in trouble.

I'm not quite sure... But I thought I don't need to do this, because my project is completely private. I will not publish this project whatsoever.

Only me and 2 friends use my software.

Do I really have to Open Source my project?

And if yes, is it enough to just publish the code parts using the software?

6
  • 3
    Do you intend to make your software available to broader public? I tried to figure it out from your comments under the answers, but it's still unclear to me. Specifically, do you want to be able to give some people the software, but refuse the access to the source for them? If you are OK with sharing the code with anyone actually using the app, then GPL shouldn't be a real concern.
    – Frax
    Jun 1 at 14:26
  • If this were entirely private, then you wouldn't have to do anything, but you also have these two friends. The answers are telling you how to comply with the licence in detail, and that's good to know, but the main thing in practice is probably that your two friends are on board. They need to know how to distribute the program, if they should ever choose to do so, so that all of you will be acting legally. (And if there's some other reason that they shouldn't distribute it, the reason that you're having trouble expressing in English, then they should understand that too!) Jun 1 at 15:15
  • @Frax My software should only be available for me and my two friends, so I don't intend to make my software available to broader public. Yes, I want to give two specific people my software, but don't want them to obtain the source code. This has some reasons though
    – Daniel
    Jun 1 at 16:16
  • In order to obtain relevant answers you must specify "working on a software which uses another software". Uses how? My software uses a Linux kernel to run on. Calls a GPLed program. Uses a GPL'ed library that it links to statically. Dynamically. Includes GPLed source code. The link seems to point to a kind of network proxy between a minecraft server and client. IIUC you don't need to GPL anything if you just use that compiled program. Jun 2 at 14:48
  • I'm using it like this: I made a mc client and implemented ViaVersion because of it's protocolhack to be able to join 1.8 to 1.16.5 servers with a 1.16.5 client (Not every server has ViaVersion installed, so I can just ignore this barrier)
    – Daniel
    Jun 2 at 19:39
45

You need to know two things about the GPL:

  • The GPL is a license which requires that when you distribute binaries, you distribute the source code with them (binaries being the things you can directly run)

  • The GPL is viral - any project using something licensed under the GPL must also be licensed under the GPL

The easiest way to comply with the first point is to simply make the software open source by making it available to all online. Many, if not all, large projects licensed under the GPL do this.

The other way of complying is to simply give anyone else who has a copy of the binaries, or who makes use of them, a copy of the source code. In your case, all you need to do is send your friends a copy of the source. As long as no one else uses this project, I think you satisfy the requirements of the license.

You must, however, also license your code under the GPL. This means, as mentioned in the comments, that you must somehow make your friends aware that if they redistribute your code, they must also do so under the terms of the GPL. This can be as simple as including a file called LICENSE in the root directory of the source code, containing a copy of the text of the GPL.

This further means that your friends will be able to share your code with other people without letting you know. You could politely ask them not to, but you can't stop them.

(That said, you have no reason to be worried - only big breaches of license misuse by large companies ever tend to get chased up. However, it's great that you want to be careful about this! Software licensing, especially FOSS licensing, is very important.)

1
  • Comments are not for extended discussion; this conversation has been moved to chat.
    – Dale M
    Jun 3 at 12:06
28

It depends on exactly how you are "using" the GPL code.

If you have copied and modified the source code then you can only distribute copies under the GPL.

If you have invoked a GPL program as a separate process so that your code can use its output then you can distribute your program without the source code, as long as you comply with the terms of the GPL for the GPL program.

If your code is linked either statically or dynamically with a GPL library then the jury is AFAIK still out. The FSF argues that the linked binary is a derivative work and therefore can only be distributed under the GPL. However this has never been actually determined by a court.

1
  • Comments are not for extended discussion; this conversation has been moved to chat.
    – feetwet
    Jun 3 at 20:18
13

What you have been told is incorrect. You are in no way required to release your product under an open source license, nor to publish it in any form. If you do "convey" a work that is under the GPL, or a modified version of a work under the GPL, then you must provide the source code, and include the GPL license text, and for a modified version, place it also under the same license, the GPL (same or later version as the one you received). (for an unmodified copy, the work remains under the same license, and the notices that it is under the GPL must not be changed.) All of that applies only if you "convey" a work, which means to provide it to others in such a form that the others could make further copies.

Section 5 of the GPL, and other parts that refer to a "modified version" apply only to "a work based on the Program". A work that "uses" another work that has been released under the GPL may or may not be "based on" that program. If it is the modified version must be released, if at all, under the same license. But if a new work uses a GPL work only in the sense of making calls to it, and does not itself include any of the source or object code of the original work (which is under the GPL) nor was it created by startling with the GPL source and making changes, even extensive changes, then the new work is not a modified version of the original, and need not be released under the GPL, but may be released under any license that the developer chooses, including a non-free license.

In short, when you convey copies of a work you got under the GPL to others, you must include the source code and retain the license and copyright notice. If you create a modified version and convey it to others, you must license that modified version under the GPL. You do not need to set up a formal open source project, however. If you create a program that will "use" another program under the GPL, but that is not a modified version of the GPL'd program, and does not incorporate that program, you need not place it under the GPL even if you convey it. If you create a modified copy of a GPL'd program for personal use but do not convey it to others, you need not place a GPL license notice on it.

6

For your case specifically, the API for that library is licensed under MIT, not GPL.

MIT is non-viral, so as long as you only call into the API for that library, you do not need to make your code open-source.

2
  • It's not clear to me one way or the other. The LICENSE file is still the text of the GNU General Public license, despite GitHub showing that it's under the MIT License. It's also not clear whether the asker is just using the API or not -- I would think if he's using compiled binaries, that's more than just the API (versus, for instance, a re-implementation of the same API). Jun 1 at 18:04
  • 6
    @JounceCracklePop, the README.md explains which parts of the project are MIT-licensed (the API folders) and which GPL-licensed (the rest). I'm inclined to think that the effect described by this answer is exactly the intent of that separation. However, it is indeed unclear whether that is the interpretation that a court would make. Moreover, if the purpose is to work around GPL-encumbrance of some of the project's dependencies then I think there's a significant risk that the project is in breach of its own GPL obligations. Jun 1 at 23:38
1

Not if you host it on a web server.

If you host a program containing open source code on a web server, you don't need to abide by the terms of the open source licenses and distribute the source code to the people who access your server, because you're technically not considered as distributing the code. This is also known as the "SaaS (Software as a Service) Loophole".

This is the loophole that the Server-Side Public License sought to close, before it was rejected by the Open Source Initiative because they were clearly corrupted by moneyed interests and big business (their press release on the subject talked about the new license "taking away rights", but the only rights taken away were the rights to exploit this loophole).

However, if you aren't using software licensed under the SSPL, then you can not only exploit this loophole to give copies of your program to your friends, you can exploit it to sell access to your SaaS service commercially, too!

1
  • The "web server loophole" is also closed by AGPL (Affero General Public License), which is approved by OSI.
    – user31389
    Jun 2 at 14:20
1

You are using open source software in your project. You are allowed to do that because of the open source license. Most likely (for example for GPL licensed software) you are allowed to do the following:

  1. Create and use software that is derived from the open source software, without any obligation to you.

  2. Distribute your modified software IF you distribute it under an open source license.

So as long as this is private, you have no obligations. If you are a company, as long as the software stays within your company, you have no obligations. As a company, you'd have to be careful not to give it to anyone outside the company, and to tell your employees not to give it to anyone outside the company. If an employee distributes the software, against specific orders, it's the employee who is on the hook and not you.

If you distribute your software, you have the choice: Distribute it under an open source license, as you should, or risk being sued for copyright infringement by the copyright holder. That is your choice. Of course if you get sued and lose the case (as you most likely will) and go on distributing, you will go straight back to court, and the judge may say "apparently a million fine wasn't enough, so now it's five millions". BUT only the copyright holder can do that. Nobody else can force you to do anything.

PS. If this is a private project, and you give it to your best mate, and you don't want anyone else to have your project: You can give the project, under an open source license, COMPLETE WITH SOURCE CODE, to your mate, and you have no further obligation at all. You have no obligation towards anyone. Your mate is allowed to give the project to others, but has no obligation. As long as you can trust your mate to not hand the project to anyone, nobody else has any rights. The important thing is that when you hand over the project, it must be accompanied by the source code. Without that, I can ask you for the source code.

1

Preface

This answer assumes that OP has a GPL'ed modified work he is distributing to his friends, and wants to avoid giving them his modifications to the source code. If by "uses another software" he means he simply executes their unmodified executable, then this answer would probably, depending on the exact details, be quite different (for example by distributing the two pieces separately).

The relevant bits of the GPL are the following; I have obviously quoted very short snippets only. Use these as a guideline for your own studies. The GPL document is quite short and, in my opinion, self-sufficient enough to work through it yourself instead of only relying on other opinions:

Propagation includes copying, distribution (with or without modification), making available to the public, and in some countries other activities as well.

To “convey” a work means any kind of propagation that enables other parties to make or receive copies.

Pure copyright (with not license whatsoever), in a nutshell, forbids propagating and conveying per default; the function of the GPL is to allow it and make sure it cannot be taken away. The copyright, per se, stays with the copyright holder.

You may convey covered works to others for the sole purpose of having them make modifications exclusively for you, or provide you with facilities for running those works,

Up to here, this last sentence is important (but not directly applicable to you!). It clears up an important issue which would otherwise mean it would be very hard to actually use GPLed software, or to work on it with subcontractors. It means that for example you can take a GPL'ed source, modify it, and give it to a subcontractor specifically to continue development for you. You can give it to, say, a hosting service to run it for you. Both without having to GPL your own modifications. This clause is far up in the license, and specifically says that for all other cases, the rest of the license is relevant.

Again, your use case does not fall under this clause.

GPL is "viral"

In all other cases, including yours, the rest of the license says this:

Conveying under any other circumstances is permitted solely under the conditions stated below.

You may convey a covered work in object code form under the terms of sections 4 and 5, provided that you also convey the machine-readable Corresponding Source

So this is rock solid and plain as daylight: it does not matter to how many people you distribute your modified work, or if it's private or public. By sending your friends your program, you must make the source code available to them. The license has a lot to say about ways how to do that. Specifically, you do not actually send the source code along with the program; it is enough if you have the source on a server and provide them the information how to get it.

Not necessarily public

On the question whether you need to also make the code publicly available: the license does not require that. The relevant chapter 6 makes three mentions of the word "public". One is the way "e)" to convey the source - but it only requires you to pick one of the ways; the others make no mention of it being public.

At the very end of chapter 6 is a mention that the way you provide the source has to be public. That is, if you a way to compress your code (i.e., as a tar or zip file), then the compression method must be public, and an implementation of the compression method, i.e. the programs "tar" or "unzip", have to be publicly available).

To clarify: this means you are not required to upload your modified source to a public source repository.

Must give unrestricted access to code

Finally, regarding whether your friends are then bound to the license:

You are not required to accept this License in order to receive or run a copy of the Program.

This means your friends can use the program however they see fit, they do not need to care about the source at all if they only use it. The obligation is on you to provide the source, but they have no obligation to actually download with it, or put it next to the program on their hard drive or anything like that.

But here's the kicker:

However, nothing other than this License grants you permission to propagate or modify any covered work. These actions infringe copyright if you do not accept this License. Therefore, by modifying or propagating a covered work, you indicate your acceptance of this License to do so.

This means you have, by giving the program to your friends, implicitly agreed to GPL your modified program. So you are indeed required to distribute the LICENSE together with your modified program, and you are required to give them free and unrestricted access to the code; and they do indeed have to do everything with the program and code as per the GPL - specifically, they can distribute the program, if accompanied by the source, in public.

There is no way for you to avoid that except by not giving your friends the program at all.

As said, the only exception for that are the two very specific cases mentioned in the preface - if your friends were developing the software for you, or hosting the software for you, then this would usage be exempt. But again, this is not what you are describing.

0

First of all, GPL requires you to provide your code upon request only to the people you have distributed GPL binaries to.

Now does your code need to be GPL in the first place?

In case you are using the MIT API of a GPL program, then your code likely doesn't have to be GPL but you shouldn't distribute the GPL parts together with your program as a bundle (unless allowed by some project modification of GPL).

In case your program supports multiple backends (lets call the GPL program you are using a backend) or is useful also without a backend, you can distribute your program without the GPL backend and let user locally install it (maybe with a script provided by you), then again you don't have to open source your code.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.