summaryrefslogtreecommitdiff
path: root/usr.sbin/bgpd
AgeCommit message (Collapse)Author
2017-06-27move a global into local context; from rob pierceTheo de Raadt
2017-06-26let admins set an unknown well-known communityPeter Hessler
from Job Snijders ok phessler@ benno@
2017-06-26add support for the "graceful shutdown" well-known community as describedPeter Hessler
in draft-ietf-grow-bgp-gshut from Job Snijders ok phessler@ benno@
2017-06-26allow setting localpref to 0Peter Hessler
from Job Snijders ok phessler@ benno@
2017-05-31Too vs To. Found by Denis Fondras openbsd (at) ledeuns (dot) netClaudio Jeker
2017-05-31Man page bits for ext-community which grew a few more subtypes.Claudio Jeker
Based on a diff from Job Snijders
2017-05-31Oups, that should have not been committed. Revert.Claudio Jeker
2017-05-31Rework the way we do extended communities (mainly in the parser) and updateClaudio Jeker
the IANA table to a somewhat more complete list. This includes BGP Prefix Origin Validation State support via the ext-community ovs keyword. OK henning@ benno@ based on a diff by Job Snijders
2017-05-30remove extended communities that have the transitive bit set fromSebastian Benoit
routes announced to an ebgp peer (ref. rfc4360). While here remove the pratial flag from extended and large communities. ok claudio@
2017-05-29change section title in bgpd.conf talking about MPLS,Sebastian Benoit
add a bit about working with multiple bgpds in rdomains in bgpctl. shouting from claudio@ and help from jmc@
2017-05-29fix "depend on" when carp interface goes from MASTER into state INITSebastian Benoit
aka UNKNOWN. ok claudio@ phessler@ and henning helped along too
2017-05-29After some consideration, revert last commit and don't abuse rde_dump_done.Claudio Jeker
IMSG_CTL_SHOW_RIB_PREFIX case is not using rib_dump_r and so should not use rde_dump_done, instead send the IMSG_CTL_END msg and free the ctx directly. This is easier to understand.
2017-05-29Fix crash in IMSG_CTL_SHOW_RIB_PREFIX handling. The ctx is not added toClaudio Jeker
the list in that case so don't try to LIST_REMOVE it. Problem found by benno@
2017-05-29change bgpd's control socket from /var/run/bgpd.sock toSebastian Benoit
/var/run/bgpd.sock.<rdomain> in both bgpd and bgpctl. makes life easier for admins. ok phessler, claudio, henning, feedback from Job Snijders
2017-05-29remove the file permission check for bgpd.confPeter Hessler
OK deraadt@, henning@, sthen@, and everyone who has ever been annoyed
2017-05-28Print when we send or recv an EOR marker.Claudio Jeker
Req by and OK benno@
2017-05-28Introduce log_peer_info() and make log_peer_warn() log at LOG_ERR insteadClaudio Jeker
of LOG_CRIT (which should only be used for fatal). OK benno@
2017-05-28Close imsg pipes later in the process. The shutdown code still tires toClaudio Jeker
send imsgs and so the SE and RDE crashed because of this late in shutdown. OK benno@ phessler@
2017-05-28tweak previous;Jason McIntyre
2017-05-28we're not hardcoded to table 0 any moreHenning Brauer
2017-05-28so far, bgpd was hardcoded to use rtable 0 for nexthop verification.Henning Brauer
instead, use the rtable bgpd was started in (route -T <n> exec / rc.d daemon_rtable) for nexthop verification and as default Adj-RIB-In and Loc-RIB. This allows multiple bgpds in different rdomains on the same machine - bgp router virtualization if you like buzzwords. initial version written under contract more than a year ago, it took us a while to wrap our brains around the bgpd <-> rdomain interactions - 1) RIBs, 2) nexthop verification and 3) tcp sockets. ok & input phessler claudio benno
2017-05-28Implement an XON/XOFF protocol between the RDE and the SE to throttleClaudio Jeker
per control session and peer the generation of imsg in the RDE. This reduces the memory pressure in the SE substantially and also a bit in the RDE. Makes the RDE more responsive for bgpctl commands. Tested by me with 100 peers * 2000 prefixes and by phessler@ on an AMS-IX border router with 200+ session. Convergance time got quite a bit better. OK phessler@
2017-05-27Allow an administrator to disable the bgp loop detection algorithm,Peter Hessler
which is useful in very limited situations. Angry dragons and grues will hunt for you, if you use it. OK claudio@ sthen@ benno@
2017-05-27allow only one network <prefix> statement per for the same prefix.Sebastian Benoit
ok florian@ phessler@
2017-05-27bump the size of ctl rib flagsPeter Hessler
OK claudio@
2017-05-27this expects 2byte ASN, so use that, instead of an asn that may or may not fitPeter Hessler
noticed by and OK claudio@
2017-05-27Allow OpenBGPD to selectively choose which local ASN to use per-peer.Peter Hessler
This is intended to be used for ASN migrations, not for permanent use. You MUST use filters to protect yourself from receiving your own routes. There be dragons and grues. OK claudio@ benno@
2017-05-27allow us to use 'local-as' in the filter languagePeter Hessler
"match in from any set community local-as:neighbor-as" OK claudio@
2017-05-27fix the reference to draft-ymbk-grow-blackholing, to RFC 7999Peter Hessler
2017-05-26AS 0 is special and should be considered an error.Peter Hessler
Drop the session if it shows during OPEN or CAPA, or mark as invalid if it is part of an Update. required by RFC 7607 man page OK jmc@ OK florian@ benno@ claudio@
2017-05-26Expand RIB names in groupsPeter Hessler
Diff from Denis Fondras, many thanks! OK claudio@ phessler@
2017-05-26Allow nested {} in prefix lists.Peter Hessler
Diff from Denis Fondras, many thanks! OK claudio@ phessler@
2017-04-18use freezero()Theo de Raadt
2017-03-28For IPv6 pass prefix not nexthop as network for connected nexthops back toClaudio Jeker
the RDE so that the code actually works. Problem found and reported by Pier Carlo Chiodi (pierky at pierky com) OK deraadt@
2017-03-21From a syslog perspective it does not make sense to log fatal andAlexander Bluhm
warn with the same severity. Switch log_warn() to LOG_ERR and keep fatal() at LOG_CRIT. OK reyk@ florian@
2017-03-02Fix breakage of md5 authentication.Renato Westphal
The previous commit (rev 1.47) added a missing htonl in pfkey_send() but didn't add a corresponding ntohl in pfkey_reply(). This patch fixes this. Found the hard way by benno@, who also suggested the rename of spip to spi. OK benno@ claudio@ henning@
2017-02-22Add missing htonl for IPsec SPI.Renato Westphal
Also, do not allow to configure SPI values in the 0..255 range. RFC 4302 and RFC 4303 say the following: "The set of SPI values in the range 1 through 255 are reserved by the Internet Assigned Numbers Authority (IANA) for future use; a reserved SPI value will not normally be assigned by IANA unless the use of the assigned SPI value is specified in an RFC. The SPI value of zero (0) is reserved for local, implementation-specific use and MUST NOT be sent on the wire". ok and tweak benno@
2017-02-19draft-ietf-idr-large-community has been published as RFC 8092Peter Hessler
2017-02-13draft-ietf-idr-shutdown extends to support a message on either ofPeter Hessler
"Administrative Shutdown" or "Administrative Reset" patch submitted by Job Snijders, thanks!
2017-01-25Hopefully the last of the struct rib rototilling. Peer just points to aClaudio Jeker
struct rib and not rib_desc since the full descriptor is almost never needed. This should now allow the update code to be changed.
2017-01-25Switch rde_generate_update and rde_send_kroute to accept a struct rib insteadClaudio Jeker
of the id. For this we move the rtableid into struct rib. Also move the update code in rib.c up to where the kroute code is. Makes more senses like that.
2017-01-25Flag the Loc-RIB with F_RIB_LOCAL so we can remove one ugly hack somewhere elseClaudio Jeker
2017-01-24Save some space in struct rib_entry so it is back to 64bytes (on 64bit archs).Claudio Jeker
Doing this by folding the lock flag into a pointer and providing an accessor function for the rib pointer. This is an acceptable middle path for this important structure. OK benno@ on an earlier version
2017-01-24sync log.c from relayd et al to bgpd.Sebastian Benoit
there is still a little difference regarding handling of the verbosity value that will be handled later. ok claudio@ florian@
2017-01-23Make util.c fatal() free by allowing undefined behaviour in prefix_compare.Claudio Jeker
If you pass in crap then you will not get gold back.
2017-01-23Rename rib pointer in struct prefix to re since it points to a rib_entry.Claudio Jeker
While there also remove a comment that is since a few years at least. OK gcc
2017-01-23Introduce a struct rib sitting between struct rib_desc and struct rib_tree.Claudio Jeker
This way the tree becomes a bit better decoupled.
2017-01-23Revert the struct rib_tree rename. I need a struct in between because ofClaudio Jeker
how struct rib_entry is used.
2017-01-23More rototilling, make rib_new and rib_find return a point to struct rib_descClaudio Jeker
2017-01-23Now rename struct rib_tree to struct rib. Again OK gccClaudio Jeker