home *** CD-ROM | disk | FTP | other *** search
/ Il CD di internet / CD.iso / SOURCE / N / TCPIP / NETKIT-A.06 / NETKIT-A / NetKit-A-0.06 / dip337d-uri / README < prev    next >
Encoding:
Text File  |  1994-07-15  |  7.8 KB  |  197 lines

  1. IMPORTANT! From now on, the FORMAT OF /ETC/DIPHOSTS file
  2. is CHANGED!! Two new fields are added, they are:
  3.     - local IP address (or hostname)
  4.     - local netmask
  5.  
  6. So from now on, /etc/diphosts will look like:
  7.  
  8. user : password : remote host : local host : netmask : comments : protocol,MTU
  9.  
  10.  
  11. Fields "local host" and "netmask" can be empty, but THEY MUST BE
  12. THERE! Example:
  13.  
  14. fool::makaka:::Silly DIP client:SLIP,296
  15. smart::ass:istant:255.255.0.0:CSLIP,296
  16.  
  17. Also, please DON'T pester Fred van Kempen with questions about
  18. this version of DIP, OK?
  19.  
  20. Also, please note: my experience shows smaller blocks (i.e.
  21. smaller MTU) work BETTER. You *can* define MTU 1500, but it
  22. won't vouch for your sanity.
  23.  
  24. I somewhat modified this package, adding support for a few
  25. commands:
  26.  
  27. 1. quit - this was needed to prevent DIP from just dropping
  28.    the tty device in some weird state, in case it couldn't
  29.    succeed establishing connection (like, the phone was
  30.    busy).
  31.  
  32. 2. netmask xxx.xxx.xxx.xxx - obviously, if you have some
  33.    specific netmask in mind, you put this into your 
  34.    profile... Otherwise it won't specify "netmask ..." in
  35.    it's "ifconfig" and may G-d help you.
  36.  
  37. 3. default - this tells DIP that it should set up the
  38.    default route to the remote host it made a connection to.
  39.    If this command isn't present in the command file,
  40.    default route won't be set/changed.
  41.  
  42. 4. exit - not really needed, just for the cleanness of the
  43.    script... Instead of just falling through the bottom,
  44.    you can use this command and it will nicely exit
  45.    leaving established [C]SLIP connection intact and
  46.    running. I didn't add the code for this command,
  47.    just spotted it in the source (:-).
  48.  
  49. 5. Added "tty_notlocal()" call (provided by Rob Janssen) and
  50.    a few other patches by him (after some verification and
  51.    clean-up).
  52.  
  53. 6. Now DIP server behaves somewhat differently from DIP
  54.    client, and it improves the reliability somewhat. It
  55.    means, there are essentially two "tty_notlocal()"
  56.    thingies in the code, one for user-requested
  57.    hangup, and the other for line drop. 
  58.  
  59. 7. A few patches, by Erik Olson, Neal Becker, Rob Janssen,
  60.    Michael N. Lipp, Joerg Schlaeger, probably some others
  61.    I was too silly to record (and I apologize for that!).
  62.  
  63. 8. This DIP is now S/Key-capable. I'm adding some S/Key sources
  64.    in here, but retrieve the whole package, just to be safe.
  65.  
  66. 9. IP address can now be assigned either by user login name,
  67.    or by tty line the call came in. If the user login name 
  68.    is "ttyS1", for example... See below for a brief
  69.    explanation/example how to use it.
  70.  
  71. TAKE A LOOK at "sample.dip" file - it's there for a purpose. (:-)
  72. SAME IS TRUE for "diphosts".
  73.  
  74. ALSO, PLEASE IGNORE MOST OF THE HOWTO AND SUCH: THEY'RE HOPELESSLY
  75. OUT OF DATE. 
  76.  
  77. I'm not sure Fred will support these changes of mine, nor
  78. can I guarantee I didn't introduce new bugs with my patch.
  79. Use it on your own risk. At least it works for me, for
  80. Compressed SLIP with MTU 296 and a LOT of remote X11
  81. and FTPing and so on.
  82.  
  83. Enjoy!
  84. uri@watson.ibm.com
  85.  
  86.  
  87. Oh, before I forgot: here's how to use dynamic IP address
  88. allocation:
  89.  
  90. DIP-3.3.7-uri supports dynamic IP address allocation. That means
  91. in uri-speak, that IP addresses are allocated for tty lines, not
  92. for users (or rather, that you can have at the same time *BOTH*
  93. per-user IP address allocation and per-line IP addr allocation).
  94. So the IP address you get, dynamically depends on what line you
  95. happen to catch (:-).
  96.  
  97.  
  98. How does it work? Simply by the way you configure your DIP server,
  99. via "/etc/diphosts" file. 
  100.  
  101. 1. First put there all the entries for per-user IP addr allocation
  102.    (maybe zero entries?).
  103.  
  104. 2. Then put in all the entries for per-line IP allocation. Thus, if
  105.    you have two incoming tty lines (two modems) and want to have
  106.    two IP addresses for them, you'd put in a user "/dev/ttyS1"
  107.    and "/dev/ttyS2"... DIP-3.3.7d and up will allow you to
  108.    put in "ttyS1" and "ttyS2" (without that slash :-).
  109.  
  110. 3. Don't forget to put in all the info 
  111.     - local_host  (what your server looks like for those incomers)
  112.       and for your own sake - try to make this local_host DIFFERENT
  113.           from your Ethernet/Token Ring/FDDI/whatever other IPs your
  114.        host may have;
  115.     - remote_host (what IP address you grace them with);
  116.     - netmask     (rather useful)
  117.     - of course, protocol (SLIP, CSLIP) and MTU. But that's trivial...
  118.  
  119. 4. You're all set. Now you add those users who are supposed to be allowed
  120.    to dial in, into your "/etc/passwd" (well, the standard procedure - I'm
  121.    sure you know how to do that, and if not, you aren't qualified to run a
  122.    SLIP server :-), and put "/usr/sbin/diplogin" as a shell for them.
  123.  
  124. 5. Example: user "fred" should be allowed to DIP in, and should get line-based
  125.    IP address. There are only two modems, for example, thus at most two lines
  126.    incoming.
  127.  
  128.    The user name/login name is "fred", the "ttyS1" line should have server IP
  129.    address 43.65.86.23 and remote end should get IP address "3.4.5.6",and the
  130.    "ttyS2" line should be server "43.65.86.33" and it's remote end should
  131.    get "4.5.6.7" IP addr. 
  132.  
  133.    Then "/etc/passwd" will have an entry:
  134.  
  135.         fred:*:1976:96:Inbound SLIP:/tmp:/usr/sbin/diplogin
  136.  
  137.     And in the "/etc/diphosts" the last two entries will be:
  138.  
  139.   ttyS1::3.4.5.6:43.65.86.23:255.255.255.0:Modem 1 incoming SLIP entry:CSLIP,296
  140.   ttyS2::4.5.6.7:43.65.86.33:255.255.255.0:Modem 2 incoming SLIP entry:CSLIP,296    
  141.  
  142. #if 0
  143.  
  144. This is the last version of DIP using the "/etc/diphosts" file.
  145. It has been updated to use the "databits" serial patches, the
  146. "speed" setting bugfix, Jim Seagrave's "echo" and "init" adds,
  147. and Paul Mossip's "dynamic address" patches, as sent to me by
  148. Jeff Uphoff.  Here is his README:
  149.  
  150. -----------------------------------------------------------------------------
  151. For those of us that have our SLIP IP addresses assigned dynamically,
  152. here is a patch for dip that will trap the address when the remote
  153. host 'displays' it.  (This is an option--those that don't want this
  154. need not enable it.)
  155.  
  156. The meat of this patch was written by Paul Mossip (mossip@vizlab.rutgers.edu)
  157. Someone mentioned the existance of his patch, so I emailed him requesting
  158. a copy and he anonymously ftp'd it into my linux box.  
  159.  
  160. I have been using it heavily for several days now, and it works
  161. beautifully.  Bravo to the author!  (And many thanks)
  162.  
  163. I extended his patch a slight bit; whenever I initiated a slip connection,
  164. dip executed a 'route' command that assigned the remote machine's IP
  165. address as both my Destination net/address and my Gateway address.
  166. My connection would not function unless I deleted that route and created
  167. a new one specifying my Destination net/address as 'default'.
  168. I have added 'default' to the set of commands that dip accepts--
  169. if you use it, your Destination net/address will be set to 'default',
  170. if you don't use it, dip sets up the route as it did before.  (This
  171. command, like the ones that Paul added, can either be entered in
  172. dip's command mode, or read in from a script file.)
  173.  
  174. The abilites that Paul's patch added to dip allowed me to totally
  175. automate my SLIP connections, with the exception of the routing change.
  176. This patch has taken the last step; everything is done from a script
  177. file and I haven't had a problem with the address assignment trapping once.
  178.  
  179. Those that have to deal with dynamically assigned IP address will
  180. find this very useful.
  181.  
  182. Thanks once again to Paul Mossip--he put all of the real work into
  183. this patch.
  184. -----------------------------------------------------------------------------
  185.  
  186. The next release of DIP will use a much more powerful scripting
  187. language (derived from the Minicom communications package), and
  188. it will use the "/etc/diptab" "termcap"-like database for its
  189. client hosts.  This will allow for a much more flexible setup
  190. of hosts, and it will allow me to implement a Dynamic Address
  191. Server for DIP, making it usable as a "real" SLIP/PPP dialin
  192. server.
  193.  
  194. Fred, 07/20/93
  195.  
  196. #endif
  197.