home *** CD-ROM | disk | FTP | other *** search
/ Il CD di internet / CD.iso / SOURCE / N / DIP / _DIP.TAR / usr / doc / dip / README.SKEY < prev    next >
Encoding:
Internet Message Format  |  1995-01-13  |  4.1 KB

  1. From: Stephen Shortland <stephen@cork.cig.mot.com>
  2. Date: Sun, 5 Jun 1994 14:00:04 +0100
  3. To: uri@watson.ibm.com
  4. Subject: DIP S/Key updates
  5.  
  6. As promised, here are the diffs to 'bolt' S/Key onto dip-3.3.7b. The
  7. modifications were very straight forward, as you can see from the
  8. diffs. The diffs are against clean dip337b-uri. The earlier password
  9. diffs that I sent you are included in these diffs, so you can ignore
  10. my previous patch.
  11.  
  12. To compile dip with S/Key support you will need to the skey-linux-1.1b
  13. package. You can get this from sunsite.unc.edu (the path is given in
  14. the makefile). Compile this package to give you libskey.a, which
  15. should be placed in /usr/bin or the dip directory. You only need
  16. libskey.a to re-compile dip - binary dists of dip will not need it.
  17.  
  18. The S/Key support comes in two halves:
  19.  
  20. DIP
  21. ===
  22. There is a new command for dip scripts:
  23.     
  24.     skey [timeout]
  25.  
  26. This tells dip to look for an S/Key challenge from the server. The
  27. challenge looks like:
  28.  
  29.     [s/key 98 tu12345]
  30.  
  31. Once it has found the challenge it prompts the user for their secret
  32. password. It then uses the password, seed (tu12345) and challenge
  33. number (98) to generate a response, with it sends to the server. The
  34. user doesn't have to type in the 6 word S/Key response - it is all
  35. done automatically.
  36.  
  37. The optional timeout parameter sets how long dip is to wait to see the
  38. challenge. errlvl is set to 1 if skey timesout. If skey successfully
  39. sends a response, errlvl is set to 0.
  40.  
  41. A sample of a dip script using skey is given below. This is for two
  42. directly connected machines, and error handling has been removed for
  43. brevity. There is no regular password on the slip account - it uses
  44. S/Key authentication only.
  45.  
  46.     port cua0
  47.     speed 38400
  48.     
  49.     send \r
  50.     wait login:
  51.     send slip\r
  52.  
  53.     skey 30
  54.  
  55.     get $local remote
  56.     get $remote remote
  57.     get $mtu 296
  58.  
  59.     default
  60.     mode CSLIP
  61.  
  62.  
  63. DIPLOGIN
  64. ========
  65. When a user logs in, diplogin checks their password field in diphosts.
  66. If this field is set to "s/key", diplogin will issue an S/Key challenge
  67. and wait for a response. If the user does not have S/Key
  68. authentication info in /etc/skeykeys, or if their response to the
  69. challenge is incorrect, the login session is terminated and an error
  70. is logged with syslog.
  71.  
  72. If the passwd field from diphosts does not contain "s/key" diplogin
  73. works as it did before - i.e. no password checking is done.
  74.  
  75. Below is a sample of an S/Key authenticated entry from /etc/diphosts:
  76.  
  77.     slip:s/key:gate:tuin:255.255.255.0:SLIP test:CSLIP,296
  78.  
  79. If you want to use S/Key authentication in diplogin, then diplogin
  80. will have to run as root, so that it can update /etc/skeykeys after a
  81. successful login. [I think that diplogin already has to run as root,
  82. so that it can configure the interface and routing tables]. This means
  83. that diplogin has to run suid root, which is not a good idea, as
  84. diplogin is not a secure program (reasons why are left as an exercise
  85. to the reader :-). An alternative, if you use getty_ps is to make
  86. diplogin the login program for a particular port. The advantage with
  87. this is that diplogin does not have to be suid, but the disadvantage
  88. is that the port is dedicated to slip logins.
  89.  
  90. If you already have a login program which does S/Key authentication,
  91. then you can leave the password field blank, so diplogin does not try
  92. to do a second authentication.
  93.  
  94. -=-=-=-=-=-=-
  95.  
  96. I have been testing out the updates here between my two machines, and
  97. they seem to work very well.
  98.  
  99. As I said earlier I am a bit concerned about making diplogin suid
  100. root, because of the security implications.  How do people normally
  101. configure diplogin, so that it can configure the interface etc?
  102.  
  103. A future enhancement may be to make the users password an optional
  104. parameter to the skey command, so that they do not have to be
  105. prompted. This is complicated a little by the fact that S/Key
  106. passwords do not have to be single words. Therefore do_command would
  107. probably have to be updated to accept a quoted string as a single
  108. parameter. Personally I do not like including passwords in scripts,
  109. but other people may find it useful.  Anyway here is the patch. If you
  110. have any problems, or questions, please give me a shout.
  111.  
  112. Stephen....
  113.