[SLUG] sending data to STDIN of an arbitrary process

From: R P Herrold (herrold@owlriver.com)
Date: Thu Oct 01 2009 - 10:17:17 EDT


On Thu, 1 Oct 2009, draeath wrote:

> I needed to send the text "Yes" followed by a return. I was root,
> which you would probably need to be (or be the user who 'owns' the
> process).
>
> Code:
> echo Yes > /proc/1337/fd/0

> If you don't want to send the return (newline) use "echo -n"
> as such: echo -n Yes > /proc/1337/fd/0

one assumes that these /proc tree entries have the usual
restrictions of only accepting input from root and the EUID
/ EGID of the owning process

... a quick perusal confirms this

-- Russ herrold
-----------------------------------------------------------------------
This list is provided as an unmoderated internet service by Networked
Knowledge Systems (NKS). Views and opinions expressed in messages
posted are those of the author and do not necessarily reflect the
official policy or position of NKS or any of its employees.



This archive was generated by hypermail 2.1.3 : Fri Aug 01 2014 - 20:44:57 EDT