Internet Draft                                                     T. Wu
draft-wu-telnet-auth-srp-01.txt                      Stanford University
Expires 31 September 1998                                     March 1998


                       Telnet Authentication: SRP

Status of this Memo

     This document is an Internet-Draft.  Internet-Drafts are working
     documents of the Internet Engineering Task Force (IETF), its
     areas, and its working groups.  Note that other groups may also
     distribute working documents as Internet-Drafts.

     Internet-Drafts are draft documents valid for a maximum of six
     months and may be updated, replaced, or obsoleted by other
     documents at any time.  It is inappropriate to use Internet-
     Drafts as reference material or to cite them other than as
     "work in progress."

     To view the entire list of current Internet-Drafts, please check
     the "1id-abstracts.txt" listing contained in the Internet-Drafts
     Shadow Directories on ftp.is.co.za (Africa), ftp.nordu.net
     (Northern Europe), ftp.nis.garr.it (Southern Europe), munnari.oz.au
     (Pacific Rim), ftp.ietf.org (US East Coast), or ftp.isi.edu
     (US West Coast).

Abstract

   This document specifies an authentication scheme for the Telnet
   protocol under the framework described in RFC 1416, using the
   SRP authentication mechanism.  The specific mechanism, SRP-SHA1,
   is described in [SRP-DRAFT].

1. Command Names and Codes

   Authentication Types

      SRP          5

   Suboption Commands

      AUTH         0
      REJECT       1
      ACCEPT       2
      CHALLENGE    3
      RESPONSE     4

      EXP          8
      PARAMS       9


draft-wu-telnet-auth-srp-01.txt                                 [Page 2]


2. Command Meanings

   IAC SB AUTHENTICATION IS <authentication-type-pair> AUTH IAC SE

      This command indicates that the client has supplied the
      username and is ready to receive that user's field parameters.
      There is no authentication information to be sent to the remote
      side of the connection yet.  This should only be sent after the
      IAC SB AUTHENTICATION NAME command has been issued.

   IAC SB AUTHENTICATION REPLY <authentication-type-pair> PARAMS
   <values of modulus, generator, and salt> IAC SE

      This command is used to pass the three parameter values used
      in the exponentiation to the client.  These values are often
      called n, g, and s.

   IAC SB AUTHENTICATION IS <authentication-type-pair> EXP
   <client's exponential residue> IAC SE

      This command is used to pass the client's exponential residue,
      otherwise known as A, computed against the parameters exchanged
      earlier.

   IAC SB AUTHENTICATION REPLY <authentication-type-pair> CHALLENGE
   <server's exponential residue> IAC SE

      This command is used to pass the server's exponential residue,
      computed against the same parameters.  This quantity is actually
      the sum of two residues, i.e. g^x + g^b.  For details see [SRP]
      and [SRP-DRAFT].

   IAC SB AUTHENTICATION IS <authentication-type-pair> RESPONSE
   <response from client> IAC SE

      This command gives the server proof of the client's authenticity
      with a 160-bit (20 byte) response.

   IAC SB AUTHENTICATION REPLY <authentication-type-pair> ACCEPT
   <server's response> IAC SE

      This command indicates that the authentication was successful.
      The server will construct its own proof of authenticity and
      include it as sub-option data.

   IAC SB AUTHENTICATION REPLY <authentication-type-pair> REJECT
   <optional reason for rejection> IAC SE

      This command indicates that the authentication was not successful,
      and if there is any more data in the sub-option, it is an ASCII
      text message of the reason for the rejection.


draft-wu-telnet-auth-srp-01.txt                                 [Page 3]


   For the PARAMS command, since three pieces of data are being
   transmitted, each parameter is preceded by a 16-bit (two byte)
   length specifier in network byte order.  The EXP commands do not have
   a count in front of the data because there is only one piece of data
   in that suboption.  The CHALLENGE, RESPONSE, and ACCEPT data also
   do not have a count because they are all fixed in size.


3. Implementation Rules

   Currently, only AUTH_CLIENT_TO_SERVER mode is supported.
   Although the SRP protocol effectively performs implicit mutual
   authentication as a result of the two-way proofs, only the
   AUTH_HOW_ONE_WAY authentication mode is currently defined.
   The AUTH_HOW_MUTUAL setting is being reserved for an explicit
   mutual-authentication variant of the SRP protocol to be defined
   in future specifications.

   All large number data sent in the arguments of the PARAMS and
   EXP commands must be in network byte order, i.e. most significant
   byte first.  No padding is used.

   The SRP-SHA1 mechanism, as described in [SRP-DRAFT] generates a
   40-byte session key, which is much longer than the 8-byte key
   generated by conventional authentication mechanisms like
   Kerberos [KERBEROS-AUTH].  This allows implementations to
   use different keys for incoming and outgoing traffic,
   increasing the security of the encrypted session.

4. Examples

   User "tjw" may wish to log in on machine "foo".  The client would
   send IAC SB AUTHENTICATION NAME "tjw" IAC SE IAC SB AUTHENTICATION
   IS SRP AUTH IAC SE.  The server would look up the field and salt
   parameters for "tjw" from its password file and send them back
   to the client.  Client and server would then exchange exponential
   residues and calculate their session keys (after the client prompted
   "tjw" for his password).  Then, the client would send the server
   its proof that it knows the session key.  The server would either
   send back an ACCEPT or a REJECT.  If the server accepts
   authentication, it also sends its own proof that it knows the
   session key to the client.


draft-wu-telnet-auth-srp-01.txt                                 [Page 4]


       Client                           Server
                                        IAC DO AUTHENTICATION
       IAC WILL AUTHENTICATION
       [ The server is now free to request authentication information.
         ]
                                        IAC SB AUTHENTICATION SEND
                                        SRP CLIENT|ONE_WAY IAC SE
       [ The server has requested SRP authentication.  This is the
         only mode currently supported.
         The client will now respond with the name of the user that it
         wants to log in as.  ]
       IAC SB AUTHENTICATION NAME
       "tjw" IAC SE
       IAC SB AUTHENTICATION IS
       SRP CLIENT|ONE_WAY AUTH
       IAC SE
       [ The server looks up the appropriate information for "tjw" and
         sends back the parameters in a PARAMS command. ]
                                        IAC SB AUTHENTICATION REPLY
                                        SRP CLIENT|ONE_WAY PARAMS
                                        ss ss nn nn nn nn ...
                                        ss ss gg gg gg gg ...
                                        ss ss tt tt tt tt ...
                                        IAC SE
       [ Both sides send their exponential residues.  In SRP-3,
         the CHALLENGE message may be computed but not sent before
         the EXP command. ]
       IAC SB AUTHENTICATION IS
       SRP CLIENT|ONE_WAY EXP
       aa aa aa aa aa aa aa aa ...
       IAC SE
                                        IAC SB AUTHENTICATION REPLY
                                        SRP CLIENT|ONE_WAY CHALLENGE
                                        bb bb bb bb bb bb bb bb ...
                                        IAC SE

       [ The client sends its response to the server. ]
       IAC SB AUTHENTICATION IS
       SRP CLIENT|ONE_WAY RESPONSE
       xx xx xx xx xx xx xx xx ...
       IAC SE
       [ The server accepts the response and sends its own proof. ]
                                        IAC SB AUTHENTICATION REPLY
                                        SRP CLIENT|ONE_WAY ACCEPT
                                        yy yy yy yy yy yy yy yy ...
                                        IAC SE


draft-wu-telnet-auth-srp-01.txt                                 [Page 5]

5. Security Considerations

   The ability to negotiate a common authentication mechanism between
   client and server is a feature of the authentication option that
   should be used with caution.  When the negotiation is performed, no
   authentication has yet occurred.  Therefore, each system has no way
   of knowing whether or not it is talking to the system it intends.  An
   intruder could attempt to negotiate the use of an authentication
   system which is either weak, or already compromised by the intruder.

   Since SRP relies on the security of the underlying public-key
   cryptosystem, the modulus "n" should be large enough to resist
   brute-force attack.  A length of at least 1024 bits is recommended,
   and implementations should reject attempts to use moduli that are
   shorter than 512 bits.

   Because SRP is believed to offer greater protection against
   intruders than previous Telnet authentication mechanisms, it is
   recommended that it be placed ahead of alternatives when negotiating
   a common authentication mechanism.  Some sites may wish to disable
   other weaker mechanisms completely for maximal security;
   implementations should permit this policy to be set easily on a
   site-by-site basis.

6. References

   [RFC1416]  D. Borman, "Telnet Authentication Option", RFC 1416,
              February 1993.

   [SRP]  T. Wu, "The Secure Remote Password Protocol", In Proceedings
          of the 1998 ISOC Network and Distributed System Security
          Symposium, San Diego, CA, pp. 97-111.

   [SRP-DRAFT]  T. Wu, "The SRP Authentication and Key Exchange System",
                draft-wu-srp-auth-XX.txt, Stanford University.

7. Author's Address

   Thomas Wu
   Stanford University
   Stanford, CA 94305
   EMail: tjw@cs.Stanford.EDU