The Surreal Horror of Pam
So the fact that PAM was adopted by Linux is mostly my fault.   I was the tech lead for Kerberos at MIT, and in 1995 I was visiting Sun to discuss how kerberos might be included in Solaris.  One of the technical discussions that we had was that each time people wanted to add support for various new large scale distributed infrastructures, whether it was Yellow Pages, or Hesiod (YP&#x27;s rough equivalent developed at MIT Project Athena), or OpenLDAP, or Kerberos, or when we wanted to automatically mount the user&#x27;s home directory, either using NFS as in Sun, or creating a temporary home directory, or creating a symlink into AFS and then getting AFS tokens, etc. we had to keep on modifying the sources for &#x2F;bin&#x2F;login.   And this was a positive drag.   Basically each large scale site was editing the source code for &#x2F;bin&#x2F;login and there was a private customized copy of login at MIT Project Athena, CMU Project Andrew, various US National Labs, yadda, yadda, yadda.<p>This was how things were done before PAM, and it presumed that you could twist the arms of the proprietary Unix vendors hard enough that they would give you to the source to &#x2F;bin&#x2F;login, which of course back then was encumbered by the AT&amp;T Unix license, which means you needed to pay AT&amp;T to get a Source License before you went back to twisting the arms of the proprietary Unix vendor.   And if you had a multi-vendor deployment, you might need to separately customize the &#x2F;bin&#x2F;login for OSF&#x2F;1, Solaris, AIX, HP&#x2F;UX, AUX, and Irix for your large scale deployment --- since all of the proprietary Unix vendors had added their own, incompatible, &quot;value adds&quot; to the OS.   Yelch!<p>The Solaris developers told me about this cool library called Pluggable Authentication Modules which they had been working on, and it was clear to me that this was the answer we were looking for.  No longer would each site need to hand edit C code to customize what was supposed to happen vis-a-vis using the user&#x27;s password to get Kerberos tickets, or get AFS tokens, and what might be needed for session startup such as site-specific ways of attaching the user&#x27;s home directory.<p>So I took the idea back from the Bay Area, and I started talking to folks in the Linux community and said, <i>this</i> is the answer to allow us to be able to distribute advanced systems such as Yellow Pages, Kerberos, OpenAFS, etc., and when the user installs the right packages we can automatically make &#x2F;bin&#x2F;login do the right thing.  Huzzah!    Michael K. Johnson at Red Hat and I managed to recruit Andrew Morgan to be the maintainer of Linux-PAM, and it started shipping in Linux distributions in 1996.  (Red Hat Linux 3.0.4, shipped in August 1996 had PAM support --- note, this is RHL 3.0.4 which is <i>not</i> RHEL 3.  Red Hat Linux predated Red Hat Enterprise Linux.)<p>Although we did a clean-room reimplementation of the PAM spec, using only the man pages which the Solaris developers had provided to me, it started shipping in Linux distributions <i>before</i> Sun managed to ship their implementation of PAM in Solaris in 1997, even though they developed the spec and had a prototype before we had even started coding.<p>So the history in Christine&#x27;s talk isn&#x27;t quite right.  PAM was not developed because of the existence of SSH.  It&#x27;s true that SSH was first written in 1995 as well, and the fact that it made it easier to integrate SSH was a bonus, but the primary concern that I (as a Linux developer and Kerberos Tech Lead) and Sun was most interested in was how to avoid custom, site-specific customized versions of &#x2F;bin&#x2F;login so we could more easily promote adoption of new technologies like Kerberos without requiring the site administrator be able to modify &#x2F;bin&#x2F;login, or having a combinatorial explosion of different &#x2F;bin&#x2F;logins for all of the different distributed computing systems which needed changes to &#x2F;bin&#x2F;login.<p>Oh, and Java was released as a Beta in 1995.  The reason why PAM modules wasn&#x27;t written in Java was because (a) it would have been insane to use something the size of a JVM for a critical system program like &#x2F;bin&#x2F;login, and (b) Sun Microsystems&#x27; marketing arm hadn&#x27;t yet started promoting Java like crazy promising &quot;write once, run^H^H^H^H debug everywhere&quot;, and claiming that Java was the right answer no matter what the question was.  Also, (c) I believe that the Solaris engineers, for whom I have immense respect, had way more good taste than that.  :-)