diff options
Diffstat (limited to 'sys/netinet')
-rw-r--r-- | sys/netinet/in_pcb.c | 6 | ||||
-rw-r--r-- | sys/netinet/ip_carp.c | 6 | ||||
-rw-r--r-- | sys/netinet/ip_output.c | 12 |
3 files changed, 12 insertions, 12 deletions
diff --git a/sys/netinet/in_pcb.c b/sys/netinet/in_pcb.c index 82c95755f82..45a274206a1 100644 --- a/sys/netinet/in_pcb.c +++ b/sys/netinet/in_pcb.c @@ -1,4 +1,4 @@ -/* $OpenBSD: in_pcb.c,v 1.227 2017/12/04 13:40:34 bluhm Exp $ */ +/* $OpenBSD: in_pcb.c,v 1.228 2018/02/19 08:59:53 mpi Exp $ */ /* $NetBSD: in_pcb.c,v 1.25 1996/02/13 23:41:53 christos Exp $ */ /* @@ -361,7 +361,7 @@ in_pcbbind(struct inpcb *inp, struct mbuf *nam, struct proc *p) return (error); } else { if (in_rootonly(ntohs(lport), so->so_proto->pr_protocol) && - suser(p, 0) != 0) + suser(p) != 0) return (EACCES); } if (nam) { @@ -456,7 +456,7 @@ in_pcbpickport(u_int16_t *lport, void *laddr, int wild, struct inpcb *inp, first = ipport_hifirstauto; /* sysctl */ last = ipport_hilastauto; } else if (inp->inp_flags & INP_LOWPORT) { - if (suser(p, 0)) + if (suser(p)) return (EACCES); first = IPPORT_RESERVED-1; /* 1023 */ last = 600; /* not IPPORT_RESERVED/2 */ diff --git a/sys/netinet/ip_carp.c b/sys/netinet/ip_carp.c index 0ba5ed4e63e..38e0ff74a7a 100644 --- a/sys/netinet/ip_carp.c +++ b/sys/netinet/ip_carp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ip_carp.c,v 1.329 2018/02/07 11:30:01 mpi Exp $ */ +/* $OpenBSD: ip_carp.c,v 1.330 2018/02/19 08:59:53 mpi Exp $ */ /* * Copyright (c) 2002 Michael Shalayeff. All rights reserved. @@ -2060,7 +2060,7 @@ carp_ioctl(struct ifnet *ifp, u_long cmd, caddr_t addr) case SIOCSVH: KERNEL_ASSERT_LOCKED(); /* touching carp_vhosts */ vhe = SRPL_FIRST_LOCKED(&sc->carp_vhosts); - if ((error = suser(p, 0)) != 0) + if ((error = suser(p)) != 0) break; if ((error = copyin(ifr->ifr_data, &carpr, sizeof carpr))) break; @@ -2147,7 +2147,7 @@ carp_ioctl(struct ifnet *ifp, u_long cmd, caddr_t addr) } carpr.carpr_advbase = sc->sc_advbase; carpr.carpr_balancing = sc->sc_balancing; - if (suser(p, 0) == 0) + if (suser(p) == 0) bcopy(sc->sc_key, carpr.carpr_key, sizeof(carpr.carpr_key)); carpr.carpr_peer.s_addr = sc->sc_peer.s_addr; diff --git a/sys/netinet/ip_output.c b/sys/netinet/ip_output.c index 87df5b34831..5746ab7d199 100644 --- a/sys/netinet/ip_output.c +++ b/sys/netinet/ip_output.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ip_output.c,v 1.344 2017/11/22 12:28:49 bluhm Exp $ */ +/* $OpenBSD: ip_output.c,v 1.345 2018/02/19 08:59:53 mpi Exp $ */ /* $NetBSD: ip_output.c,v 1.28 1996/02/13 23:43:07 christos Exp $ */ /* @@ -989,7 +989,7 @@ ip_ctloutput(int op, struct socket *so, int level, int optname, switch (optname) { case IP_AUTH_LEVEL: if (optval < IPSEC_AUTH_LEVEL_DEFAULT && - suser(p, 0)) { + suser(p)) { error = EACCES; break; } @@ -998,7 +998,7 @@ ip_ctloutput(int op, struct socket *so, int level, int optname, case IP_ESP_TRANS_LEVEL: if (optval < IPSEC_ESP_TRANS_LEVEL_DEFAULT && - suser(p, 0)) { + suser(p)) { error = EACCES; break; } @@ -1007,7 +1007,7 @@ ip_ctloutput(int op, struct socket *so, int level, int optname, case IP_ESP_NETWORK_LEVEL: if (optval < IPSEC_ESP_NETWORK_LEVEL_DEFAULT && - suser(p, 0)) { + suser(p)) { error = EACCES; break; } @@ -1015,7 +1015,7 @@ ip_ctloutput(int op, struct socket *so, int level, int optname, break; case IP_IPCOMP_LEVEL: if (optval < IPSEC_IPCOMP_LEVEL_DEFAULT && - suser(p, 0)) { + suser(p)) { error = EACCES; break; } @@ -1040,7 +1040,7 @@ ip_ctloutput(int op, struct socket *so, int level, int optname, /* needs privileges to switch when already set */ if (p->p_p->ps_rtableid != rtid && p->p_p->ps_rtableid != 0 && - (error = suser(p, 0)) != 0) + (error = suser(p)) != 0) break; /* table must exist */ if (!rtable_exists(rtid)) { |