Subject: watching a tty
To: None <netbsd-users@netbsd.org>
From: Tomasz Luchowski <zuntum@netbsd.org>
List: netbsd-users
Date: 11/29/2001 17:20:21
FreeBSD has watch(8):

NAME
     watch - snoop on another tty line

SYNOPSIS
     watch [-ciotnW] [tty]

DESCRIPTION
     Watch allows the superuser to examine all data coming through a specified
     tty.  Watch writes to standard output.

Would it be possible to do something similair (i.e. spying another person and
seeing what's she doing) on NetBSD?

Just compiling their watch doesn't work

17:14 zuntum@flis:/tmp/watch> ls
Makefile  watch.8   watch.c
17:14 zuntum@flis:/tmp/watch> make
cc -O2 -pipe -march=pentium -mcpu=pentium -pipe -march=pentium -mcpu=pentium -Werror   -c watch.c
watch.c:24: sys/snoop.h: No such file or directory
watch.c: In function `detach_snp':
watch.c:217: `SNPSTTY' undeclared (first use in this function)
watch.c:217: (Each undeclared identifier is reported only once
watch.c:217: for each function it appears in.)
watch.c: In function `attach_snp':
watch.c:223: `SNPSTTY' undeclared (first use in this function)
watch.c: In function `main':
watch.c:393: `SNP_OFLOW' undeclared (first use in this function)
watch.c:401: `SNP_DETACH' undeclared (first use in this function)
watch.c:402: `SNP_TTYCLOSE' undeclared (first use in this function)
cc1: warnings being treated as errors
watch.c:394: warning: unreachable code at beginning of switch statement
*** Error code 1

Stop.

as they have to use "pseudo-device snp" in kernel. Any thoughts?


-- 
/* Tomasz Luchowski <zuntum@netbsd.org> */