diff options
author | guido <guido@FreeBSD.org> | 1998-03-01 19:39:29 +0000 |
---|---|---|
committer | guido <guido@FreeBSD.org> | 1998-03-01 19:39:29 +0000 |
commit | 406aea3e09766ad7004a2dd800fe137e6769b856 (patch) | |
tree | ce9fb746d367948f2fceb3f21525c91848a3bfa2 /sys/kern/uipc_socket.c | |
parent | 94eab2321526272010f40a6aba888228d177a5ff (diff) | |
download | FreeBSD-src-406aea3e09766ad7004a2dd800fe137e6769b856.zip FreeBSD-src-406aea3e09766ad7004a2dd800fe137e6769b856.tar.gz |
Make sure that you can only bind a more specific address when it is
done by the same uid.
Obtained from: OpenBSD
Diffstat (limited to 'sys/kern/uipc_socket.c')
-rw-r--r-- | sys/kern/uipc_socket.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/kern/uipc_socket.c b/sys/kern/uipc_socket.c index 72897db..4debb5f 100644 --- a/sys/kern/uipc_socket.c +++ b/sys/kern/uipc_socket.c @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * @(#)uipc_socket.c 8.3 (Berkeley) 4/15/94 - * $Id: uipc_socket.c,v 1.36 1998/02/06 12:13:28 eivind Exp $ + * $Id: uipc_socket.c,v 1.37 1998/02/19 19:38:20 fenner Exp $ */ #include <sys/param.h> @@ -93,6 +93,7 @@ socreate(dom, aso, type, proto, p) TAILQ_INIT(&so->so_incomp); TAILQ_INIT(&so->so_comp); so->so_type = type; + so->so_uid = p->p_ucred->cr_uid;; so->so_proto = prp; error = (*prp->pr_usrreqs->pru_attach)(so, proto, p); if (error) { |