Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Relationship between BSDs and AT&T Code #16

Open
atoponce opened this issue Oct 8, 2018 · 17 comments
Open

Relationship between BSDs and AT&T Code #16

atoponce opened this issue Oct 8, 2018 · 17 comments

Comments

@atoponce
Copy link
Contributor

atoponce commented Oct 8, 2018

I have some difficulties with the following paragraph (emphasis mine):

The term UNIX also debatedbly encompasses operating systems that are direct descendants of the original AT&T UNIX codebase but have since re-implemented the AT&T code with code under open source licenses. The most prominent of which the family of BSDs: FreeBSD, OpenBSD, and NetBSD, and their derivatives. These are not UNIX® certified, they are technically Unix-like, but share a unique direct link back to AT&T UNIX®, while newcomers like Redox OS do not.

I think there needs to be some clarification surrounding FreeBSD, OpenBSD, and NetBSD, and their connection to AT&T copyrighted Unix source code. I don't have all the answers, but my understanding is this, and I can submit a pull request when we have all the wrinkles ironed out.

  • NetBSD is based on BSD Net/2, which is 4.3BSD-Lite, released in June 1991. AT&T brought a lawsuit against Berkeley Software Design (BSDi), which prompted the BSD developers to fork the codebase into two branches- "Lite", which was sans AT&T code and "Encumbered" which contained AT&T code. Because NetBSD is based on code completely written from scratch, it isn't exactly "re-implemented" AT&T code "under open source licenses".
  • OpenBSD is a fork of NetBSD 1.0, released in October 1995, so it may need to be a nested item under NetBSD, rather than standing on its own. It also borrowed code heavily from 4.4BSD-Lite 1 and 4.4BSD-Lite 2, making it free of any encumbered AT&T code, where everything was written from scratch.
  • FreeBSD forked from the 386 BSD codebase, and released in December 1993, which in turn was based on BSD Net/2, like NetBSD. So it also would not qualify as "re-implemented" AT&T code "under open source licenses".

I would rewrite the phrase "but have since re-implemented the AT&T code with code under open source licenses" as "but have rewritten code from scratch, compatible with AT&T, released under open source licenses". I think that clarifies it a bit better.

@krytarowski
Copy link

FreeBSD is a fork of NetBSD 0.8 with applied custom patches that never landed NetBSD.

@krytarowski
Copy link

Also, modern BSDs are not a reimplementation/clones, but the original AT&T UNIX still in development, but without clobbering licensing issues any more.

@atoponce
Copy link
Contributor Author

atoponce commented Oct 8, 2018

FreeBSD is a fork of NetBSD 0.8 with applied custom patches that never landed NetBSD.

Not according to Wikipedia. They may have incorporated patches from NetBSD, but FreeBSD is a direct fork of 386BSD by Jolitz's. The UNIX timeline also confirms FreeBSD forked from 386BSD.

Also, modern BSDs are not a reimplementation/clones, but the original AT&T UNIX still in development, but without clobbering licensing issues any more.

That's where I disagree. They're as much the original AT&T Unix as Debian GNU/Linux is. Everything in the -Lite releases are free of any AT&T code. They're BSD systems written from scratch, just like GNU/Linux, Minix, and others.

AIX, HP/UX, Solaris, and Illumos are the only original AT&T Unix source code still in active development. Xinuos OpenServer 10, since being based on FreeBSD, like macOS etc., broke away from that code base as well.

@krytarowski
Copy link

krytarowski commented Oct 8, 2018

Not according to Wikipedia. They may have incorporated patches from NetBSD, but FreeBSD is a direct fork of 386BSD by Jolitz's. The UNIX timeline also confirms FreeBSD forked from 386BSD.

Majority of the code was indeed from 386BSD, but everything else (including putting it together, gathering floating patches) was from NetBSD. Also before the fork, primary developers of FreeBSD were developers of NetBSD.

I don't care what claims Wikipedia, I care what are the facts.

FreeBSD notes it here on a graph in its repository https://svnweb.freebsd.org/base/head/share/misc/bsd-family-tree?view=co

   *---------- 4.3BSD NET/2 -------------------+-------------*
   |                    |                      |             |
386BSD 0.0              |                      |           BSD/386 ALPHA
   |                    |                      |             |
386BSD 0.1 ------------>+                      |           BSD/386 0.3.[13]
   |     \              |                  4.4BSD Alpha      |
   |     386BSD 1.0     |                      |           BSD/386 0.9.[34]
   |                    |                  4.4BSD            |
   |                    |                    / |             |
   |                    |   4.4BSD-Encumbered  |             |
   |                -NetBSD 0.8                |           BSD/386 1.0
   |               /    |                      |             |
FreeBSD 1.0 <-----'  NetBSD 0.9                |           BSD/386 1.1
   |                    |           .----- 4.4BSD Lite       |
FreeBSD 1.1             |          /   /       |     \       |

Solaris is a fork/rework of SunOS, SunOS is an early fork of BSD, later BSD pulled code from SunOS etc. It was a crosspolling similar to current one between modern BSDs.

Modern BSDs track history sections back to AT&T 1-7 and later through the BSD line. If you check source code of AT&T for e.g. signal code, you can note that it resembles the current code in NetBSD (FreeBSD had deeper refactoring).

AT&T couldn't defend their proprietary rights to code changed so many times over so many years (e.g. VM subsystem was totally rewritten) except to a small number of files, that were removed in BSD Lite/2, that was a point to rebase NetBSD and FreeBSD patches. NetBSD 1.0 was free and it was a base for the OpenBSD fork.

@sirredbeard
Copy link
Owner

Perhaps we can check the Wikipedia sources and look for an independent source?

@sirredbeard sirredbeard changed the title Inaccurate phrasing Relationship between BSDs and AT&T Code Oct 8, 2018
@krytarowski
Copy link

GNU on the other hand was implementation from scratch, they needed 20 years to get usable and acceptable environment in serious usage, however they never got a widely accepted kernel and they are down to Linux.

BSD due to AT&T lawsuit lost almost a decade looking at the growing of Linux. Linus once claimed that if 386BSD would be available, he wouldn't start his kernel project.

Stating that GNU is like modern BSD is nicely said ignorance.

Disclaimer - I'm a BSD developer and a developer of few GNU projects (with paperwork done with FSF).

@atoponce
Copy link
Contributor Author

atoponce commented Oct 8, 2018

@krytarowski Even the SVN link you provided and the ASCII art shows that FreeBSD 1.0 is a 386BSD .01 fork/derivative, with borrowed source from NetBSD 0.8, as well as FreeBSD 2.0 borrowing source from 4.4BSD-Lite and FreeBSD 3.0 borrowing source code from 4.4BSD-Lite 2.

Regardless though, my point is that the BSDs are all based of source code written from scratch, and currently do not contain any licensed AT&T copyrighted source code. The code lineage is broken, so saying they "have since re-implemented the AT&T code" is slightly misleading, and should be cleaned up.

I do think though that OpenBSD should be listed as a NetBSD derivative. Or at least phrasing stating the fact, as OpenBSD forked very early in NetBSD's history, and has diverged significantly to the point that it certainly would qualify as standing on its own.

@sirredbeard
Copy link
Owner

I would be amenable to rephrasing "have since re-implemented the AT&T code" and generally adding some details about BSD 1991-1995.

I would also be amenable to noting OpenBSD forked from NetBSD, but because it is definitely it's own thing now I would like to keep in listed separately.

@krytarowski
Copy link

"source code written from scratch" as a general rule this is not true, it's an process patching the same sourcetree.

Similarly OpenSSH is a descendant of the original SSH project, but if they would care, they would easily drop the remaining (c) from the original code holders. This does not mean that it's a reimplementation from scratch. It's a similar situation that over so many years there were so many changes that it's basically a new project.

"with borrowed source from NetBSD 0.8", it is a fork of NetBSD-0.8, while the majority of the base was from 386BSD.

@sirredbeard sorry, but your resource is too much of rewriting the history in a way you 'like'. There are just too many gotchas that I think it's not worth the effort to keep correcting it..

@atoponce
Copy link
Contributor Author

atoponce commented Oct 8, 2018

@sirredbeard Fair enough.

@krytarowski OpenSSH never had any proprietary licensed SSH code. Their fork was from the last free version of SSH v1.2.12. After that, Tatu took the source proprietary, and OpenSSH forged on with their open implementation. Even in the LICENSE file, Tatu clearly states that the code is freely licensed, and can be used for any purpose. To compare it to previously proprietary licensed AT&T Unix source code that was rewritten to avoid the AT&T lawsuit is apples and oranges.

@krytarowski
Copy link

krytarowski commented Oct 8, 2018

It's a similar situation of descending from other project, just a different situation with licenses. The only difference is that OpenSSH does not need to formally break the 'linage' to prevent being sued.

In BSD the code linage with AT&T was never broken, it was nothing left to sue after removal of a marginal number of files in Lite/2. However strictly speaking, early BSDs (until 4.4BSD) were severely breaking the compatibility with earlier versions for various reasons, trying to support code from only 1 version behind. This helped to make some changes in a way that they were ready for the 64-bit CPU world in 90ties with e.g. breaking off_t type to be 64-bit always -- on Linux it's a total mess today as they keep using various integer types for it due to baggage of 32-bit world.

If you do not believe, start comparing the AT&T and BSD source trees rather than claiming something from Wikipedia.

While there GNU started many of their projects with clean room implementation (however it's still often a process of gluing of little bit reworked BSD code here and there, tagging it with GPL).

@krytarowski
Copy link

For your interest, there is an ongoing process of switching in NetBSD from BSD 4-clause license to 2-clause one. We are looking for older versions of some files without patches with BSD-4-clause code, sometimes reimplementing functionality or removing unneeded code. Typically we cannot do anything with a code with (c) that is not owned by The NetBSD Foundation.

If we follow your rationale, it's a process of reimplementing from scratch NetBSD with 2-clause license from an older version that is 4-clause one... and another 'linage breakage'!

@krytarowski
Copy link

krytarowski commented Oct 25, 2018

I've discussed this in person with Kirk McKusick about this issue of calling BSD as an reimplementation of UNIX.

In general this terminology is still acceptable and considered correct, however:

  • original UNIX was pulling back patches and code from BSD (similar to SunOS-BSD cross-pollination)
  • BSD was shared with people with license for the source code of AT&T UNIX
  • at BSD4.4-Lite2 point no AT&T UNIX license was needed any more

As a comparison, GNU:

  • was started with empty files and from scratch
  • never AT&T UNIX license was needed
  • formally no cross-pollination between original UNIX or other projects

And as mentioned above, NetBSD is being now in a process of reimplementation with BSD-2-clause license. A process analogous to the AT&T->BSD license and copyright movement, however nobody in the world would claim that NetBSD 2-clause is fundamentally a distinct project to NetBSD BSD-4-clause one.

Kirk McKusick prefers the terminology of BSD as 'derivation' of the original UNIX.

@dodona2
Copy link

dodona2 commented Oct 25, 2018

As a comparison, GNU:
* was started with empty files and from scratch

GNU is a license(falling more and more into disfavor), a set of tools(some say forked from the BSD tool chain) and a compiler done by cygnus/red hat. GNU never was capable producing a working kernel.

In contrast Linux was started with empty files and from scratch. Linux is not a license, it is a working kernel.

@krytarowski
Copy link

GNU is software or Operating System, GPL its license and FSF the foundation supporting it.

HURD is its formal kernel and it uses ifdef checks for __gnu__. In the past people were calling Linux distributions as GNU/Linux ones, however it's recently less and less popular. As an example, it's no longer used on a front page of the Debian project. In general kernel is the most important piece of the operating system and it defines the userland, and GNU is just a selection of userland utilities (nowadays being consumed by systemd).

GNU is still strong as a toolchain, however all the remaining parts are optional (or with alternatives) nowadays in Linux distributions.

@brunomaximom
Copy link

FreeBSD a fork of Net? What? Where are the references of that assumption?

@existful
Copy link

FreeBSD != NetBSD fork.

Code history and releases:
https://people.freebsd.org/~nbm/clug/history.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants
@atoponce @krytarowski @dodona2 @brunomaximom @sirredbeard @existful and others