linux/arch/powerpc/include/uapi/asm
Aleksa Sarai 54ebbfb160 tty: add TIOCGPTPEER ioctl
When opening the slave end of a PTY, it is not possible for userspace to
safely ensure that /dev/pts/$num is actually a slave (in cases where the
mount namespace in which devpts was mounted is controlled by an
untrusted process). In addition, there are several unresolvable
race conditions if userspace were to attempt to detect attacks through
stat(2) and other similar methods [in addition it is not clear how
userspace could detect attacks involving FUSE].

Resolve this by providing an interface for userpace to safely open the
"peer" end of a PTY file descriptor by using the dentry cached by
devpts. Since it is not possible to have an open master PTY without
having its slave exposed in /dev/pts this interface is safe. This
interface currently does not provide a way to get the master pty (since
it is not clear whether such an interface is safe or even useful).

Cc: Christian Brauner <christian.brauner@ubuntu.com>
Cc: Valentin Rothberg <vrothberg@suse.com>
Signed-off-by: Aleksa Sarai <asarai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-06-09 12:27:54 +02:00
..
auxvec.h powerpc: Add new cache geometry aux vectors 2017-02-06 19:46:04 +11:00
bitsperlong.h
bootx.h
byteorder.h powerpc: Include the appropriate endianness header 2013-10-11 16:48:33 +11:00
cputable.h powerpc: Add PPC_FEATURE userspace bits for SCV and DARN instructions 2017-05-25 23:07:45 +10:00
eeh.h powerpc/eeh: Introduce eeh_pe_inject_err() 2015-05-12 20:33:35 +10:00
elf.h powerpc: Move ARCH_DLINFO out of uapi 2017-02-06 19:46:04 +11:00
epapr_hcalls.h powerpc: Fix misspellings in comments. 2016-03-01 19:27:20 +11:00
errno.h powerpc/kernel: Switch to using MAX_ERRNO 2015-07-29 11:56:11 +10:00
fcntl.h
ioctl.h
ioctls.h tty: add TIOCGPTPEER ioctl 2017-06-09 12:27:54 +02:00
ipcbuf.h
Kbuild uapi: export all headers under uapi directories 2017-05-11 00:21:54 +09:00
kvm_para.h KVM: PPC: Disable NX for old magic page using guests 2014-05-30 14:26:24 +02:00
kvm.h kvm: make KVM_COALESCED_MMIO_PAGE_OFFSET public 2017-04-07 16:49:01 +02:00
mman.h powerpc/hugetlb: Add ABI defines for supported HugeTLB page sizes 2017-04-11 07:46:06 +10:00
msgbuf.h
nvram.h
opal-prd.h powerpc/powernv: Add opal-prd channel 2015-06-05 08:32:21 +10:00
param.h
perf_event.h powerpc/perf: Export PERF_EVENT_CONFIG_EBB_SHIFT to userspace 2013-08-01 13:11:46 +10:00
perf_regs.h powerpc/perf: Assign an id to each powerpc register 2016-04-21 23:32:59 +10:00
poll.h
posix_types.h
ps3fb.h
ptrace.h powerpc: Change vrX register defines to vX to match gcc and glibc 2015-03-16 18:32:11 +11:00
resource.h
sembuf.h
setup.h powerpc: Bump COMMAND_LINE_SIZE to 2048 2014-04-28 16:31:58 +10:00
shmbuf.h
sigcontext.h powerpc/signal: Fix confusing header documentation in sigcontext.h 2015-07-16 16:14:40 +10:00
siginfo.h
signal.h powerpc: switch to generic old sigaction() 2013-02-03 18:16:10 -05:00
socket.h New getsockopt option to get socket cookie 2017-04-08 08:07:01 -07:00
sockios.h
spu_info.h
stat.h
statfs.h
swab.h
termbits.h
termios.h
tm.h powerpc/tm: Abort syscalls in active transactions 2015-06-19 17:10:28 +10:00
types.h
ucontext.h
unistd.h powerpc: Wire up statx() syscall 2017-03-16 20:45:53 +11:00