home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / unix / wizards / 4781 < prev    next >
Encoding:
Text File  |  1992-11-18  |  1.8 KB  |  38 lines

  1. Newsgroups: comp.unix.wizards
  2. Path: sparky!uunet!mcsun!sunic!aun.uninett.no!news.uit.no!staff.cs.uit.no!orjanr
  3. From: orjanr@staff.cs.uit.no (╪rjan Robertsen)
  4. Subject: Please explain...
  5. Keywords: Telnet, pseudo-terminals, sockets
  6. Sender: orjanr@staff.cs.uit.no (Orjan Robertsen)
  7. Organization: University of Troms°
  8. Date: Wed, 18 Nov 1992 19:06:32 GMT
  9. Message-ID: <1992Nov18.190632.13873@news.uit.no>
  10. Lines: 26
  11.  
  12. Hello wizards, can some of you help me out on the following:
  13.  
  14. When you use telnet, telnetd sets up a pseudo terminal before doing
  15. a fork. The child "dups" its descriptors so that stdin. stdout and stderr all
  16. go to the slave side of the pseudo terminal, and then execs /bin/login
  17. which in turn execs your remote shell. The parent (the original telnetd)
  18. goes into a loop and handles I/O from the net and the master side of the pseudo
  19. terminal. Right? 
  20.  
  21. What I don't understand is how input/output from the shell (to/from the slave side of the terminal) ends up going over the socket back to the local telnet?
  22. I thought all communication had to pass through telnetd, but monitoring
  23. this process (with monitor) shows no I/O activity when telnet and the remote
  24. shell is communicating. How can this be ? How is the I/O from the remote
  25. shell mapped onto the network ? I thought it would pass through the normal
  26. sosend()/soreceive() routines, but as far as I can see, it does not?
  27.  
  28. The book by Stevens gives a good example with rlogin, and from the picture
  29. (side 617) it seems that all communication goes through rlogind. Shouldn't
  30. it be the same setup for telnetd ?
  31.  
  32. Please email.
  33. Thanks in advance..
  34. -- 
  35. ////      ╪rjan W. Robertsen            |e-mail   : orjanr@staff.cs.uit.no////
  36. ///Dept. of Computer Science, University|Home     : +47-83-82897          ///
  37. // of Tromsoe, N-9000 TROMS╪, NORWAY    |Phone/Fax: +47-83-44053/44580    //
  38.