if I’m using an open source GPL-3.0 library in my saas product, do I need to publish my code under the same license as well?
-
Are you planning to publish your code at all? Since you mentioned SaaS, I guess you are just going to keep it on your own servers. But if you are planning on publishing it somewhere (the code, not the service), this fact will affect the answer.– BrandinCommented Apr 24, 2019 at 13:03
-
It's a commercial SaaS. We are not going to publish the code outside our private servers.– AbdelmawlaCommented Apr 24, 2019 at 18:09
2 Answers
If you only run the software on servers that you control, then that is not considered distribution according to the GPL license and thus you are not required to publish your source code.
If you give the binaries to others to run on their servers, then you are distributing the software and you need to observe the restrictions of the GPL license. That means that you must also provide your source code under a GPL-compatible license.
-
While compared to closed source, GPL does give more freedom, but compared to other open source licenses like MIT or BSD2/3 it also imposes restrictions. Since we are only talking about open source on this site, why don't you mention the restrictions in your answer? "That means that you must also povide your source code under a license that gives the recipients the same restrictions as they get with the GPL license." Not to mention that this sentence is incorrect since he uses a library. GPL does not set any more restrictions on the use of libraries than LGPL does.– Smart455Commented Apr 24, 2019 at 17:07
-
@Smart455: I didn't mention that because the GPL doesn't require all code in a project to have the same restrictions that the GPL has, only the same freedoms. You can combine GPL code with code that has more freedoms than the GPL (like the freedom to not distribute source code), but not fewer freedoms. Commented Apr 24, 2019 at 18:03
-
So why would he has to release his code under GPL (in your answer) if you just wrote (in your comment) that he actually could release it under more permissive license and combine that with GPL? Which one is it then?– Smart455Commented Apr 24, 2019 at 18:17
-
1@Smart455: His code does not have to be under the GPL and I have edited my answer to make that more clear. The license does have to be compatible with the GPL though to make the act of distribution legal. Commented Apr 24, 2019 at 18:30
-
2GPL does not really have 'restrictions' it has obligations. If you want to distribute GPL code, you must supply all the relevant source code. The only apparent confusion is that sometimes people think that if they make some changes or add-ons to some GPL code, then somehow the parts they add are completely 'theirs'. No. Just like if you buy a Harry Potter book and decide to write your own chapter based on that. Yes, you wrote it, but it is not really 'yours'. It is a derivative work. With GPL, though, you are allowed to make derivative works, as long as you follow the license terms.– BrandinCommented Apr 25, 2019 at 4:22
By law you are free to license your code as you decide to license it. No one can force you to do anything. Just be prepared to fight for your right in a court in case some FSF, FSC or some similar organisation is going to bully you.
So instead ask yourself: do you have the resources to go to court? Are you a sort of person who gets easily intimidated by threats and false claims? You can estimate your risks by counting all the down-votes this answer gets from the fascists around here alone.
-
2No, this is not how it works. If you distribute someone else's code (which is GPL licensed), then that license says under what terms you are allowed to distribute their software. One of the terms of GPL is that if you make a derivative work (by combining GPL code with your code), then you must distribute the source code to the whole derived work when you distribute it. If you don't agree to this term, you must not make derivative works from that software.– BrandinCommented Apr 25, 2019 at 4:10
-
@Brandin So where does it say that incorporating someones library, without modifying it, makes it a derivative work? Can you please point out where in gpl sets any more restrictions to (/burden with obligations) libraries than lgpl?– Smart455Commented Apr 25, 2019 at 6:37
-
1This answer is technically correct, but highly misleading in context. Also @Smart455 you are alluding to things that are simply not clear in any jurisdiction: there is no clear precedent anywhere as to what precisely a derivative work is in the context of software libraries. FSF has one opinion on that. If that opinion is true, the LGPL provides a useful exception. People wanting to minimize compliance risks should follow the FSF opinion as well, since it's a “worst case” from their perspective. Others have voiced other opinions, e.g. Lawrence Rosen.– amonCommented Apr 26, 2019 at 10:49
-
@amon FSF is extremely biased about their licenses and therefore it's pointless to ask their opinion on it. There is threat that they might jump on anyone who would challenge their reign of terror and that's why I felt necessary to warn about it.– Smart455Commented Apr 29, 2019 at 18:00