lkml.org 
[lkml]   [2004]   [Feb]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Does anyone still care about BSD ptys?
On Mon, 9 Feb 2004, Dominik Kubla wrote:

> On Mon, Feb 09, 2004 at 09:00:24AM -0500, Richard B. Johnson wrote:
> > > On Mon, Feb 09, 2004 at 07:17:27AM +0000, H. Peter Anvin wrote:
> > > > Does anyone still care about old-style BSD ptys, i.e. /dev/pty*?
> >
> > Only people who want to log-in from the network..... Of course
> > you could force a re-write of all the stuff like telnet, adding
> > another layer of bugs that'll take another N years to find and
> > remove.
>
> What are you talking about? On my system (Debian Sid) there are no BSD
> pty's (i removed the device nodes) and everything works without even a
> recompile.
>
> Regards,
> Dominik


Really? Then you don't have anybody trying to log-in
from the network using telnet, then do you?

The BSD virtual terminals go in pairs, /dev/ptyp* /dev/ttyp*

Script started on Mon Feb 9 13:19:16 2004
# ls -la /dev/ptyp*
crw-rw-rw- 1 root root 2, 0 Feb 9 13:17 /dev/ptyp0
crw-rw-rw- 1 root root 2, 1 Feb 9 13:19 /dev/ptyp1
crw-rw-rw- 1 root root 2, 2 Feb 5 11:22 /dev/ptyp2
crw-rw-rw- 1 root root 2, 3 Mar 19 2003 /dev/ptyp3
[SNIPPED...]

# ls -la /dev/ttyp0
# ls -la /dev/ttyp*
crw--w---- 1 rjohnson tty 3, 0 Feb 9 13:17 /dev/ttyp0
crw-rw-rw- 1 root root 3, 1 Feb 9 13:19 /dev/ttyp1
crw-rw-rw- 1 root root 3, 2 Feb 5 11:22 /dev/ttyp2
crw-rw-rw- 1 root root 3, 3 Mar 19 2003 /dev/ttyp3
Script done on Mon Feb 9 13:20:03 2004
Here, rjohnson is logged in using telnet. The code is so common
that there is even some C runtime library support in later
C libraries, it's called forkpty(). `man forkpty`. It does a lot
of the dirty-work of using BSD virtual terminals.


Cheers,
Dick Johnson
Penguin : Linux version 2.4.24 on an i686 machine (797.90 BogoMips).
Note 96.31% of all statistics are fiction.


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:00    [from the cache]
©2003-2011 Jasper Spaans