On Wed, 30 Sep 1998, Robert G. Brown wrote:
>  I'm working with Jacek writing my own
> version of "procd", a daemon that I already have running in alpha that
> can provide on demand what amounts to a cat of any (permitted) file in
> /proc, all via a TCP connection without the overhead of a shell.  The
> procd can also lookup or query/build anything accessible in userspace,
> e.g. it calculates and returns number of users or local time the hard
> way to avoid shell calls to uptime (I'm trying to leave it
> unprivileged).  I'd be happy to add code to procd to query the CPU

I've also written a little daemon that I call procd.  It is a simple
socket based app that listens for a connection on a specified TCP port. 
You telnet to the port and type the name of the file you want to view.  It
restricts the files you can see to those available from /proc.   So if you
want /proc/cpuinfo that's exactly what you type into your telnet session
and you get the results right there.  There isn't any reason why another
program couldn't be written to communicate with this one.  The output from
the file requested continues until you see a '.' on a line by itself, much
like the termination of a DATA segment in SMTP, so it would be easy to
parse.
  This runs as a nonpriveleged user also, no need for root.
  I don't have this up on the web yet so if anyone would like to see it
just drop me an email.  Its GPL'd, as it should be.
  -M@

Reply via email to