3

I have written a simple shell in C. I started my work when I had an OS lab. I did this as an assignment. I tried to implement cd, pipe, I/O redirection, background process, jobs, running system binaries, exit etc. Now, I want to open a project on my shell in GitHub so that anyone can contribute and beginner students can get help to start.

But, I don't want anyone to copy my code for his/her assignment. Is there any license that prohibits copying the code for assignment?

  • 1
    I'm voting to close this question as off-topic because the license asked about would not be Free or Open. – curiousdannii Sep 8 '17 at 14:36
  • @curiousdannii, you say "the license asked about would not be Free or Open". I think you are mistaken. Please see my answer, which mentions at least seven free software licenses that would be suitable :) – sampablokuper Sep 10 '17 at 1:32
  • @sampablokuper You have given some suggestions based on what they need, but not what was actually asked for. – curiousdannii Sep 10 '17 at 1:51
  • 7
    @curiousdanii I disagree with the close vote. I think there is value in saying, "This is not compatible with the tenants of FLOSS; here's why, and here's a FLOSS-friendly alternative." I think such answers provide value to the FLOSS community and their associated questions ought to be allowed. I weakly agree there is a danger of causing an explosion of such questions with minimal variations (there are an infinitude of possible terms that are exclusive to FLOSS) but I don't think we have that problem yet, and we could probably solve it with duplicates. (This discussion should to go meta.) – apsillers Sep 10 '17 at 18:35
  • 4
    For what it's worth, we allow any question about open source licensing recommendations, provided that: 1) It is asked in good faith 2) There is a demonstrated willingness or intent to find an open source license for their needs, even if such criteria would render it impossible. – Zizouz212 Sep 11 '17 at 1:47
10

It seems like you want the legal power to bring a lawsuit against any student who uses your code in any capacity related to schoolwork. I think this is a bad idea for two reasons.

First: this would not a FOSS license: it violates Freedom 0 ("The freedom to run the program as you wish, for any purpose") and point 6 of the OSD ("The license must not restrict anyone from making use of the program in a specific field of endeavor.") It will be incompatible with any copyleft license like the GPL and only add to license proliferation. There are existing licenses that will meet your needs without FOSS-incompatible terms (see below).

Second: I understand you want to discourage plagiarism, but schools and universities already have academic honor codes and cultural norms that strongly prohibit plagiarism. It is not your responsibility to enforce this, and any anti-academic licensing terms will likely only cause harm by disallowing innocent cases: what if a course instructor wants students to build off of your work for an assignment so they can learn how to read and extend existing code?

In any case, virtually any FOSS license will require redistributors to preserve your original copyright notices. If a student removes those in an attempt at plagiarism, then they will be in violation of the license anyway. There is no need for you to target plagiarism specifically. (And if the student doesn't remove those copyright notices, then I suspect the instructor will have a lot of questions about why someone else's name is on the project!)

6

Overview

I don't like that someone copy my code for his/her assignment. Is there any license that prohibit copying the code for assignment?

This question seems to conflate plagiarism with the overlapping but distinct concept of copyright infringement. Briefly:

  • plagiarism is the act of presenting someone else's knowledge work as one's own;
  • copyright infringement is the act of making unlicensed copies of a given knowledge work, in breach of copyright law.

A given act can be plagiarism, copyright infringement, both, or neither. Here is a Venn diagram showing the intersection between the two concepts:

     /-----------\  /--------------\
    /             \/                \
   /              /\                 \
  /              /  \                 \
 /              /    \                 \
|  Plagiarism  | Both |  Copyright      |
 \              \    /   infringement  /
  \              \  /                 /
   \              \/                 /
    \             /\                /
     \-----------/  \--------------/

For your purposes, preventing plagiarism is all that you need. For the sake of a complete answer, however, I will also discuss the prevention of copyright infringement. This will allow you to take a "belt and braces" approach.

Preventing plagiarism

As apsillers already indicated, any reputable educational institution will have policies against plagiarism and will enforce those policies. Any student who cheats by submitting your work as though it were their own should be caught and punished (e.g. by having their grade for that assignment reduced to zero).

In other words, preventing students from committing plagiarism in their assignments is a responsibility that rests with the students and the school, not with you.

Preventing copyright infringement

In most countries, copyright exists in any sufficiently original work that has been placed into a fixed form (e.g. written down). By default, this legally bars people other than the copyright holder (e.g. the author, or the entity that commissioned the work) from copying or adapting that work for any purpose except for the very limited purposes of "fair use" or "fair dealing".

In order to give people greater access to (copies of) that work, the copyright holder must typically license the work in some way.

Proprietary software licenses

With proprietary software, this is done with a EULA, which typically grants very limited rights to the licensee, such as the right to perform (run) the work, for some limited purposes. I personally would not recommend the use of such a license in general, and especially not in your case, as its restrictions would be excessive. Many free software licenses (see below for examples) would meet your needs just as well, and would be more beneficial to the community.

For a student to submit proprietary software as though it were their own would typically be an act of plagiarism and of copyright infringement.

Free software licenses

With free (libre) software, this is done with a license that upholds the Four Freedoms:

  • Freedom 0: The freedom to run the program for any purpose.
  • Freedom 1: The freedom to study how the program works, and change it to make it do what you wish.
  • Freedom 2: The freedom to redistribute and make copies so you can help your neighbour.
  • Freedom 3: The freedom to improve the program, and release your improvements (and modified versions in general) to the public, so that the whole community benefits.

None of these freedoms allows a recipient to claim authorship or copyright in the original work. As such, most popular free software licenses (e.g. the AGPLv3, the GPLv3, the ALv2, the 2-, 3-, and 4-clause BSD licences, or the MIT License) are suitable for satisfying a copyright holder's wish that a recipient should not be able to claim authorship or copyright of the work. I would suggest you use one of these licenses: preferably one of the first three, as they are the ones that best account for edge cases.

For a student to submit free software (i.e. software provided to them under such a license) as though it were their own would typically be an act of plagiarism and of copyright infringement.

Public domain: a special case of freedom

The most permissive possible license is a public domain dedication. This waives the right of the author or copyright holder to the fullest extent permitted by law. In the context of software, you could view this as meaning that arbitrary additional freedoms are granted in addition to the Four Freedoms above, i.e. as a very permissive form of free software licensing.

This is still quite rare, but you can do it if you want to, e.g. by applying the CC0 license.

For a student to submit a public domain work as though it were their own would typically be an act of plagiarism, but not of copyright infringement.

A note about GitHub

When publishing code to GitHub, you grant GitHub a license to use that code in certain ways. This license exists in addition to any other license (e.g. the GPLv3) that you might have applied to the work, and has been the subject of debate in the free software community.

For example, if you publish your work to GitHub, other GitHub users are in turn licensed to fork that work on GitHub's website, regardless of any other copyright restrictions on the work.

This is unlikely to affect your concern about plagiarism, for the reasons given earlier. Even so, as you stated you hope to publish to GitHub and expressed concerns about copying of your work, it seemed appropriate to mention it.

  • This site is about the Free and Open software movement. We generally recommend not answering questions which explicitly ask for license recommendations which would be in violation of the Free or Open definitions. In any case, you have answered with what the OP really needs, but not what they actually asked for, which can legitimately be considered Not An Answer. – curiousdannii Sep 10 '17 at 1:52
  • 1
    @curiousdannii, thanks for your comment :) "you have answered with what the OP really needs, but not what they actually asked for..." I think I provided both ;) "... which can legitimately be considered Not An Answer." We'll have to agree to disagree about that ;) However, I definitely should have been clearer that I was not advocating the use of proprietary licenses: mea culpa. I simply took that as read because of the context (i.e. opensource.SE), but I have now made it unmistakeable. Thanks for drawing my attention to that flaw in my answer! – sampablokuper Sep 10 '17 at 16:00
  • 2
    FWIW I think both the question and this answer are completely good and fine for this site. curiousdanni just has an extremely strict interpretation of the site's scope. – RubberDuck Sep 10 '17 at 20:13

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.