Pseudoterminal
In some operating systems, including Unix-like systems, a pseudoterminal, pseudotty, or PTY is a pair of pseudo-device endpoints (files) which establish asynchronous, bidirectional communication (IPC) channel (with two ports) between two or more processes.
One pseudo-device in the pair, the master, provides means by which a terminal emulator or remote login server (e.g. a Telnet, rlogin, or Secure Shell server) process controls the slave. The other pseudo-device, the slave, emulates a hardware serial port device, and is used by terminal-oriented programs such as shells (e.g. bash) as a processes to read/write data back from/to master endpoint. PTYs are similar to bidirectional pipes.: 1388
Devpts is a Linux kernel virtual file system containing pseudoterminal devices.
Linux implementation is based on System V-style terminals (commonly referred as UNIX 98 pseudoterminals) and provides POSIX and the Single Unix Specification API in the form of a posix_openpt() function since 1998.