summaryrefslogtreecommitdiffstats
path: root/sys/netinet6/in6_proto.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Copy the user provided sockaddr into a normalized sockaddr in rtrequest()claudio2019-06-131-1/+2
| | | | | | | | | | before adding it to the routing table. The rtable code is doing memcmp() of those rt_dest sockaddrs so it is important that they are stored in a canonical form. To do this struct domain is extended to include the sockaddr size for this address family. OK bluhm@ anton@ Reported-by: syzbot+10fe9cd8d0211c562ead@syzkaller.appspotmail.com
* Retire dom_rtkeylen from struct domain. Nothing is using this anymore.claudio2018-11-191-2/+1
| | | | | It was used by the original patricia tree. OK mpi@
* rework gif to be more consistent.dlg2018-02-101-2/+18
| | | | | | | | | while here, give us support for mpls in gif on ipv6. this moves all the gif handling into if_gif, eg, the mpls handling is no longer in ip_etherip.c. ok claudio@
* update the gre driver.dlg2018-02-071-1/+19
| | | | | | | | | | | the main new feature is gre keys, supported by the vnetid ioctls. this also adds support for gre over ipv6, the use of hfsc, and allows tx mitigation in the future. this diff removes keepalive support, but i promised claudio@ and patrick@ i would put it back after this goes in. ok claudio@
* Constify protocol tables and remove an assert now that ip_deliver() ismpi2017-11-231-2/+2
| | | | | | mp-safe. ok bluhm@, visa@
* Drop all Ethernet-in-IP support from gif(4)jca2017-11-171-14/+1
| | | | | As a result, ip_ether.c now only deals with MPLS-in-IP. The next commits will move & rename stuff to make this clear. ok visa@ mpi@
* Remove inet6 etherip sysctl entriesjca2017-11-151-3/+1
| | | | | | | The INET6 entries are not needed, not documented (use net.inet.etherip) and do not appear in sysctl(8) output. ok mpi@
* Finish off pr_drain functions, they haven't been used since 2006.florian2017-11-051-2/+1
| | | | OK mpi
* Move PRU_DETACH out of pr_usrreq into per proto pr_detachflorian2017-11-021-2/+16
| | | | | | functions to pave way for more fine grained locking. Suggested by, comments & OK mpi
* Get rid of ip6.maxifprefixes and ip6.maxifdefrouters, the kernel noflorian2017-07-131-3/+1
| | | | | | | longer tracks prefixes or default routers from router advertisements. Pointed out by jmc. ports tree grepping sthen, who only found nsh OK mpi, sthen
* The function name ip4_input() is confusing as it also handles IPv6bluhm2017-05-181-3/+3
| | | | | | | | | | packets. This is the IP in IP protocol input function, so call it ipip_input(). Rename the existing ipip_input() to ipip_input_gif() as it is the input function used by the gif interface. Pass the address family to make it consistent with pr_input. Use __func__ in debug print and panic messages. Move all ipip prototypes to the ip_ipip.h header file. OK dhill@ mpi@
* The large and nested GIF #ifdef in protosw made it hard to figurebluhm2017-05-171-30/+16
| | | | | | out what is going on. There were also some inconsistencies that seem to be oversights. Use more specific the #ifdefs. OK mpi@
* Remove rip_output() and rip6_output() from inetsw and inet6sw. Thebluhm2017-05-091-14/+1
| | | | | | | rip_output() function is never called via the pr_output pointer. rip_usrreq(PRU_SEND) calls rip_output() directly. raw_usrreq() is never called from inetsw. Situation in inet and inet6 is analog. OK claudio@ mikeb@
* Move PRU_ATTACH out of the pr_usrreq functions into pr_attach.claudio2017-03-131-4/+20
| | | | | | | Attach is quite a different thing to the other PRU functions and this should make locking a bit simpler. This also removes the ugly hack on how proto was passed to the attach function. OK bluhm@ and mpi@ on a previous version
* Convert domain declarations to C99 initializers.mpi2017-03-021-8/+12
| | | | ok dhill@, florian@, bluhm@
* Use c99 struct initialization with protosw.dhill2017-02-221-90/+187
| | | | | | | This makes it easier to grep for a member, such as .pr_usrreq, and know which functions to review. ok mpi@ bluhm@ jca@
* Change the IPv4 pr_input function to the way IPv6 is implemented,bluhm2017-01-291-8/+8
| | | | | | | to get rid of struct ip6protosw and some wrapper functions. It is more consistent to have less different structures. The divert_input functions cannot be called anyway, so remove them. OK visa@ mpi@
* Remove PIM support from the multicast stack.rzalamena2016-12-221-12/+1
| | | | ok mpi@
* Kill sysctl net.inet6.ip6.rr_prunejca2016-06-011-3/+1
| | | | | We don't support Router Renumbering and there are no plans to change that. ok mpi@
* Remove sysctl net.inet6.ip6.v6onlyjca2016-05-191-2/+1
| | | | | | | | This sysctl is a no-op, read-only since it was introduced. There are no plans to support IPv4-mapped addresses on OpenBSD, thus this sysctl is meaningless. Noticed by djm@, ok claudio@ mpi@ sthen@ henning@
* Get rid of rt_mask() and stop allocating a "struct sockaddr" for everympi2015-12-031-2/+2
| | | | | | | | | | | | | 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@
* Implement etherip(4) drivergoda2015-12-031-1/+13
| | | | | | | 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@
* Initialize the routing table before domains.mpi2015-10-071-3/+3
| | | | | | | | | | | | | | | | | | | | | | | The routing table is not an optional component of the network stack and initializing it inside the "routing domain" requires some ugly introspection in the domain interface. This put the rtable* layer at the same level of the if* level. These two subsystem are organized around the two global data structure used in the network stack: - the global &ifnet list, to be used in process context only, and - the routing table which can be read in interrupt context. This change makes the rtable_* layer domain-aware and extends the "struct domain" such that INET, INET6 and MPLS can specify the length of the binary key used in lookups. This allows us to keep, or move towards, AF-free route and rtable layers. While here stop the madness and pass the size of the maximum key length in *byte* to rn_inithead0(). ok claudio@, mikeb@
* Merge gif(4)'s tentacles in a single file.mpi2015-09-281-2/+2
| | | | | | Tested by <mxb AT alumni DOT chalmers DOT se>. ok dlg@
* Make every subsystem using a radix tree call rn_init() and pass thempi2015-09-041-2/+1
| | | | | | | | | | | | | | | length of the key as argument. This way every consumer of the radix tree has a chance to explicitly initialize the shared data structures and no longer rely on another subsystem to do the initialization. As a bonus ``dom_maxrtkey'' is no longer used an die. ART kernels should now be fully usable because pf(4) and IPSEC properly initialized the radix tree. ok chris@, reyk@
* Use a global table for domains instead of building a list at run time.mpi2015-08-301-2/+2
| | | | | | | As a side effect there's no need to run if_attachdomain() after the list of domains has been built. ok claudio@, reyk@
* Abstract the routing table internals behind an rtable_* API.mpi2015-07-181-10/+3
| | | | | | | | | | Code abusing the radix internals for the routing table should now includes <net/rtable.h> and only deal with "struct rtentry". Code using a radix tree for another purpose can still include <net/radix.h>. Inputs from and ok claudio@, mikeb@
* unifdef INET in net code as a precursor to removing the pretend option.tedu2014-12-191-9/+1
| | | | | long live the one true internet. ok henning mikeb
* Explicitly include <net/if_var.h> instead of pulling it in <net/if.h>.mpi2014-12-051-1/+2
| | | | ok mikeb@, krw@, bluhm@, tedu@
* Nuke net.inet6.icmp6.rediraccept and allow redirects on interfacesflorian2014-08-271-2/+1
| | | | | | | with autoconf enabled. If one is doing SLAAC one does already trust link local icmp6 so the policy for icmp6 redirects should be the same. pointed out by & OK bluhm@; OK henning@
* Keep pim code under #ifdef PIM to be coherent with what's in netinet/.mpi2014-08-191-4/+4
|
* Fewer <netinet/in_systm.h> !mpi2014-07-221-2/+1
|
* introduce the IFXF_AUTOCONF6 interface flag which controls wether wehenning2014-07-111-2/+1
| | | | | | | | | accept rtadvs on that interface. the global net.inet6.ip6.accept_rtadv sysctl just doesn't cut it, even tho the spec wants that - but in their little absurd world, a host just has one interface by definition anyway... the sysctlgoes away. lots of head scratching, brain cell elemination etc from bluhm benno stsp florian, excitement from simon and todd, ok bluhm stsp benno florian
* Remove rfc 4620 Node Information Query support (from the kernel).benno2014-07-111-2/+1
| | | | ok henning@ stu@, Yay! weerd@
* Set default of net.inet6.icmp6.nodeinfo to 0,benno2014-07-091-2/+2
| | | | | disables responses to RFC4620 IPv6 Node Information Queries. ok florian henning bluhm
* There are gasps of shock! Add a pmtu delay sysctl BUTTON for netinet6,deraadt2013-10-211-9/+2
| | | | | making the code the same as netinet4 along the way. ok bluhm phessler
* The header file netinet/in_var.h included netinet6/in6_var.h. Thisbluhm2013-10-171-3/+2
| | | | | | | created a bunch of useless dependencies. Remove this implicit inclusion and do an explicit #include <netinet6/in6_var.h> when it is needed. OK mpi@ henning@
* Instead of having various extern declarations for protocol variables,mpi2013-04-241-3/+2
| | | | declare them once in their corresponding header file.
* Allow raw IPv6 sockets for IPsec protocols. IPv4 does the same.bluhm2013-04-011-7/+7
| | | | Ok claudio@
* tedu faith(4), suggested by todd@ some weeks ago after a submission bympi2013-03-141-2/+1
| | | | | | dhill. ok krw@, mikeb@, tedu@ (implicit)
* Expand the socket splicing functionality from TCP to UDP. Mergebluhm2013-01-171-2/+2
| | | | | | | the code relevant for UDP from sosend() and soreceive() into somove(). That allows the kernel to directly transfer the UDP data from one socket to another. OK claudio@
* Direct IPv6 packets with Ethernet encapsulation into the appropriatemikeb2012-03-151-2/+8
| | | | | | | input routine allowing us to bridge two IPv4 networks over an IPv6 link with gif(4). ok henning, sthen, ok and tests phessler, "lets get this in!" todd
* - use nitems(); no binary changejasper2011-03-311-2/+2
| | | | ok claudio@
* Don't process ICMP6 redirects by default anymore. This is in line withclaudio2011-03-231-2/+2
| | | | | | what we do for IPv4. rtsol will turn it back on if -F is used. After discussion with bluhm@, fgsch@, sthen@ and deraadt@ OK sthen@
* Add socket option SO_SPLICE to splice together two TCP sockets.bluhm2011-01-071-2/+2
| | | | | | | The data received on the source socket will automatically be sent on the drain socket. This allows to write relay daemons with zero data copy. ok markus@
* remove some unused netinet6 codejsg2010-07-081-8/+1
| | | | ok stsp@ henning@ claudio@
* IPv6 support for divert sockets.michele2009-11-051-3/+15
| | | | | | tested by phessler@ pyr@ ok claudio@ "go ahead" deraadt@
* delay /etc/netstart until IPv6-DAD (dup-address-detection) is completed.markus2008-11-251-1/+2
| | | | ok fries, hshoexer, claudio
* From KAME, allow adjustable limits on NDP entries and discovered routes.mcbride2008-06-111-1/+5
| | | | ok mpf naddy
* Remove {tcp/udp}6_usrreq(); Since the normal ones nowthib2008-05-241-3/+3
| | | | | | | take a proc argument, theres no need for these, since they are just wrappers. OK claudio@