netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "David S. Miller" <davem@redhat.com>
To: Andrew Morton <akpm@osdl.org>
Cc: dtucker@zip.com.au, netdev@oss.sgi.com
Subject: Re: [Bugme-new] [Bug 1360] New: Can't access /proc/self/fd/0 from sshd when no pty allocated.
Date: Sat, 18 Oct 2003 23:57:35 -0700	[thread overview]
Message-ID: <20031018235735.52f5e15a.davem@redhat.com> (raw)
In-Reply-To: <20031018172736.417bf89d.akpm@osdl.org>

On Sat, 18 Oct 2003 17:27:36 -0700
Andrew Morton <akpm@osdl.org> wrote:

> This appears to be deliberate:
> 
> /*
>  *	In theory you can't get an open on this inode, but /proc provides
>  *	a back door. Remember to keep it shut otherwise you'll let the
>  *	creepy crawlies in.
>  */
>   
> static int sock_no_open(struct inode *irrelevant, struct file *dontcare)
> {
> 	return -ENXIO;
> }
> 
> I do not know why; the comment is fairly useless.

For many socket types there are no sane open() semantics.

If I open() a unconnected socket, what does that mean?
Should it connect, of do something like a dup()?

This code has been this way for a long time, anyone who wants to
change this needs to deal with and address all the aforementioned
issues.

  reply	other threads:[~2003-10-19  6:57 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <200310151142.h9FBgi5k029003@fire-1.osdl.org>
2003-10-19  0:27 ` [Bugme-new] [Bug 1360] New: Can't access /proc/self/fd/0 from sshd when no pty allocated Andrew Morton
2003-10-19  6:57   ` David S. Miller [this message]
2003-10-22  8:40     ` Darren Tucker

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20031018235735.52f5e15a.davem@redhat.com \
    --to=davem@redhat.com \
    --cc=akpm@osdl.org \
    --cc=dtucker@zip.com.au \
    --cc=netdev@oss.sgi.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).