"Borrowing" code

N

Novice

I'm curious to know the legalities involved in "borrowing" code without
paying for it.

Let me clarify. Let's say that I find some code snippets or even entire
classes, displayed on websites and that it would save me time and money
to use those classes in my own projects. This web site, www.java2s.com,
is just one of many such web sites on the Internet, as is the Java
Tutorial at the Oracle website.

Assuming I make no claim that I am the author (by leaving the @author
Javadoc tag empty), am I "stealing" this code? What if I cite the author
name in the @author tag (or the URL of the webpage in a comment if the
author's name isn't present in the code)? Or would I have to get written
permission of the author or website to use the code? Or even obtain a
licence before I can use the code?

Code published in web pages or newsgroup posts "feels" as if it should be
in the public domain but I think that's just wishful thinking on my part.
Given that you can look at it without paying anyone for that privilege,
and copy it into your own IDE and try it, etc. it feels as if it is there
to be used. But as I understand it, those who create written works,
whether books or programs, are their owners (unless in the employ of
others) and retain copyright on this work, a copyright that typically
lasts for the developer's life plus 70 years.

If copyright does apply to all these snippets and example classes, would
I be able to bypass copyright by modifying the code in some small way -
maybe just with some comments or different variable names - or would that
be the equivalent of painting a stolen car: it doesn't negate the fact
that it's stolen and just tries to make it less obvious?

I've been banging my head against a wall for a while on a couple of
classes my project needs and I have found two perfectly good classes that
meet my needs so I'd like to use them rather than put still more time
into making my own classes work satisfactorily. I'd like to figure out
what I can do to use the clases I found without having to look over my
shoulder (or fight my conscience) on the question of "stealing" this
code.
 
G

glen herrmannsfeldt

Novice said:
I'm curious to know the legalities involved in "borrowing" code without
paying for it.
Let me clarify. Let's say that I find some code snippets or even entire
classes, displayed on websites and that it would save me time and money
to use those classes in my own projects. This web site, www.java2s.com,
(snip)
If copyright does apply to all these snippets and example classes, would
I be able to bypass copyright by modifying the code in some small way -
maybe just with some comments or different variable names - or would that
be the equivalent of painting a stolen car: it doesn't negate the fact
that it's stolen and just tries to make it less obvious?

The general rule is that copyright protects the expression,
not the idea. Exactly how much modification you need to make
is not so well defined. (IANAL, as usual.)

But no, it isn't very much like painting a stolen car.
Remember, it is the intellectual property we are talking about,
not the physical property. You can own a physical object without
owning the copyright to it, as is commonly true with studio
portraits. You own the print, the studio the copyright, even
though it is a picture of you!
I've been banging my head against a wall for a while on a
couple of classes my project needs and I have found two
perfectly good classes that meet my needs so I'd like to
use them rather than put still more time into making my
own classes work satisfactorily.

I don't know the details very well. Usually if it is pretty
small, I wouldn't worry about it, if larger you should at least
acknowlege the source. If it is on a public web site with
no notice, then I would worry less than some other places.

-- glen
 
L

Lew

Novice said:
I'm curious to know the legalities involved in "borrowing" code without
paying for it.

It depends entirely on the license for that code.
Let me clarify. Let's say that I find some code snippets or even entire
classes, displayed on websites and that it would save me time and money
to use those classes in my own projects. This web site, www.java2s.com,
is just one of many such web sites on the Internet, as is the Java
Tutorial at the Oracle website.

Can you spell "plagiarism"? How about "lawsuit"?
Assuming I make no claim that I am the author (by leaving the @author
Javadoc tag empty), am I "stealing" this code? What if I cite the author

Yes, if you violate the license it's still stealing (and no quotes around it, either - putting quotes around "stealing" doesn't make the act more ethical).
"@author" Javadoc tags have nothing at all whatsoever to do with claiming
authorship.
name in the @author tag (or the URL of the webpage in a comment if the
author's name isn't present in the code)? Or would I have to get written
permission of the author or website to use the code? Or even obtain a
licence before I can use the code?

You obtain a license in accordance with the terms of the license. Copyright
inheres upon authorship, at least in U.S. law, and thus you are obligated to
respect it regardless of source. Each program is released under different
terms; you must respect the terms on a case-by-case basis or you're liable.
Code published in web pages or newsgroup posts "feels" as if it should be
in the public domain but I think that's just wishful thinking on my part.

Yes, that's true. "Feels" is not a legal basis (nor an engineering one, unless
your professional intuition is very well honed) for action.
Given that you can look at it without paying anyone for that privilege,
and copy it into your own IDE and try it, etc. it feels as if it is there

There's that "feels" again. Tsk, tsk.
to be used. But as I understand it, those who create written works,
whether books or programs, are their owners (unless in the employ of
others) and retain copyright on this work, a copyright that typically
lasts for the developer's life plus 70 years.

The term depends on the jurisdiction, the work, when and how it was published,
and whether it was done for hire, anonymously, pseudonymously, or otherwise.
If copyright does apply to all these snippets and example classes, would
I be able to bypass copyright by modifying the code in some small way -
maybe just with some comments or different variable names - or would that
be the equivalent of painting a stolen car: it doesn't negate the fact
that it's stolen and just tries to make it less obvious?

Why are you so anxious to bypass copyright? Are you a criminal?
I've been banging my head against a wall for a while on a couple of
classes my project needs and I have found two perfectly good classes that
meet my needs so I'd like to use them rather than put still more time
into making my own classes work satisfactorily. I'd like to figure out
what I can do to use the clases I found without having to look over my
shoulder (or fight my conscience) on the question of "stealing" this
code.

If you're doing this in an academic environment, you should be worried about
the rules for plagiarism, not the rules for copyright.

If you're doing this in a commercial environment, don't take risks. The entire
tenor of your post is that of someone trying to skirt the rules. Bad boy!

If you're doing this for a review or satire, or for personal use, then "fair
use" doctrine applies. Just don't go beyond fair-use boundaries.

BTW, asking a bunch of software guys for legal advice is absolutely a winning
formula. Make sure to ask taxi drivers for medical advice and supermarket
cashiers where to invest as well. After all, many taxi drivers are pre-med
majors, and some cashiers are studying for their MBAs. Heck, I've met
supermarket cashiers who were attorneys. One-stop shopping - bread, milk,
cigarettes, investment advice and legal counsel. Did you remember your courtesy
card for the discount?
 
B

BGB

I'm curious to know the legalities involved in "borrowing" code without
paying for it.

I am by no means a legal expert, nor am I functioning as a valid legal
council, but I am writing of these matters as I understand them.

Let me clarify. Let's say that I find some code snippets or even entire
classes, displayed on websites and that it would save me time and money
to use those classes in my own projects. This web site, www.java2s.com,
is just one of many such web sites on the Internet, as is the Java
Tutorial at the Oracle website.

Assuming I make no claim that I am the author (by leaving the @author
Javadoc tag empty), am I "stealing" this code? What if I cite the author
name in the @author tag (or the URL of the webpage in a comment if the
author's name isn't present in the code)? Or would I have to get written
permission of the author or website to use the code? Or even obtain a
licence before I can use the code?

here is the issue:
it is not about who is cited as the author, this is related to academic
notions of "plagiarism", but is not all that relevant as far as code is
concerned;
you don't generally "obtain" a license to use someones' code, they
assign a license to said code (describing the particular terms under
which it can be used), and everyone else is expected to follow these
terms (under the power of law).

it is worth looking for the terms, as many people will just put the code
under some or another FOSS license (GPL, BSD, MIT, ...), in which case
one can use it freely under these terms.


one can often "license" something (as in, pay them for the legal right
to make use of it), but this is a different matter (not directly related
to copyright law per-se, but may be regarded as a use-case for copyright
law).

Code published in web pages or newsgroup posts "feels" as if it should be
in the public domain but I think that's just wishful thinking on my part.

yes, it is wishful thinking (partly).

typically, the website will list somewhere what sort of terms of use the
code is under.
as far as the law is concerned, if no terms of conditions are found, one
either has to ask permission, or has no implicit rights to use the code.

in practice, it probably doesn't matter too much, since:
if they put it up on a website, they probably don't really care whether
or not anyone uses it (they probably intend that someone does make use
of it);
if the fragment is fairly small, the courts probably aren't really going
to bother to care either.


it is also not like you are going, taking some random piece of
commercial software, and ripping off bits of its source code. this would
be far less certain, and people are far more likely to try to sue out of
general principle.


similarly, small fragments may also fall under the terms of "fair use",
which isn't technically the same as "public domain", but rather means
that the law has decided not to bother.

this, however, does lead to some controversy, with different people
having differing opinions as to what constitutes fair use.


some people believe in notions of "strict copyright enforcement" which
implicitly denies the notion of fair use, but AFAIK what cases have been
raised on these grounds have often been dismissed as "frivolous" in the
courts.

most commonly, this has been in relation to people using short
audio-clips from songs in composing longer songs, or in using parts of
images in constructing other artwork or in TV shows, like "our logo can
be made out in this particular shot of this particular episode of this
particular show, we want the network to pay us $100M" (then one can see
just how long until the case gets dismissed). (or, in an old, terrible,
"futuristic" SciFi movie where one could clearly see a computer with a
Windows 9x desktop in one of the shots, it is nice to know that the
distant future uses CRT monitors and runs Windows 98, never-mind that
"Encom OS" was apparently actually Ubuntu, ...).


the notion of strict-enforcement remains more common with code, but
probably only assuming anyone actually cares, and if it is put up on a
website for public use, it is probably not all that likely that anyone
is going to care.

"tables of numbers or other information" are generally safe.

Given that you can look at it without paying anyone for that privilege,
and copy it into your own IDE and try it, etc. it feels as if it is there
to be used. But as I understand it, those who create written works,
whether books or programs, are their owners (unless in the employ of
others) and retain copyright on this work, a copyright that typically
lasts for the developer's life plus 70 years.

yes.
but, as noted, they may either allow them to be used (maybe stated
explicitly somewhere), or the use may fall under fair-use.

If copyright does apply to all these snippets and example classes, would
I be able to bypass copyright by modifying the code in some small way -
maybe just with some comments or different variable names - or would that
be the equivalent of painting a stolen car: it doesn't negate the fact
that it's stolen and just tries to make it less obvious?

it, again, depends.

there is a rule of something like 20% modification means copyright no
longer applies, but what exactly this means for code is less clear.

I would guess that code which differs only in that the variable names
are changed and that 20% of the characters are different would not apply.

however, if the code has been "naturally" altered almost beyond all
recognition, I would guess it is probably safe.

I've been banging my head against a wall for a while on a couple of
classes my project needs and I have found two perfectly good classes that
meet my needs so I'd like to use them rather than put still more time
into making my own classes work satisfactorily. I'd like to figure out
what I can do to use the clases I found without having to look over my
shoulder (or fight my conscience) on the question of "stealing" this
code.

simplest answer is to see if one can find a license anywhere, and then
act under the terms of the license.

effectively, this prevents them from taking any action, as well (as I
understand it) any other parties they may have potentially "stolen" from
(legally, it is their fault in this case).


however, if it is something like a warez site, then the above likely
doesn't hold (they can't offer any sort of legal protection as they are,
by definition, illegal).

it is much like, people are free to buy and sell stuff, but they may
still be legally accountable for knowingly buying and selling stolen
property (this is also why places like pawn shops will turn away things
that they suspect are stolen).


granted, there are a lot of grey areas...
 
G

Gene Wirchenko

On 2/16/2012 12:59 PM, Lew wrote:
...

There is one situation in which asking a programmer about this is useful
- asking the author of the code about a proposed use.

The first step should, of course, be to look at the code itself and the
web site for licensing information. The next step, if the code contains
a copyright notice, an @author tag, or other indication of authorship,
should be to try to contact the author.

I agree with this.

I also think that someone posting tutorial material that is
freely available on the Web can be presumed to be making it freely
available for use. Otherwise, what is the point of the tutorial? An
explicit copyright statement with the code would trump that though.

Sincerely,

Gene Wirchenko
 
J

Jeff Higgins

I'm curious to know the legalities involved in "borrowing" code without
paying for it.

Let me clarify. Let's say that I find some code snippets or even entire
classes, displayed on websites and that it would save me time and money
to use those classes in my own projects. This web site, www.java2s.com,
is just one of many such web sites on the Internet, as is the Java
Tutorial at the Oracle website.
The java2s site doesn't seem to have a TOS that I could find.
Most of the pages are marked with an "All rights reserved" copyright notice.
There is a "Contact us" link.
If you look at the bottom of the Java Tutorial "reallybigindex" page
there are links to the TOS and Code Sample License.
 
A

Arved Sandstrom

It depends entirely on the license for that code.


Can you spell "plagiarism"? How about "lawsuit"?


Yes, if you violate the license it's still stealing (and no quotes around it, either - putting quotes around "stealing" doesn't make the act more ethical).
"@author" Javadoc tags have nothing at all whatsoever to do with claiming
authorship.


You obtain a license in accordance with the terms of the license. Copyright
inheres upon authorship, at least in U.S. law, and thus you are obligated to
respect it regardless of source. Each program is released under different
terms; you must respect the terms on a case-by-case basis or you're liable.


Yes, that's true. "Feels" is not a legal basis (nor an engineering one, unless
your professional intuition is very well honed) for action.


There's that "feels" again. Tsk, tsk.


The term depends on the jurisdiction, the work, when and how it was published,
and whether it was done for hire, anonymously, pseudonymously, or otherwise.


Why are you so anxious to bypass copyright? Are you a criminal?


If you're doing this in an academic environment, you should be worried about
the rules for plagiarism, not the rules for copyright.

If you're doing this in a commercial environment, don't take risks. The entire
tenor of your post is that of someone trying to skirt the rules. Bad boy!

If you're doing this for a review or satire, or for personal use, then "fair
use" doctrine applies. Just don't go beyond fair-use boundaries.

BTW, asking a bunch of software guys for legal advice is absolutely a winning
formula. Make sure to ask taxi drivers for medical advice and supermarket
cashiers where to invest as well. After all, many taxi drivers are pre-med
majors, and some cashiers are studying for their MBAs. Heck, I've met
supermarket cashiers who were attorneys. One-stop shopping - bread, milk,
cigarettes, investment advice and legal counsel. Did you remember your courtesy
card for the discount?
Bit of an overheated reaction to what I thought were reasonable questions.

I'm the last person to advocate filching code that should be attributed
(or paid for or both). I make my living writing code for money, and I'd
be annoyed if someone copied it and passed it off as theirs.

*If* my code was non-obvious, that is. Or incorporated significant
domain knowledge. In other words, if it actually merited some legal
protections, according to commonsense.

There is a lot of code out there that ought to be under copyright
according to the rules, but should not be copyrighted according to
commonsense. There are myriads of code snippets that express concept
implementations, in every programming language, that any well-versed
person would code more or less in the same fashion, with only very
trivial tweaks. Tutorials, for example, are positively loaded with this
kind of code. Should any of it qualify for copyright? Why should it? Why
should code like that qualify when 500 or 5000 or 50000 other coders
have already independently written basically the same thing?

Code is not like prose or poetry. It's possible to provide a bunch of
programmers with the same detailed design of a proposed solution, and
assuming a good level of skill, it won't be unusual to see many highly
similar elements in the independent implementations. So why should any
of that be copyrighted?

Who amongst us hasn't seen code snippets on the Web that didn't look
remarkably like something we had written ourselves?

Anyway, there are much better reasons not to worry about copyright, even
in the frequent cases when it legally exists but is retarded. It's much
better - for several reasons - not to copy and paste. One, you have no
idea if the code is defective or not if you just copy it. If it's so
trivial that you can immediately tell by visual inspection that it's OK,
as in a "public static void main Hello World" example (which the lawyers
would argue is under copyright), then you should just type it in yourself.

Two, from a learning standpoint, and a downroad maintenance standpoint,
you shouldn't copy and paste non-trivial code because you're sacrificing
a learning opportunity. Presumably you went hunting for the code snippet
because you didn't know how to do it yourself. Learn from the code
snippet, and work through it. Build up your own implementation, *guided*
by the example. Quite frankly, if you end up with code that you typed
yourself, and you thoroughly understand it, and could now independently
write it, you can ethically feel good about your efforts. My sincere
opinion.

AHS
 
N

Novice

It depends entirely on the license for that code.


Can you spell "plagiarism"? How about "lawsuit"?


Yes, if you violate the license it's still stealing (and no quotes
around it, either - putting quotes around "stealing" doesn't make the
act more ethical). "@author" Javadoc tags have nothing at all
whatsoever to do with claiming authorship.


You obtain a license in accordance with the terms of the license.
Copyright inheres upon authorship, at least in U.S. law, and thus you
are obligated to respect it regardless of source. Each program is
released under different terms; you must respect the terms on a
case-by-case basis or you're liable.


Yes, that's true. "Feels" is not a legal basis (nor an engineering
one, unless your professional intuition is very well honed) for
action.


There's that "feels" again. Tsk, tsk.


The term depends on the jurisdiction, the work, when and how it was
published, and whether it was done for hire, anonymously,
pseudonymously, or otherwise.


Why are you so anxious to bypass copyright? Are you a criminal?


If you're doing this in an academic environment, you should be worried
about the rules for plagiarism, not the rules for copyright.

If you're doing this in a commercial environment, don't take risks.
The entire tenor of your post is that of someone trying to skirt the
rules. Bad boy!
I'm sorry if it came off that way. I'm actually trying NOT to break any
laws or rules, which is why I'm trying to find out when it's okay to
borrow something and when it is not.
If you're doing this for a review or satire, or for personal use, then
"fair use" doctrine applies. Just don't go beyond fair-use boundaries.

BTW, asking a bunch of software guys for legal advice is absolutely a
winning formula. Make sure to ask taxi drivers for medical advice and
supermarket cashiers where to invest as well. After all, many taxi
drivers are pre-med majors, and some cashiers are studying for their
MBAs. Heck, I've met supermarket cashiers who were attorneys. One-stop
shopping - bread, milk, cigarettes, investment advice and legal
counsel. Did you remember your courtesy card for the discount?

I have no intention of treating what I read here as solid gold top-shelp
legal advice. I know I have to pay for that and, even then, there are no
guarantees. All a laywer is ever really going to do is tell me if a given
act has been prosecuted in the relevant jurisdiction and whether the
court's decision has been upheld by higher courts or overturned.

But my theory is that people who are writing code for a living probably
all have at least a ballpark sense of what is common practice - and
therefore _probably_ legal - and that's what I'm trying to find out.
 
N

Novice

On 2/16/2012 12:59 PM, Lew wrote:
...

There is one situation in which asking a programmer about this is
useful - asking the author of the code about a proposed use.

The first step should, of course, be to look at the code itself and
the web site for licensing information. The next step, if the code
contains a copyright notice, an @author tag, or other indication of
authorship, should be to try to contact the author.

Patricia

That seems like very sound advice. Thank you both, Lew and Patricia.
 
A

Arne Vajhøj

I'm curious to know the legalities involved in "borrowing" code without
paying for it.

Let me clarify. Let's say that I find some code snippets or even entire
classes, displayed on websites and that it would save me time and money
to use those classes in my own projects. This web site, www.java2s.com,
is just one of many such web sites on the Internet, as is the Java
Tutorial at the Oracle website.

Assuming I make no claim that I am the author (by leaving the @author
Javadoc tag empty), am I "stealing" this code? What if I cite the author
name in the @author tag (or the URL of the webpage in a comment if the
author's name isn't present in the code)? Or would I have to get written
permission of the author or website to use the code? Or even obtain a
licence before I can use the code?

Code published in web pages or newsgroup posts "feels" as if it should be
in the public domain but I think that's just wishful thinking on my part.
Given that you can look at it without paying anyone for that privilege,
and copy it into your own IDE and try it, etc. it feels as if it is there
to be used. But as I understand it, those who create written works,
whether books or programs, are their owners (unless in the employ of
others) and retain copyright on this work, a copyright that typically
lasts for the developer's life plus 70 years.

If copyright does apply to all these snippets and example classes, would
I be able to bypass copyright by modifying the code in some small way -
maybe just with some comments or different variable names - or would that
be the equivalent of painting a stolen car: it doesn't negate the fact
that it's stolen and just tries to make it less obvious?

I've been banging my head against a wall for a while on a couple of
classes my project needs and I have found two perfectly good classes that
meet my needs so I'd like to use them rather than put still more time
into making my own classes work satisfactorily. I'd like to figure out
what I can do to use the clases I found without having to look over my
shoulder (or fight my conscience) on the question of "stealing" this
code.

Ideally the code should already have been assigned a license and then
if you comply with that license then you are good.

With no license you have no right to use the cod.

I would agree that code posted at web sites, usenet groups
with the obvious intent to provide help for other users
has an implicit permissive license.

But how that would fly with the lawyers in court
that I do not know.

Arne
 
A

Arne Vajhøj

I have no intention of treating what I read here as solid gold top-shelp
legal advice. I know I have to pay for that and, even then, there are no
guarantees. All a laywer is ever really going to do is tell me if a given
act has been prosecuted in the relevant jurisdiction and whether the
court's decision has been upheld by higher courts or overturned.

But my theory is that people who are writing code for a living probably
all have at least a ballpark sense of what is common practice - and
therefore _probably_ legal - and that's what I'm trying to find out.

We can certainly tell you about common practice.

How much common practice follow the law is another
question.

My guess is that it depends on the number of cases
that went to court.

If there are hundreds of cases everybody know how
the verdicts go.

With zero cases the correlation between common practice
in the IT world and the law may be very small.

I have never heard about a case related to this
question.

Arne
 
N

Novice

BGB said:
I am by no means a legal expert, nor am I functioning as a valid legal
council, but I am writing of these matters as I understand them.



here is the issue:
it is not about who is cited as the author, this is related to
academic notions of "plagiarism", but is not all that relevant as far
as code is concerned;
you don't generally "obtain" a license to use someones' code, they
assign a license to said code (describing the particular terms under
which it can be used), and everyone else is expected to follow these
terms (under the power of law).

it is worth looking for the terms, as many people will just put the
code under some or another FOSS license (GPL, BSD, MIT, ...), in which
case one can use it freely under these terms.


one can often "license" something (as in, pay them for the legal right
to make use of it), but this is a different matter (not directly
related to copyright law per-se, but may be regarded as a use-case for
copyright law).



yes, it is wishful thinking (partly).

typically, the website will list somewhere what sort of terms of use
the code is under.
as far as the law is concerned, if no terms of conditions are found,
one either has to ask permission, or has no implicit rights to use the
code.

in practice, it probably doesn't matter too much, since:
if they put it up on a website, they probably don't really care
whether or not anyone uses it (they probably intend that someone does
make use of it);

Exactly! This is why it seemed to me that it might be okay to "borrow"
such examples. It seemed self-evident that someone writing a tutorial
meant for it to be used in developing code.

I wasn't contemplating stealing the full source code for Windows here,
just using a small class or two that someone had figured out and
displayed publicly.
if the fragment is fairly small, the courts probably aren't really
going to bother to care either.


it is also not like you are going, taking some random piece of
commercial software, and ripping off bits of its source code. this
would be far less certain, and people are far more likely to try to
sue out of general principle.


similarly, small fragments may also fall under the terms of "fair
use", which isn't technically the same as "public domain", but rather
means that the law has decided not to bother.

this, however, does lead to some controversy, with different people
having differing opinions as to what constitutes fair use.


some people believe in notions of "strict copyright enforcement" which
implicitly denies the notion of fair use, but AFAIK what cases have
been raised on these grounds have often been dismissed as "frivolous"
in the courts.

most commonly, this has been in relation to people using short
audio-clips from songs in composing longer songs, or in using parts of
images in constructing other artwork or in TV shows, like "our logo
can be made out in this particular shot of this particular episode of
this particular show, we want the network to pay us $100M" (then one
can see just how long until the case gets dismissed). (or, in an old,
terrible, "futuristic" SciFi movie where one could clearly see a
computer with a Windows 9x desktop in one of the shots, it is nice to
know that the distant future uses CRT monitors and runs Windows 98,
never-mind that "Encom OS" was apparently actually Ubuntu, ...).


the notion of strict-enforcement remains more common with code, but
probably only assuming anyone actually cares, and if it is put up on a
website for public use, it is probably not all that likely that anyone
is going to care.
Exactly. That's why I'm asking about the usability of the code I see in
those public places.
"tables of numbers or other information" are generally safe.



yes.
but, as noted, they may either allow them to be used (maybe stated
explicitly somewhere), or the use may fall under fair-use.



it, again, depends.

there is a rule of something like 20% modification means copyright no
longer applies, but what exactly this means for code is less clear.

I would guess that code which differs only in that the variable names
are changed and that 20% of the characters are different would not
apply.

however, if the code has been "naturally" altered almost beyond all
recognition, I would guess it is probably safe.



simplest answer is to see if one can find a license anywhere, and then
act under the terms of the license.
Agreed. I will look for the licence terms, if any, for this code. Or
maybe I'll just study the heck out of it, figure out how it works, and
then write my own version of it and hope that it is different enough that
it doesn't upset the person who I'm imitating.
effectively, this prevents them from taking any action, as well (as I
understand it) any other parties they may have potentially "stolen"
from (legally, it is their fault in this case).


however, if it is something like a warez site, then the above likely
doesn't hold (they can't offer any sort of legal protection as they
are, by definition, illegal).

it is much like, people are free to buy and sell stuff, but they may
still be legally accountable for knowingly buying and selling stolen
property (this is also why places like pawn shops will turn away
things that they suspect are stolen).


granted, there are a lot of grey areas...

Thanks for your coments on this subject.
 
E

Eric Sosman

I'm curious to know the legalities involved in "borrowing" code without
paying for it.

Let me clarify. Let's say that I find some code snippets or even entire
classes, displayed on websites and that it would save me time and money
to use those classes in my own projects. This web site, www.java2s.com,
is just one of many such web sites on the Internet, as is the Java
Tutorial at the Oracle website.

Since that site says

Copyright 2009 - 12 Demo Source and Support.
All rights reserved.

.... I think you'd better check with them first.
 
D

Daniel Pitts

Ideally the code should already have been assigned a license and then
if you comply with that license then you are good.

With no license you have no right to use the cod.

I would agree that code posted at web sites, usenet groups
with the obvious intent to provide help for other users
has an implicit permissive license.

But how that would fly with the lawyers in court
that I do not know.
Actually, I somehow doubt that. First, code posted in public forums
isn't always owned by the person posting. Second, it is quite possible
that the code is intended to demonstrate a concept or technique, but
author of the code did not intend for the code to be copied verbatim.

IANAL, but from my experience with copyright, it seems that nothing
implicit matters, only what is made explicit. *except* fair-use.
 
R

Roedy Green

I'm curious to know the legalities involved in "borrowing" code without
paying for it.

I think anything that looks like teaching examples is fair game for
incorporation. Otherwise look for their policy. In general POSTED
code is fair game. Downloaded code is likely to have restrictions.

Everything on my site, including docs, is for non-military use only.
 
A

Arne Vajhøj

I think anything that looks like teaching examples is fair game for
incorporation. Otherwise look for their policy. In general POSTED
code is fair game. Downloaded code is likely to have restrictions.

I would expect the difference between inline and download code to
be more about number of files and size than about permission.
Everything on my site, including docs, is for non-military use only.

So your site is not fair game for incorporation.

Arne
 
G

Gene Wirchenko

I think anything that looks like teaching examples is fair game for
incorporation. Otherwise look for their policy. In general POSTED
code is fair game. Downloaded code is likely to have restrictions.

Everything on my site, including docs, is for non-military use only.

What if I write an app using some of your code, and someone buys
it and puts it to military use?

As I recall from an article when I was still living in Vancouver
(in "The Computer Paper", I think), you had trouble enforcing your
limitation. How did that end up going?

Sincerely,

Gene Wirchenko
 
G

Gene Wirchenko

I think anything that looks like teaching examples is fair game for
incorporation. Otherwise look for their policy. In general POSTED
code is fair game. Downloaded code is likely to have restrictions.

Everything on my site, including docs, is for non-military use only.

What if I write an app using some of your code, and someone buys
it and puts it to military use?

As I recall from an article when I was still living in Vancouver
(in "The Computer Paper", I think), you had trouble enforcing your
limitation. How did that end up going?

Sincerely,

Gene Wirchenko
 
B

BGB

I think anything that looks like teaching examples is fair game for
incorporation. Otherwise look for their policy. In general POSTED
code is fair game. Downloaded code is likely to have restrictions.

Everything on my site, including docs, is for non-military use only.

in my case, a lot of my code is currently MIT licensed.

some of my other code is "free for non-commercial use" (no, this is not
due to dislike of commercial software, rather it is for sake of leaving
myself as the only person who can currently directly profit off of it).

I had considered wanting to clarify it (there are some forms of
commercial use I am ok with), but I couldn't find any clear or concise
way to define them.

not that it really matters, as for now my server is down (and will be so
for a while), so no one can get or use any of it anyways.


or such...
 
L

Lew

I agree with this.

I also think that someone posting tutorial material that is
freely available on the Web can be presumed to be making it freely
available for use. Otherwise, what is the point of the tutorial? An
explicit copyright statement with the code would trump that though.

It's too strong a conclusion, "freely" available. A tutorial's code very
reasonably could be licensed only for personal use in service of learning the
material in the tutorial. Presence in a tutorial is not presumptive evidence
that code is licensed freely or in the public domain.

Regardless of our assumptions, the law is what prevails. In the U.S., the law
does not require a copyright notice for there to be an enforceable copyright.

So while you may presume anything you want, presumptions not being things that
require or benefit from evidence, that presumptuousness can lead you into
trouble. The law will still hold you to account, and that trumps all
presumption.

It's safer to assume, assumptions being things that can benefit from evidence.
In the case of U.S. copyright law, the safe assumption is that the material is
copyright, that the rights are restricted, and that you may not disseminate that expression beyond the boundaries of fair use, absent affirmative evidence
otherwise.

That's also a safe conclusion. Conclusions are things that require evidence.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

borrowing Constants 22
Can't understand code 2
Code efficiency 3
AttributeError in pygame code 4
Problem with code 2
Age gate code 0
Help with code 0
Who are low code solutions designed for? 1

Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top