The lawyers of most organisations, write the contracts as if they are about property rights, and to protect their own rights. The organisation does not want to loose their own property rights.
However software is not like apples: If I have an apple, and you have an apple, and then we swap apples, then we both have one apple. If I have a program, and you have a program, and we both give each other a copy of the program, then we both have two programs. The programs have not diminished. Therefore to give one person rights we do not have to take them away form another.
Therefore with software there is no need to deprive others, for you to have a right over it. (software/music/etc is not property.)
The best way to do this, and protect the students is to allow the pupil to keep her/his copyright, and only giving copyright to the school, with a clause that they can not re-licence (This only gives the school power to prosecute infringement, but not to abuse their power. The pupil could not be prosecuted, as it is impossible for them to infringe the copyright, as they are a full copyright holder. You will need to see a lawyer for advice on this. Or better to talk to the FSF).
And then to use the GPL licence (a copyleft licence). Other licences, including the MIT licences (that are permissive), but especially proprietary licences can abuse the power that the school (or anyone else) has over the students.
This imbalance of power, may also invalidate any contract that you may think you have.
I believe that a permissive licence is just as bad in this situation, as it can use this permission to take advantage;
It would allow the school to create proprietary derivatives, of the pupils work. As the school may be in a better position to sell the software, this may not be fair.
Where as a copyleft licence such as the GPL, makes it much harder to take advantage of the author.
Any work that is licensed under the GPL gives anyone that has a copy of the program the following freedoms:
- The freedom to run the program as you wish, for any purpose (freedom 0).
- The freedom to study how the program works, and change it so it does your computing as you wish (freedom 1). Access to the source code is a precondition for this.
- The freedom to redistribute copies so you can help your neighbor (freedom 2).
- The freedom to distribute copies of your modified versions to others (freedom 3). By doing this you can give the whole community a chance to benefit from your changes. Access to the source code is a precondition for this.
However there freedoms are immutable, no one can, legally, distribute it without also giving these freedoms.
\begin{array}{|l|l|l|}
\hline
& Student\ has\ copyright & Student\ does\ not\ have\ copyright \\
\hline
Propratory & Student\ can\ use,\ modify,\ distribute. & \\
\hline
GPL & Anyone\ can\ use,\ modify,\ distribute. & Anyone\ can\ use,\ modify,\ distribute. \\
\hline
Permissive& Anyone\ can\ use,\ modify,\ distribute. & Anyone\ can\ use,\ modify,\ distribute. \\
\hline
\end{array}
\begin{array}{|l|l|l|}
\hline
& Student\ has\ copyright & Student\ does\ not\ have\ copyright \\
\hline
Propratory & Student\ can\ fork\ and\ change\ licence. & \\
\hline
GPL & Student\ can\ fork\ and\ change\ licence. & \\
\hline
Permissive& Anyone\ can\ fork\ and\ change\ licence. & Anyone\ can\ fork\ and\ change\ licence. \\
\hline
\end{array}
ethical ≠ legal
. If the student has legal representation at the same level as the school and the business, that's not obligated to either for payment, then an "ethical" situation might be achieved, otherwise it cannot. $\endgroup$