diff --git a/contrib/opie/opie.4 b/contrib/opie/opie.4 index 3ac19324a39d..9db1755cf24c 100644 --- a/contrib/opie/opie.4 +++ b/contrib/opie/opie.4 @@ -1,340 +1,342 @@ .\" opie.4: Overview of the OPIE software. .\" .\" %%% portions-copyright-cmetz-96 .\" Portions of this software are Copyright 1996-1999 by Craig Metz, All Rights .\" Reserved. The Inner Net License Version 2 applies to these portions of .\" the software. .\" You should have received a copy of the license with this software. If .\" you didn't get a copy, you may request one from . .\" .\" Portions of this software are Copyright 1995 by Randall Atkinson and Dan .\" McDonald, All Rights Reserved. All Rights under this copyright are assigned .\" to the U.S. Naval Research Laboratory (NRL). The NRL Copyright Notice and .\" License Agreement applies to this software. .\" .\" History: .\" .\" Modified by cmetz for OPIE 2.4. Spelling fixes. .\" Modified by cmetz for OPIE 2.2. Removed MJR DES documentation. Removed .\" references to the old square brackets challenge delimiters. .\" Modified at NRL for OPIE 2.01. Updated UNIX trademark credit. .\" Definition of "seed" written by Neil Haller of Bellcore .\" Written at NRL for OPIE 2.0. .\" .\" $FreeBSD$ .\" .TH OPIE 4 "January 10, 1995" .SH NAME .B OPIE \- One-time Passwords In Everything +.SH DEPRECATION NOTICE +OPIE is deprecated, and may not be available in FreeBSD 14.0 and later. .SH DESCRIPTION .LP OPIE is a package derived from the Bellcore S/Key Version 1 distribution that helps to secure a system against replay attacks (see below). It does so using a secure hash function and a challenge/response system. It provides replacements for the .IR login (1), .IR su (1), and .IR ftpd (8) programs that use OPIE authentication as well as demonstrate how a program might be adapted to use OPIE authentication. OPIE was developed at and for the United States Naval Research Laboratory (NRL). OPIE is derived in part from Berkeley Standard Distribution UNIX and the Bellcore S/Key Version 1 distribution. .LP From the average user's perspective, OPIE is a nuisance that prevents their account from being broken into. The first time a user wishes to use OPIE, (s)he needs to use the .IR opiepasswd (1) command to put an entry for them into the OPIE database. The user can then use OPIE to authenticate themselves with any program that supports it. If no other clients are being used, this means they can use OPIE to .I telnet, .I rlogin, or .I ftp into the system, log in on a terminal port (like a modem), or switch to another user's account. When they would normally be asked for a password, they will get a challenge from the server. They then need to copy that challenge (or re-type, if they don't have the ability to copy and paste through something like a window system) to their calculator program, enter their password, then copy (or re-type) the response from the calculator as their password. While this will seem cumbersome at first, with some practice, it becomes easy. .SH TERMS .TP .I user name The name that the system knows you as. For example, "jdoe". .TP .I secret password A password, usually selected by the user, that is needed to gain access to the system. For example, "SEc1_rt". .TP .I challenge A packet of information output by a system when it wishes to authenticate a user. In OPIE, this is a three-item group consisting of a hash identifier, a sequence number, and a seed. This information is needed by the OPIE calculator to generate a proper response. For example, "otp-md5 95 wi14321". .TP .I response A packet of information generated from a challenge that is used by a system to authenticate a user. In OPIE, this is a group of six words that is generated by the calculator given the challenge and the secret password. For example, "PUP SOFT ROSE BIAS FLAG END". .TP .I seed A piece of information that is used in conjunction with the secret password and sequence number to compute the response. Its purpose is to allow the same secret password to be used for multiple sequences, by changing the seed, or for authentication to multiple machines by using different seeds. .TP .I sequence number A counter used to keep track of key iterations. In OPIE, each time a successful response is received by the system, the sequence number is decremented. For example, "95". .TP .I hash identifier A piece of text that identifies the actual algorithm that needs to be used to generate a proper response. In OPIE, the only two valid hash identifiers are "otp-md4", which selects MD4 hashing, and "otp-md5", which selects MD5. .SH REPLAY ATTACKS When you use a network terminal program like .IR telnet (1) or even use a modem to log into a computer system, you need a user name and a secret password. Anyone who can provide those to the system is recognized as you because, in theory, only you would have your secret password. Unfortunately, it is now easy to listen in on many computer communications media. From modem communication to many networks, your password is not usually safe over remote links. If a cracker can listen in when you send your password, (s)he then has a copy of your password that can be used at any time in the future to access your account. On more than one occasion, major sites on the Internet have been broken into exactly this way. .LP All an attacker has to do is capture your password once and then replay it to the server when it's asked for. Even if the password is communicated between machines in encoded or encrypted form, as long as a cracker can get in by simply replaying a previously captured communication, you are at risk. Up until very recently, Novell NetWare was vulnerable this way. A cracker couldn't find out what your password actually is, but (s)he didn't need to -- all that was necessary to get into your account was to capture the encrypted password and send that back to the server when asked for it. .SH ONE-TIME PASSWORDS One solution to the problem of replay attacks is to keep changing the way that a password is being encoded so that what is sent over the link to another system can only be used once. If you can do that, then a cracker can replay it as many times as (s)he wants -- it's just not going to get them anywhere. It's important, however, to make sure you encode the password in such a way that the cracker can't use the encoded version to figure out what the password is or what a future encoded password will be. Otherwise, while still an improvement over no encoding or a fixed encoding, you can still be broken into. .SH THE S/KEY ALGORITHM A solution to this whole problem was invented by Lamport in 1981. This technique was implemented by Haller, Karn, and Walden at Bellcore. They created a free software package called "S/Key" that used an algorithm called a cryptographic checksum. A cryptographic checksum is a strong one-way function such that, knowing the result of such a function, an attacker still cannot feasibly determine the input. Further, unlike cyclic redundancy checksums (CRCs), cryptographic checksums have few inputs that result in the same output. .LP In S/Key, what changes is the number of times the password is run through the secure hash. The password is run through the secure hash once, then the output of the hash is run through the secure hash again, that output is run through the secure hash again, and so on until the number of times the password has been run through the secure hash is equal to the desired sequence number. This is much slower than just, say, putting the sequence number in before the password and running that through the secure hash once, but it gains you one significant benefit. The server machine you are trying to connect to has to have some way to determine whether the output of that whole mess is right. If it stores it either without any encoding or with a normal encoding, a cracker could still get at your password. But if it stores it with a secure hash, then how does it account for the response changing every time because the sequence number is changing? Also what if you can never get to the machine any way that can't be listened in on? How do you change your password without sending it over the link? .LP The clever solution devised by Lamport is to keep in mind that the sequence number is always decrementing by one and that, in the S/Key system, simply by running any response with a sequence number N through the secure hash, you can get the response with a sequence number N+1, but you can't go the other way. At any given time, call the sequence number of the last valid response that the system got N+1 and the sequence number of the response you are giving it N. If the password that generated the response for N is the same as the one for N+1, then you should be able to run the response for N through the secure hash one more time, for a total of N+1 times, and get the same response as you got back for N+1. Once you compare the two and find that they are the same, you subtract one from N so that, now, the key for N that you just verified becomes the new key for N+1 that you can store away to use the next time you need to verify a key. This also means that if you need to change your password but don't have a secure way to access your machine, all the system really needs to have to verify your password is a valid response for one more than the sequence number you want to start with. .LP Just for good measure, each side of all of this uses a seed in conjunction with your password when it actually generates and verifies the responses. This helps to jumble things up a little bit more, just in case. Otherwise, someone with a lot of time and disk space on their hands could generate all the responses for a lot of frequent passwords and defeat the system. .LP This is not, by any means, the best explanation of how the S/Key algorithm works or some of the more minor details. For that, you should go to some of the papers now published on the topic. It is simply a quick-and-dirty introduction to what's going on under the hood. .SH OPIE COMPONENTS The OPIE distribution has been incorporated into three standard client programs: .IR login (1), .IR su (1), and .IR ftpd (8), .LP There are also three programs in the OPIE distribution that are specific to the OPIE system: .IR opiepasswd (1), which allows a user to set and change their OPIE password, .IR opieinfo (1), which allows a user to find out what their current sequence number and seed are, and .IR opiekey(1), which is an OPIE key calculator. .SH ADDING OPIE TO OTHER PROGRAMS Adding OPIE authentication to programs other than the ones included as clients in the OPIE distribution isn't very difficult. First, you will need to make sure that the program includes somewhere. Then, below the other includes such as , but before variable declarations, you need to include . You need to add a variable of type "struct opie" to your program, you need to make sure that the buffer that you use to get a password from the user is big enough to hold OPIE_RESPONSE_MAX+1 characters, and you need to have a buffer in which to store the challenge string that is big enough to hold OPIE_CHALLENGE_MAX+1 characters. .LP When you are ready to output the challenge string and know the user's name, you would use a call to opiechallenge. Later, to verify the response received, you would use a call to opieverify. For example: .sp 0 .sp 0 #include .sp 0 . .sp 0 . .sp 0 #include .sp 0 . .sp 0 . .sp 0 char *user_name; .sp 0 /* Always remember the trailing null! */ .sp 0 char password[OPIE_RESPONSE_MAX+1]; .sp 0 . .sp 0 . .sp 0 struct opie opiedata; .sp 0 char opieprompt[OPIE_CHALLENGE_MAX+1]; .sp 0 . .sp 0 . .sp 0 opiechallenge(&opiedata, user_name, opieprompt); .sp 0 . .sp 0 . .sp 0 if (opieverify(&opiedata, password)) { .sp 0 printf("Login incorrect"); .sp 0 .SH TERMINAL SECURITY AND OPIE When using OPIE, you need to be careful not to allow your password to be communicated over an insecure channel where someone might be able to listen in and capture it. OPIE can protect you against people who might get your password from snooping on the line, but only if you make sure that the password itself never gets sent over the line. The important thing is to always run the OPIE calculator on whichever machine you are actually using - never on a machine you are connected to by network or by dialup. .LP You need to be careful about the X Window System, because it changes things quite a bit. For instance, if you run an xterm (or your favorite equivalent) on another machine and display it on your machine, you should not run an OPIE calculator in that window. When you type in your secret password, it still gets transmitted over the network to go to the machine the xterm is running on. People with machines such as X terminals that can only run the calculator over the network are in an especially precarious position because they really have no choice. Also, with the X Window System, as with some other window system (NeWS as an example), it is sometimes possible for people to read your keystrokes and capture your password even if you are running the OPIE calculator on your local machine. You should always use the best security mechanism available on your system to protect your X server, be it XDM-AUTHORIZATION-1, XDM-MAGIC-COOKIE-1, or host access control. *Never* just allow any machine to connect to your server because, by doing so, you are allowing any machine to read any of your windows or your keystrokes without you knowing it. .SH SEE ALSO .BR ftpd (8) .BR login (1), .BR opie (4), .BR opiekeys (5), .BR opieaccess (5), .BR opiekey (1), .BR opieinfo (1), .BR opiepasswd (1), .sp Lamport, L. "Password Authentication with Insecure Communication", Communications of the ACM 24.11 (November 1981), pp. 770-772. .sp Haller, N. "The S/KEY One-Time Password System", Proceedings of the ISOC Symposium on Network and Distributed System Security, February 1994, San Diego, CA. .sp Haller, N. and Atkinson, R, "On Internet Authentication", RFC-1704, DDN Network Information Center, October 1994. .sp Rivest, R. "The MD5 Message Digest Algorithm", RFC-1321, DDN Network Information Center, April 1992. .sp Rivest, R. "The MD4 Message Digest Algorithm", RFC-1320, DDN Network Information Center, April 1992. .SH AUTHOR Bellcore's S/Key was written by Phil Karn, Neil M. Haller, and John S. Walden of Bellcore. OPIE was created at NRL by Randall Atkinson, Dan McDonald, and Craig Metz. S/Key is a trademark of Bell Communications Research (Bellcore). UNIX is a trademark of X/Open. .SH CONTACT OPIE is discussed on the Bellcore "S/Key Users" mailing list. To join, send an email request to: .sp skey-users-request@thumper.bellcore.com diff --git a/contrib/opie/opieaccess.5 b/contrib/opie/opieaccess.5 index 41b1ec0e03b7..00dc64745427 100644 --- a/contrib/opie/opieaccess.5 +++ b/contrib/opie/opieaccess.5 @@ -1,89 +1,92 @@ .\" opieaccess.5: Manual page describing the /etc/opieaccess file. .\" .\" Portions of this software are Copyright 1995 by Randall Atkinson and Dan .\" McDonald, All Rights Reserved. All Rights under this copyright are assigned .\" to the U.S. Naval Research Laboratory (NRL). The NRL Copyright Notice and .\" License Agreement applies to this software. .\" .\" History: .\" .\" Modified by cmetz for OPIE 2.4. Fixed "0PIE" typo. .\" Written at NRL for OPIE 2.0. .\" .ll 6i .pl 10.5i .\" @(#)opieaccess.5 2.0 (NRL) 1/10/95 .\" $FreeBSD$ .\" .lt 6.0i .TH OPIEACCESS 5 "January 10, 1995" .AT 3 .SH NAME /etc/opieaccess \- OPIE database of trusted networks +.SH DEPRECATION NOTICE +OPIE is deprecated, and may not be available in FreeBSD 14.0 and later. + .SH DESCRIPTION The .I opieaccess file contains a list of networks that are considered trusted by the system as far as security against passive attacks is concerned. Users from networks so trusted will be able to log in using OPIE responses, but not be required to do so, while users from networks that are not trusted will always be required to use OPIE responses (the default behavior). This trust allows a site to have a more gentle migration to OPIE by allowing it to be non-mandatory for "inside" networks while allowing users to choose whether they with to use OPIE to protect their passwords or not. .sp The entire notion of trust implemented in the .I opieaccess file is a major security hole because it opens your system back up to the same passive attacks that the OPIE system is designed to protect you against. The .I opieaccess support in this version of OPIE exists solely because we believe that it is better to have it so that users who don't want their accounts broken into can use OPIE than to have them prevented from doing so by users who don't want to use OPIE. In any environment, it should be considered a transition tool and not a permanent fixture. When it is not being used as a transition tool, a version of OPIE that has been built without support for the .I opieaccess file should be built to prevent the possibility of an attacker using this file as a means to circumvent the OPIE software. .sp The .I opieaccess file consists of lines containing three fields separated by spaces (tabs are properly interpreted, but spaces should be used instead) as follows: .PP .nf .ta \w' 'u Field Description action "permit" or "deny" non-OPIE logins address Address of the network to match mask Mask of the network to match .fi Subnets can be controlled by using the appropriate address and mask. Individual hosts can be controlled by using the appropriate address and a mask of 255.255.255.255. If no rules are matched, the default is to deny non-OPIE logins. .SH SEE ALSO .BR ftpd (8) .BR login (1), .BR opie (4), .BR opiekeys (5), .BR opiepasswd (1), .BR opieinfo (1), .BR su (1), .SH AUTHOR Bellcore's S/Key was written by Phil Karn, Neil M. Haller, and John S. Walden of Bellcore. OPIE was created at NRL by Randall Atkinson, Dan McDonald, and Craig Metz. S/Key is a trademark of Bell Communications Research (Bellcore). .SH CONTACT OPIE is discussed on the Bellcore "S/Key Users" mailing list. To join, send an email request to: .sp skey-users-request@thumper.bellcore.com diff --git a/contrib/opie/opieinfo.1 b/contrib/opie/opieinfo.1 index 41cdebe8dec4..5eb0a01ba43b 100644 --- a/contrib/opie/opieinfo.1 +++ b/contrib/opie/opieinfo.1 @@ -1,100 +1,103 @@ .\" opieinfo.1: Manual page for the opieinfo(1) program. .\" .\" %%% portions-copyright-cmetz-96 .\" Portions of this software are Copyright 1996-1999 by Craig Metz, All Rights .\" Reserved. The Inner Net License Version 2 applies to these portions of .\" the software. .\" You should have received a copy of the license with this software. If .\" you didn't get a copy, you may request one from . .\" .\" Portions of this software are Copyright 1995 by Randall Atkinson and Dan .\" McDonald, All Rights Reserved. All Rights under this copyright are assigned .\" to the U.S. Naval Research Laboratory (NRL). The NRL Copyright Notice and .\" License Agreement applies to this software. .\" .\" History: .\" .\" Modified by cmetz for OPIE 2.2. Removed MJR DES documentation. .\" Modified at NRL for OPIE 2.0. .\" Written at Bellcore for the S/Key Version 1 software distribution .\" (keyinfo.1). .\" .\" $FreeBSD$ .ll 6i .pl 10.5i .lt 6.0i .TH OPIEINFO 1 "January 10, 1995" .AT 3 .SH NAME opieinfo \- Extract sequence number and seed for future OPIE challenges. .SH SYNOPSIS .B opieinfo [\-v] [\-h] [ .I user_name ] +.SH DEPRECATION NOTICE +OPIE is deprecated, and may not be available in FreeBSD 14.0 and later. + .SH DESCRIPTION .I opieinfo takes an optional user name and writes the current sequence number and seed found in the OPIE key database for either the current user or the user specified. opiekey is compatible with the .IR keyinfo (1) program from Bellcore's S/Key Version 1 except that specification of a remote system name is not permitted. .sp .I opieinfo can be used to generate a listing of your future OPIE responses if you are going to be without an OPIE calculator and still need to log into the system. To do so, you would run something like: .sp .B opiekey \-n 42 `opieinfo` .SH OPTIONS .TP .B \-v Display the version number and compile-time options, then exit. .TP .B \-h Display a brief help message and exit. .TP .B The name of a user whose key information you wish to display. The default is the user running opieinfo. .SH EXAMPLE .sp 0 wintermute$ opieinfo .sp 0 495 wi01309 .sp 0 wintermute$ .LP .SH FILES .TP /etc/opiekeys -- database of key information for the OPIE system. .SH SEE ALSO .BR opie (4), .BR opiekey (1), .BR opiepasswd (1), .BR su (1), .BR login (1), .BR ftpd (8), .BR opiekeys (5) .BR opieaccess (5) .SH AUTHOR Bellcore's S/Key was written by Phil Karn, Neil M. Haller, and John S. Walden of Bellcore. OPIE was created at NRL by Randall Atkinson, Dan McDonald, and Craig Metz. S/Key is a trademark of Bell Communications Research (Bellcore). .SH CONTACT OPIE is discussed on the Bellcore "S/Key Users" mailing list. To join, send an email request to: .sp skey-users-request@thumper.bellcore.com diff --git a/contrib/opie/opiekey.1 b/contrib/opie/opiekey.1 index bc62b9460d90..d593ce169990 100644 --- a/contrib/opie/opiekey.1 +++ b/contrib/opie/opiekey.1 @@ -1,173 +1,176 @@ .\" opiekey.1: Manual page for the opiekey(1) program. .\" .\" %%% portions-copyright-cmetz-96 .\" Portions of this software are Copyright 1996-1999 by Craig Metz, All Rights .\" Reserved. The Inner Net License Version 2 applies to these portions of .\" the software. .\" You should have received a copy of the license with this software. If .\" you didn't get a copy, you may request one from . .\" .\" Portions of this software are Copyright 1995 by Randall Atkinson and Dan .\" McDonald, All Rights Reserved. All Rights under this copyright are assigned .\" to the U.S. Naval Research Laboratory (NRL). The NRL Copyright Notice and .\" License Agreement applies to this software. .\" .\" History: .\" .\" Modified by cmetz for OPIE 2.3. Added -t documentation. Removed .\" opie-bugs pointer. Removed opie-md5 and opie-md4 names. Fixed .\" a bolding bug. Added -f flag. Added escapes on flags. Minor .\" editorial changes. Updated example. .\" Modified by cmetz for OPIE 2.2. Removed MJR DES documentation. .\" Re-worded retype documentation. Added opiegen reference. .\" Added -x documentation. .\" Modified at NRL for OPIE 2.0. .\" Written at Bellcore for the S/Key Version 1 software distribution .\" (key.1). .\" .\" $FreeBSD$ .ll 6i .pl 10.5i .lt 6.0i .TH OPIEKEY 1 "February 20, 1996" .AT 3 .SH NAME opiekey, otp-md4, otp-md5 \- Programs for computing responses to OTP challenges. .SH SYNOPSIS .B opiekey | .B otp-md4 | .B otp-md5 [\-v] [\-h] [\-f] [\-x] .sp 0 [\-t .I type ] [\-4|\-5] [\-a] [\-n .I count ] .I sequence_number seed .sp 0 +.SH DEPRECATION NOTICE +OPIE is deprecated, and may not be available in FreeBSD 14.0 and later. + .SH DESCRIPTION .I opiekey takes the optional count of the number of responses to print along with a (maximum) sequence number and seed as command line args. It prompts for the user's secret pass phrase and produces an OPIE response as six words. If compiled to do so, it can prompt for the user's secret pass phrase twice to help reduce errors due to mistypes. The second password entry can be circumvented by entering only an end of line. .I opiekey is downward compatible with the .IR key (1) program from the Bellcore S/Key Version 1 distribution and several of its variants. .SH OPTIONS .TP .B \-v Display the version number and compile-time options, then exit. .TP .B \-h Display a brief help message and exit. .TP .B \-4, \-5 Selects MD4 or MD5, respectively, as the response generation algorithm. The default for otp-md4 is MD4 and the default for opie-md5 is MD5. The default for opiekey depends on compile-time configuration, but should be MD5. MD4 is compatible with the Bellcore S/Key Version 1 distribution. .TP .B \-f Force .I opiekey to continue, even where it normally shouldn't. This is currently used to force opiekey to operate in even from terminals it believes to be insecure. It can also allow users to disclose their secret pass phrases to attackers. Use of the -f flag may be disabled by compile-time option in your particular build of OPIE. .TP .B \-a Allows you to input an arbitrary secret pass phrase, instead of running checks against it. Arbitrary currently does not include '\\0' or '\\n' characters. This can be used for backwards compatibility with key generators that do not check passwords. .TP .B \-n the number of one time access passwords to print. The default is one. .TP .B \-x Output the OTPs as hexadecimal numbers instead of six words. .TP .B \-t Generate an extended response of the specified type. Supported types are: .sp 1 word six-word .sp 0 hex hexadecimal .sp 0 init hexadecimal re-initialization .sp 0 init-word six-word re-initialization .sp 1 The re-initialization responses .I always generate the simple active attack protection. .TP .SH EXAMPLE .sp 0 wintermute$ opiekey \-5 \-n 5 495 wi01309 .sp 0 Using MD5 algorithm to compute response. .sp 0 Reminder: Don't use opiekey from telnet or dial-in sessions. .sp 0 Enter secret pass phrase: .sp 0 491: HOST VET FOWL SEEK IOWA YAP .sp 0 492: JOB ARTS WERE FEAT TILE IBIS .sp 0 493: TRUE BRED JOEL USER HALT EBEN .sp 0 494: HOOD WED MOLT PAN FED RUBY .sp 0 495: SUB YAW BILE GLEE OWE NOR .sp 0 wintermute$ .LP .SH BUGS .BR opiekey(1) can lull a user into revealing his/her password when remotely logged in, thus defeating the purpose of OPIE. This is especially a problem with xterm. .BR opiekey(1) implements simple checks to reduce the risk of a user making this mistake. Better checks are needed. .LP .SH SEE ALSO .BR ftpd (8), .BR login (1), .BR opie (4), .BR opiepasswd (1), .BR opieinfo (1), .BR opiekeys (5), .BR opieaccess (5), .BR su (1) .SH AUTHOR Bellcore's S/Key was written by Phil Karn, Neil M. Haller, and John S. Walden of Bellcore. OPIE was created at NRL by Randall Atkinson, Dan McDonald, and Craig Metz. S/Key is a trademark of Bell Communications Research (Bellcore). .SH CONTACT OPIE is discussed on the Bellcore "S/Key Users" mailing list. To join, send an email request to: .sp skey-users-request@thumper.bellcore.com diff --git a/contrib/opie/opiekeys.5 b/contrib/opie/opiekeys.5 index 26f08ed06ff8..954d545f90c0 100644 --- a/contrib/opie/opiekeys.5 +++ b/contrib/opie/opiekeys.5 @@ -1,69 +1,72 @@ .\" opiekeys.5: Manual page describing the /etc/opiekeys file. .\" .\" Portions of this software are Copyright 1995 by Randall Atkinson and Dan .\" McDonald, All Rights Reserved. All Rights under this copyright are assigned .\" to the U.S. Naval Research Laboratory (NRL). The NRL Copyright Notice and .\" License Agreement applies to this software. .\" .\" History: .\" .\" Modified by cmetz for OPIE 2.32. This is opiekeys.5, not opiekeys.1 or .\" opieaccess.5. .\" Written at NRL for OPIE 2.0. .\" .ll 6i .pl 10.5i .\" @(#)opiekeys.5 2.0 (NRL) 1/10/95 .\" $FreeBSD$ .\" .lt 6.0i .TH OPIEKEYS 5 "January 10, 1995" .AT 3 .SH NAME /etc/opiekeys \- OPIE database of user key information +.SH DEPRECATION NOTICE +OPIE is deprecated, and may not be available in FreeBSD 14.0 and later. + .SH DESCRIPTION The .I opiekeys file contains user information used by the OPIE software to authenticate users. The .I opiekeys file is backwards compatible with the S/Key .I /etc/skeykeys database file, but only if the hashing algorithm (MD4 and MD5) is the same between S/Key and OPIE (i.e., MD5 OPIE cannot use MD4 S/Key keys). The .I opiekeys file consists of six fields separated by spaces (tabs are properly interpreted, but spaces should be used instead) as follows: .PP .nf .ta \w' 'u Field Description name User's login name. sequence User's sequence number. seed User's seed. key User's last response (hex). date Last change date. time Last change time. .fi .SH SEE ALSO .BR ftpd (8) .BR login (1), .BR opie (4), .BR opiekeys (5), .BR opiepasswd (1), .BR opieinfo (1), .BR su (1), .SH AUTHOR Bellcore's S/Key was written by Phil Karn, Neil M. Haller, and John S. Walden of Bellcore. OPIE was created at NRL by Randall Atkinson, Dan McDonald, and Craig Metz. S/Key is a trademark of Bell Communications Research (Bellcore). .SH CONTACT OPIE is discussed on the Bellcore "S/Key Users" mailing list. To join, send an email request to: .sp skey-users-request@thumper.bellcore.com diff --git a/contrib/opie/opiepasswd.1 b/contrib/opie/opiepasswd.1 index 5ce6cb010b4f..aa6fc5771e16 100644 --- a/contrib/opie/opiepasswd.1 +++ b/contrib/opie/opiepasswd.1 @@ -1,178 +1,181 @@ .\" opiepasswd.1: Manual page for the opiepasswd(1) program. .\" .\" %%% portions-copyright-cmetz-96 .\" Portions of this software are Copyright 1996-1999 by Craig Metz, All Rights .\" Reserved. The Inner Net License Version 2 applies to these portions of .\" the software. .\" You should have received a copy of the license with this software. If .\" you didn't get a copy, you may request one from . .\" .\" Portions of this software are Copyright 1995 by Randall Atkinson and Dan .\" McDonald, All Rights Reserved. All Rights under this copyright are assigned .\" to the U.S. Naval Research Laboratory (NRL). The NRL Copyright Notice and .\" License Agreement applies to this software. .\" .\" History: .\" .\" Modified by cmetz for OPIE 2.4. Fixed spelling bug. .\" Modified by cmetz for OPIE 2.3. Added -f flag documentation. .\" Updated console example. .\" Modified by cmetz for OPIE 2.2. Removed MJR DES documentation. .\" Modified at NRL for OPIE 2.0. .\" Written at Bellcore for the S/Key Version 1 software distribution .\" (keyinit.1). .\" .\" $FreeBSD$ .ll 6i .pl 10.5i .lt 6.0i .TH OPIEPASSWD 1 "January 10, 1995" .AT 3 .SH NAME opiepasswd \- Change or set a user's password for the OPIE authentication system. .SH SYNOPSIS .B opiepasswd [\-v] [\-h] [\-c|\-d] [\-f] .sp 0 [\-n .I initial_sequence_number ] [\-s .I seed ] [ .I user_name ] +.SH DEPRECATION NOTICE +OPIE is deprecated, and may not be available in FreeBSD 14.0 and later. + .SH DESCRIPTION .I opiepasswd will initialize the system information to allow one to use OPIE to login. .I opiepasswd is downward compatible with the keyinit(1) program from the Bellcore S/Key Version 1 distribution. .SH OPTIONS .TP .TP .B \-v Display the version number and compile-time options, then exit. .TP .B \-h Display a brief help message and exit. .TP .B \-c Set console mode where the user is expected to have secure access to the system. In console mode, you will be asked to input your password directly instead of having to use an OPIE calculator. If you do not have secure access to the system (i.e., you are not on the system's console), you are volunteering your password to attackers by using this mode. .TP .B \-d Disable OTP logins to the specified account. .TP .B \-f Force .I opiepasswd to continue, even where it normally shouldn't. This is currently used to force opiepasswd to operate in "console" mode even from terminals it believes to be insecure. It can also allow users to disclose their secret pass phrases to attackers. Use of the -f flag may be disabled by compile-time option in your particular build of OPIE. .TP .B \-n Manually specify the initial sequence number. The default is 499. .TP .B \-s Specify a non-random seed. The default is to generate a "random" seed using the first two characters of the host name and five pseudo-random digits. .SH EXAMPLE Using .I opiepasswd from the console: .LP .sp 0 wintermute$ opiepasswd \-c .sp 0 Updating kebe: .sp 0 Reminder \- Only use this method from the console; NEVER from remote. If you .sp 0 are using telnet, xterm, or a dial\-in, type ^C now or exit with no password. .sp 0 Then run opiepasswd without the \-c parameter. .sp 0 Using MD5 to compute responses. .sp 0 Enter old secret pass phrase: .sp 0 Enter new secret pass phrase: .sp 0 Again new secret pass phrase: .sp 0 .sp 0 ID kebe OPIE key is 499 be93564 .sp 0 CITE JAN GORY BELA GET ABED .sp 0 wintermute$ .LP Using .I opiepasswd from remote: .LP .sp 0 wintermute$ opiepasswd .sp 0 Updating kebe: .sp 0 Reminder: You need the response from your OPIE calculator. .sp 0 Old secret password: .sp 0 otp-md5 482 wi93563 .sp 0 Response: FIRM BERN THEE DUCK MANN AWAY .sp 0 New secret password: .sp 0 otp-md5 499 wi93564 .sp 0 Response: SKY FAN BUG HUFF GUS BEAT .sp 0 .sp 0 ID kebe OPIE key is 499 wi93564 .sp 0 SKY FAN BUG HUFF GUS BEAT .sp 0 wintermute$ .LP .SH FILES .TP /etc/opiekeys -- database of key information for the OPIE system. .SH SEE ALSO .BR ftpd (8), .BR login (1), .BR passwd (1), .BR opie (4), .BR opiekey (1), .BR opieinfo (1), .BR su (1), .BR opiekeys (5), .BR opieaccess (5) .SH AUTHOR Bellcore's S/Key was written by Phil Karn, Neil M. Haller, and John S. Walden of Bellcore. OPIE was created at NRL by Randall Atkinson, Dan McDonald, and Craig Metz. S/Key is a trademark of Bell Communications Research (Bellcore). .SH CONTACT OPIE is discussed on the Bellcore "S/Key Users" mailing list. To join, send an email request to: .sp skey-users-request@thumper.bellcore.com diff --git a/lib/libpam/modules/pam_opie/pam_opie.8 b/lib/libpam/modules/pam_opie/pam_opie.8 index 968985a6c9f6..0b4cae1c4195 100644 --- a/lib/libpam/modules/pam_opie/pam_opie.8 +++ b/lib/libpam/modules/pam_opie/pam_opie.8 @@ -1,123 +1,127 @@ .\" Copyright (c) 2001 Mark R V Murray .\" All rights reserved. .\" Copyright (c) 2002 Networks Associates Technology, Inc. .\" All rights reserved. .\" .\" Portions of this software were developed for the FreeBSD Project by .\" ThinkSec AS and NAI Labs, the Security Research Division of Network .\" Associates, Inc. under DARPA/SPAWAR contract N66001-01-C-8035 .\" ("CBOSS"), as part of the DARPA CHATS research program. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. The name of the author may not be used to endorse or promote .\" products derived from this software without specific prior written .\" permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" $FreeBSD$ .\" -.Dd July 7, 2001 +.Dd September 15, 2022 .Dt PAM_OPIE 8 .Os .Sh NAME .Nm pam_opie .Nd OPIE PAM module .Sh SYNOPSIS .Op Ar service-name .Ar module-type .Ar control-flag .Pa pam_opie .Op Ar options +.Sh DEPRECATION NOTICE +OPIE is deprecated, and may not be available in +.Fx 14.0 +and later. .Sh DESCRIPTION The OPIE authentication service module for PAM, .Nm provides functionality for only one PAM category: that of authentication. In terms of the .Ar module-type parameter, this is the .Dq Li auth feature. It also provides a null function for session management. .Pp Note that this module does not enforce .Xr opieaccess 5 checks. There is a separate module, .Xr pam_opieaccess 8 , for this purpose. .Ss OPIE Authentication Module The OPIE authentication component provides functions to verify the identity of a user .Pq Fn pam_sm_authenticate , which obtains the relevant .Xr opie 4 credentials. It provides the user with an OPIE challenge, and verifies that this is correct with .Xr opiechallenge 3 . .Pp The following options may be passed to the authentication module: .Bl -tag -width ".Cm auth_as_self" .It Cm debug .Xr syslog 3 debugging information at .Dv LOG_DEBUG level. .It Cm auth_as_self This option will require the user to authenticate himself as the user given by .Xr getlogin 2 , not as the account they are attempting to access. This is primarily for services like .Xr su 1 , where the user's ability to retype their own password might be deemed sufficient. .It Cm no_fake_prompts Do not generate fake challenges for users who do not have an OPIE key. Note that this can leak information to a hypothetical attacker about who uses OPIE and who does not, but it can be useful on systems where some users want to use OPIE but most do not. .El .Pp Note that .Nm ignores the standard options .Cm try_first_pass and .Cm use_first_pass , since a challenge must be generated before the user can submit a valid response. .Sh FILES .Bl -tag -width ".Pa /etc/opiekeys" -compact .It Pa /etc/opiekeys default OPIE password database. .El .Sh SEE ALSO .Xr passwd 1 , .Xr getlogin 2 , .Xr opiechallenge 3 , .Xr syslog 3 , .Xr opie 4 , .Xr pam.conf 5 , .Xr pam 8 diff --git a/lib/libpam/modules/pam_opieaccess/pam_opieaccess.8 b/lib/libpam/modules/pam_opieaccess/pam_opieaccess.8 index 5521a85d1d44..87d901187ee9 100644 --- a/lib/libpam/modules/pam_opieaccess/pam_opieaccess.8 +++ b/lib/libpam/modules/pam_opieaccess/pam_opieaccess.8 @@ -1,142 +1,146 @@ .\" Copyright (c) 2001 Mark R V Murray .\" All rights reserved. .\" Copyright (c) 2002 Networks Associates Technology, Inc. .\" All rights reserved. .\" .\" Portions of this software were developed for the FreeBSD Project by .\" ThinkSec AS and NAI Labs, the Security Research Division of Network .\" Associates, Inc. under DARPA/SPAWAR contract N66001-01-C-8035 .\" ("CBOSS"), as part of the DARPA CHATS research program. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. The name of the author may not be used to endorse or promote .\" products derived from this software without specific prior written .\" permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" $FreeBSD$ .\" -.Dd October 26, 2007 +.Dd September 15, 2022 .Dt PAM_OPIEACCESS 8 .Os .Sh NAME .Nm pam_opieaccess .Nd OPIEAccess PAM module .Sh SYNOPSIS .Op Ar service-name .Ar module-type .Ar control-flag .Pa pam_opieaccess .Op Ar options +.Sh DEPRECATION NOTICE +OPIE is deprecated, and may not be available in +.Fx 14.0 +and later. .Sh DESCRIPTION The .Nm module is used in conjunction with the .Xr pam_opie 8 PAM module to ascertain that authentication can proceed by other means (such as the .Xr pam_unix 8 module) even if OPIE authentication failed. To properly use this module, .Xr pam_opie 8 should be marked .Dq Li sufficient , and .Nm should be listed right below it and marked .Dq Li requisite . .Pp The .Nm module provides functionality for only one PAM category: authentication. In terms of the .Ar module-type parameter, this is the .Dq Li auth feature. It also provides null functions for the remaining module types. .Ss OPIEAccess Authentication Module The authentication component .Pq Fn pam_sm_authenticate , returns .Dv PAM_SUCCESS in two cases: .Bl -enum .It The user does not have OPIE enabled. .It The user has OPIE enabled, and the remote host is listed as a trusted host in .Pa /etc/opieaccess , and the user does not have a file named .Pa \&.opiealways in his home directory. .El .Pp Otherwise, it returns .Dv PAM_AUTH_ERR . .Pp The following options may be passed to the authentication module: .Bl -tag -width ".Cm allow_local" .It Cm allow_local Normally, local logins are subjected to the same restrictions as remote logins from .Dq localhost . This option causes .Nm to always allow local logins. .It Cm debug .Xr syslog 3 debugging information at .Dv LOG_DEBUG level. .It Cm no_warn suppress warning messages to the user. These messages include reasons why the user's authentication attempt was declined. .El .Sh FILES .Bl -tag -width ".Pa $HOME/.opiealways" .It Pa /etc/opieaccess List of trusted hosts or networks. See .Xr opieaccess 5 for a description of its syntax. .It Pa $HOME/.opiealways The presence of this file makes OPIE mandatory for the user. .El .Sh SEE ALSO .Xr opie 4 , .Xr opieaccess 5 , .Xr pam.conf 5 , .Xr pam 8 , .Xr pam_opie 8 .Sh AUTHORS The .Nm module and this manual page were developed for the .Fx Project by ThinkSec AS and NAI Labs, the Security Research Division of Network Associates, Inc.\& under DARPA/SPAWAR contract N66001-01-C-8035 .Pq Dq CBOSS , as part of the DARPA CHATS research program.