When looking for a strong open source license for a new project, a license such as the (A)GPLv3 provides a round-all catch-all protection against legal shenanigans such as patent disputes.

Effectively it ensures that software that was intended to contribute to an open society cannot be turned around and used against that goal. (among other things)

The open source community is adamant that discrimination against field is incompatible with the open source idea. Reasons for this range from technical ("where do you draw the line") to idealistic ("it's not really free if not all can use it for whatever"). The FSF has been very clear that a limitation of the use should even be opposed even when it attempts to forbid the use for "really bad thing"s.

However, people have been trying to limit the use of their software for various specific and unspecific things they don't like:

What I want, and I think also motivates the examples above, is the intent to protect the idea of open source not to the letter, but to its spirit. A way to limit the tools intended for an open society by people or organisations (and specifically their goals) that are incompatible with it -- according to my interpretation as the software's author. For example, the ideology of fascists is utterly incompatible with a free society, so I want to limit the use of free software so that it cannot be used to further such a cause (e.g. the official website of the BNP uses WordPress under a GPLv2 license, so does the Identitäre Bewegung, and many many more).

I understand the general position expressed by the FSF for a general-purpose license like the GPL, if only from a practical standpoint; How do we define what is and isn't considered to fall under a category such as JSON's "Evil"? But the general case doesn't necessarily apply to the special case.

So - How do I license a piece of software under the GPL or something equivalent, while excluding its limitation that no discrimination can be made for its applicability? Specifically I want to list a number of purposes and fields that are not covered by the license for the very reason that they are (ideologically) incompatible with the (perceived) spirit of the license.

  • "For example, the ideology of fascists is utterly incompatible with a free society" The "free" in free software doesn't mean all freedoms ever, but specific ones. Fascists, dictators, anarchists, they can all use and uphold the free software definition. – curiousdannii May 5 at 4:11
  • 3
    Forbidding fascists (or some other group of 'bad' people) from using the software is not in the 'spirit' of free or open source software. The software should be able to be used by anyone. – Brandin May 5 at 4:24
  • 3
    The best way to ensure such culture thrives is to live it, to use well-established open source licenses, and to refrain from dictating what people have to do or leave do. It's the same problem with any producer of dual-use hardware: you can use a knife to prepare food or kill a person. As manufacturer focus on the good examples and condone the bad. But putting that all in a sales contract... makes things complicated for all the good and doesn't stop the bad. – planetmaker May 5 at 8:06

You are not the first person to want to try this. In 2019 Coraline Ehmke released the Hippocratic Licence, which forbids the use of covered software to violate human rights laws. She's not the first person to try it either, but she's not unknown in the free software world, so you may learn some salutary lessons from how it worked out for her.

Apparently over 300 projects have signed up to use it. You can see the A-list here, and you will notice no projects of any significance at all. The estimable Andrew Katz writes about it for OpenUK, and he makes some very worthwhile points, the first of which is

If people use the [Hippocratic Licence] then this creates yet another, incompatible pool of software, which cannot be combined with any copyleft code, and can only be combined with open source software licensed under very liberal licences.

That's not a good outcome; we need more, mutually-incompatible free software licences like we need holes in our heads. It's not that the aims people are seeking this way aren't desirable ends, it's that they are only tangentially connected to the software and the process of its development, and so they don't fit well into a software licence, and they don't work well when they're there. Katz notes similar desires arising when he was involved in drafting the CERN Open Hardware Licence:

In our drafting of the CERN OHLv2, we were often asked to incorporate superficially desirable conditions, like a condition requiring any item made from the design to be energy efficient, or to use sustainable materials, or to be easily repairable.

He didn't yield to any of them, but instead suggests a potential solution:

We suggest that organisations could apply a certification, to say that certain items of hardware meet sustainability standards, or are certified repairable. That is, a certification which is in parallel with the licensing requirement, and in order to use the relevant certification mark, the distributor of the hardware would have to be licensed by the relevant body. In effect, control would be through a combination of community norms, and legal remedies akin to trademark infringement.

There is no reason why such a scheme could [not] be extended to software.

I think this is excellent advice. Instead of muddying the waters with Yet Another Weird Licence, use a regular copyleft licence, and launch a marking exercise for users of your software, something that they can only display if they avoid military use, or commercial use, or even (if you can define it) evil use. I'd really like to see a sticker on my next laptop that says, eg, "non-weaponised bitmask software inside". Note that copyleft is a necessity for this scheme to work: there's no shame in weaponising the bitmask software if nobody knows you've done it, because nobody knows your product includes bitmask.

Edit to address Diagon's comment, infra: re governments, it won't work brilliantly, to be honest, because the consumer doesn't care about acceptability: they're the only game in town. There are other ways to pressure governments, though, of which I recommend the ballot box.

To answer your second point, about the little extra clause: your software is then GPL-incompatible. If you purport to distribute it under GPLv2 with the extra clause, it's simply unusable in practice (crayon licence, non-free, GPL-incompatible). If you purport to do so under GPLv3, your additional clause may simply be ignored under s7.

My point is that your choice as an author is not between software that may be used by all and software that may be used by all except bad people. Because of pre-existing expectations and modes of interaction in the free software community, your choice is between software that may be used by all and software that may be used by nearly nobody. If you're happy with the latter, why pretend to be writing free software at all? Release as zero-cost proprietary software, and then I guarantee your work can't be re-used by bad people, because it can't be re-used by anyone.

| improve this answer | |
  • Very informative, thank you. However, I don't quite see how the proposed "solution" applies to software as there is zero incentive (that I can see) for any "nefarious" entity to care about having or not having an "ethical cert" sticker on their product if they can get away with it. – bitmask May 6 at 21:23
  • 2
    @bitmask Certifications don't motivate nefarious companies, but rather motivate virtuous consumers toward companies that aren't nefarious. Nefarious companies care only insofar as a shift in demand harms their business. Meanwhile, consumers and communities who care enjoy the choice of using known non-nefarious sources. Consider, e.g., the Respects Your Freedom certification for hardware -- many people (and businesses) have probably never heard of it, but those who care about the subject use it. – apsillers May 6 at 21:47
  • 1
    When customers are governments, so eg. weapons manufacturers, how would this work? And, if a license clause were added that said, "Northrop Grumman is not to use this software," then how would that interfere with use in relation to, say other GPL'd software? – Diagon May 13 at 7:02
  • 1
    @Diagon see above. – MadHatter May 13 at 7:38

How do I license a piece of software under the GPL or something equivalent, while excluding its limitation that no discrimination can be made for its applicability?

For the GPL, you cannot. The GPL license explicitly forbids additional restrictions and if you do add such a restriction, recipients of your software are allowed to disregard and even remove them.

For "something equivalent", you will have to ask a lawyer to draft you a new license. Most likely this license will not be accepted as an open-source license, so it will do your cause little good.

| improve this answer | |

How do I enforce not just the letter but also the spirit of open source for an open culture?

You practically cannot

If you write your own license, you need a lawyer. And even if your new license is seriously written there are lots of places where using your software won't be allowed. (e.g. large corporations are limiting the set of usable licenses on corporate computers, to a small subset of open source licenses, and individuals usually don't bother compiling source code... Think of the GCC compiler: do you compile it from its source code in 2020?).

And don't be naive: as soon as you publish some code on the web, someone could download it and might mis-use it (e.g. the PHP interpreter or the Ocaml compiler is certainly used for activities you disagree with; it is open source). That guy can be a gangster, a criminal, a military in some dictature regime, an engineer in a GAFAM corporation that you dislike...

personal example

FWIW, I worked in the past (2004) on the POESIA internet content filtering project (GPLv3). The good motivation (and reason for funding that interesting project by the European Union) was of course protection of European school-aged kids (e.g. against porn sites).

Ten years later, I have been contacted by some Iranian guy, starting his email with "In the name of the Iranian republic" about that project.

I just ignored that email.

Also the notion of open culture or freedom varies a lot. A widely known example is public apology of Nazism: legal in the USA, illegal in France or Germany. My opinion is that the US culture is no more open than the French or German one.

PS. Be aware of code obfuscation techniques. See this answer.

NB. I am of course ignoring illegal means, such as machine guns or bribery.

| improve this answer | |

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.