summaryrefslogtreecommitdiff
path: root/sys/netinet6
AgeCommit message (Collapse)Author
2016-01-06fix comment typosStuart Henderson
2015-12-22Do not return EEXIST if the same address is added twice.Martin Pieuchot
Reported by sebastisa@. ok sebasitia@, stsp@, florian@, vgross@
2015-12-18Fix SO_REUSE* flags effects when binding multicast addresses. NoVincent Gross
regression observed on avahi. ok benno@
2015-12-18Convert arc4random() to arc4random_uniorm(). Diff by Matthew Martin.tb
Ensure that arc4random_uniform() doesn't loop by redefining ND6_MAX_DESYNC_FACTOR to be 512, the largest power of two smaller than the RFC-specified 600 seconds. Suggested by florian@ and deraadt@ ok florian@, sthen@ in this form, arc4random change ok djm@, tedu@
2015-12-09Keep all ether prototypes in one place.Martin Pieuchot
2015-12-09Always pass a valid interface pointer to rtdeletemsg().Martin Pieuchot
This will allows for stricter checks inside rtdeletemsg() and it should be up to the caller to decide if the route needs to be deleted or not. ok vgross@
2015-12-05Remove useless "if() else", multicast and unicast v6 route lookups areVincent Gross
actually the same. This has been introduced in r1.7 to prevent RTM_MISS storms, but we don't send this message anymore. ok @mpi
2015-12-04prefix function names like randomid and pmod to keep them out of globalTed Unangst
namespace. the history of this file is that it was a modified version of ip_id.c (with static functions to avoid clashes), then that file was rewritten, then this file lost static.
2015-12-03Get rid of rt_mask() and stop allocating a "struct sockaddr" for everyMartin Pieuchot
route entry in ART. rt_plen() now represents the prefix length of a route entry and should be used instead. For now use a "struct sockaddr_in6" to represent the mask when needed, this should be then replaced by the prefix length and RTA_NETMASK only used for compatibility with userland. ok claudio@
2015-12-03ip_send()/ip6_send() allow PF to send response packet in ipsoftnet task.Alexandr Nedvedicky
this avoids current recursion to pf_test() function. the change also switches icmp_error()/icmp6_error() to use ip_send()/ip6_send() so they are safe for PF. The idea comes from Markus Friedl. bluhm, mikeb and mpi helped me a lot to get it into shape. OK bluhm@, mpi@
2015-12-03add sizes to some free() calls. ok claudioTed Unangst
2015-12-03rewrite if to be more clear. ok bluhm stspTed Unangst
2015-12-03Implement etherip(4) driverKazuya Goda
This commit is not removing the existing EtherIP part of gif(4) and it keeps EtherIP of gif(4) working. ok jbg@ sthen@ mpi@ reyk@ yasuoka@
2015-12-03rm unused kernel only IPV6_RECVRTHDRDSTOPTS sockopt. ok deraadt sthenTed Unangst
2015-12-02Move port picking away from in_pcbbind()Vincent Gross
ok sthen@
2015-12-02When destroying an interface, we have to wait until all referencesAlexander Bluhm
are not used anymore. This has to be done before any interface fields become invalid. As the route delete request cannot call if_get() anymore, pass down the interface. Split rtrequest_delete() into a separate function that may take an existing inteface. OK mpi@
2015-12-02Kill the RT_REPORT flag to rtalloc() and stop sending RTM_MISS messagesClaudio Jeker
for failed route lookups. This is something that was maybe useful in the 90is but in this modern times it is just annoying and nothing expect it anyway. OK mpi@, sthen@
2015-12-01Use rt_ifa_add(9) instead or rtrequest(9) when adding ND prefixes.Martin Pieuchot
While here pick the corresponding ``ifa'' to attach the route instead of the one corresponding to the link-local address on the same interface. ok bluhm@
2015-12-01Kill redundant or unused arguments in rtredirect().Martin Pieuchot
ok bluhm@
2015-12-01Remove backward compatibility for "older version of routed and gated".Martin Pieuchot
ok millert@, bluhm@
2015-12-01Remove "just for safety" over engineering checks.Martin Pieuchot
ifa->ifa_addr must not be NULL when an ifa is on a per-interface list of addresses. ok bluhm@, sthen@, benno@, millert@
2015-11-29Use if_get() rather than dereferencing rt_ifp in ip6_getpmtu().Martin Pieuchot
While here fix a NULL dereference introduced by the support for multiple rdomains. It seems that this code path is never run... With input from David Hill, ok florian@
2015-11-24No need for <net/if_types.h>Martin Pieuchot
As a bonus this removes a "#if NCARP > 0", say yeah!
2015-11-21Use if_get() rather than dereferencing rt_ifp directly.Martin Pieuchot
ok sthen@, visa@, sashan@, florian@
2015-11-18Factorize the bits to check if a L2 route is connected, wether it isMartin Pieuchot
attached to a carp(4) or bridge(4) member, to not dereference rt_ifp directly. ok visa@
2015-11-13Do not cast malloc(9) results.Martin Pieuchot
2015-11-12Do not try to guess if there's still an IPv4 multicast routing daemonMartin Pieuchot
using an interface based on the value of ``ip_mrouter''. Calling SIOCDELMULTI on an interface is correct even if such daemon is running because the Ethernet layer refcounts currently joined multicast groups.
2015-11-12Unbreak adding a MIFF_REGISTER interface.Martin Pieuchot
Such interface is created on the fly so if_get() could return NULL because mif6c_pifi doesn't mean what you think in this case.
2015-11-12unidef MRT6DEBUGMartin Pieuchot
2015-11-12More PIM love. Reduce differences with ip_mroute.c and dynamicallyMartin Pieuchot
allocate the register ifp such that if_get() works.
2015-11-12Sync headers and get rid of #ifdef MROUTING.Martin Pieuchot
2015-11-12Fix PIM build.Martin Pieuchot
2015-11-11Store the index of the lo0 interface instead of a pointer to itsMartin Pieuchot
descriptor. Allow to get rid of two if_ref() in the output paths. ok dlg@
2015-11-06Change nd6_nud_hint() to no longer manipulate rt_ifp directly.Martin Pieuchot
While here remove unused argument and convert the route check to rtisvalid(9). ok bluhm@
2015-11-03Remove dead assignments.Charles Longeau
Found by LLVM/Clang Static Analyzer. ok bluhm@ mpi@
2015-11-03Disable TCP/UDP TX hardware checksumming if an IPv4 packet containsChristian Weisgerber
IP options or if an IPv6 packet contains header extensions. Required by cnmac(4) and a sensible precautionary measure in general. ok visa@, mikeb@
2015-11-02Retire ARP load-balacing, thanks for all the fish!Martin Pieuchot
One of the keys of our MP work relies on making OpenBSD's kernel simpler! In this case turning ARP processing MP-safe is quite complicated due to the way carp(4) is hooked in arpinput() and nowadays you'd better run kitchensinkd(9) anyway :) ok bluhm@, claudio@, reyk@
2015-11-02typo in commentStuart Henderson
2015-11-02Implement the list of nd6 llinfo entries with a TAILQ.Alexander Bluhm
OK millert@ mpi@
2015-11-02Prefer an existing refcounted ``ifp'' to rt_ifp when possible or use theMartin Pieuchot
interface index directly. ok bluhm@
2015-11-02Stop using rt_ifp.Martin Pieuchot
ok bluhm@
2015-11-01Replace the nd6 llinfo malloc(9) with pool_get(9) like arp does.Alexander Bluhm
OK mpi@
2015-11-01Compare nd6 llinfo pointer with NULL. No binary change.Alexander Bluhm
OK mpi@
2015-10-30Rename rtrequest1() to rtrequest().Alexander Bluhm
OK mpi@
2015-10-29a few redundant tests can be deleted now that switch cases are only forTed Unangst
a single value
2015-10-29oops, one firebomb went off course. put back some code that's still used.Ted Unangst
2015-10-29RFC 2292 API support was removed 9 years ago, but left in a binary compatTed Unangst
ABI form for the sake of existing programs. no programs from that era have been able to run for quite some time. Kill it all. ok deraadt florian millert mpi (I believe this is my first IPv6 diff. Future, here I come!)
2015-10-29Kill a comment saying that rt_ifp may not be the same as ifp, that's noMartin Pieuchot
longer true.
2015-10-28Add a missing splx for a return path introduced in rev 1.163Jonathan Gray
ok mpi@ bluhm@
2015-10-28Remove linkmtu and maxmtu from struct nd_ifinfo. IN6_LINKMTU can nowFlorian Obser
die and ifp->if_mtu is the one true mtu. Suggested by and OK mpi@