summaryrefslogtreecommitdiff
path: root/usr.sbin/bgpd
AgeCommit message (Collapse)Author
2004-11-18embed two struct capabilities, one for the capas announced by the peer andHenning Brauer
one for the capas we announced him, into the session_up imsg to the RDE after brainstorming with claudio
2004-11-18add an instance of struct capabilities to peer_conf, and inheritHenning Brauer
peer->capa.ann from this
2004-11-18inside struct peer, replace the occurance of the older struct peer_capaHenning Brauer
by two instances of the new struct capabilities, one for announcements and one for the received capabilities
2004-11-18remove the global 'announce' flag from struct peer_capa, clearHenning Brauer
individual capability flags where needed
2004-11-18let peer->capa.mp_[v4|v6] contain the SAFI, don't just use it as boolHenning Brauer
2004-11-18Subsequent Address Family Indicators (SAFI) in hex and add SAFI_NONEHenning Brauer
2004-11-18struct capa_mp is not needed any more, spotted by claudioHenning Brauer
2004-11-18introduce session_capa_mp() which adds the multiprotocol announcementsHenning Brauer
to OPEN messages. eases session_open() quite a bit and kills duplicate code claudio ok
2004-11-18add code to announce support for IPv6 Unicast.Henning Brauer
disabled for now, claudio ok
2004-11-18it's oupsa oupsa oupsa time...Henning Brauer
writing to a member of a const struct is no good, so un-const struct peer for log_statechange()
2004-11-18supress logging of subsequent connect() failures as long as:Henning Brauer
-the session alternates between Active and Connect. Other states reset logging -the error is the same as the last connect() error seen jajajaja claudio
2004-11-11Unbreak peer_localaddr() because Link Local Addresses reported byClaudio Jeker
getifaddrs() have the scope id added to the address and so fuck up in the compare later. This part has bin stolen from ifconfig/ifconfig.c and shows the beauty of IPv6. Thank you KAME. disgusting but OK henning@
2004-11-11Unbreak link local IPv6 sessions by setting the correct scope_id inClaudio Jeker
addr2sa. OK henning@
2004-11-11Don't hardcode the prefix table to the IPv4 one, especially if there isClaudio Jeker
already code to select the correct tree by AF.
2004-11-11Pass the copied as-path attributes to the filter function and not theClaudio Jeker
original. Affected code is currently still unreachable.
2004-11-11spaces at EOL in comments, spotted by theoHenning Brauer
2004-11-11NOTREACHED not not reached! Stupid me.Claudio Jeker
2004-11-11Store the local v4 and v6 address of a session. For IPv4 sessions the firstClaudio Jeker
IPv6 address with global scope of the interface used by the session is used. In any case the local endpoint of the session is used for one of the two no matter what scope. OK henning@
2004-11-11New config statement "rde route-age [evaluate|ignore]". If set to evaluateClaudio Jeker
the best path selection will not only be based on the path attributes but also on the age of the prefix. This is an extension to the RFC. The default is ignore but previously it was implicitly set to evaluate. OK henning@ man page OK jaredy@ jmc@
2004-11-10prefix_write() works also for IPv6. OK henning@Claudio Jeker
2004-11-10It is not needed to mask the value wit 0xff as it is < 255. OK henning@Claudio Jeker
2004-11-10"not reached" does not help LINT use NOTREACHED instead and use it only inClaudio Jeker
places where needed. OK henning@
2004-11-10Remove no longer needed code. OK henning@Claudio Jeker
2004-11-09in the list of RIRs:Henning Brauer
-add LACNIC -RIPE serves more than just europe, and ARIN more than north america -order alphabetically From: Klaus Steding-Jessen <jessen@nic.br>
2004-11-05memleaks in error pathes, again awesome work from Patrick LatifiHenning Brauer
2004-11-04(try to) open the config file earlier, makes the error handling easier inHenning Brauer
case we cannot. in fact there was one missing free(), thus this diff plugs a little memory hole (without real-world relevance I guess). From Patrick Latifi, thanks!
2004-11-02don't leak mem on strlcpy failure, Patrick LatifiHenning Brauer
2004-11-02supress logging of the (likely very long) repeated Connect -> Active ->Henning Brauer
Connect -> Active state changes, just clutters logs, claudio ok
2004-11-02save the previous state in struct peer, claudio okHenning Brauer
2004-10-19fix printing of groups - instead of surrounding each neighbor statementHenning Brauer
which is part of a group by "group blah { .. }", so that each group decl occurs multiple times (that is valid, but confusing and ugly), stuff pointers to each peer into an a array and sort it based on group id. then print all neighbors whoch are not part of a group followed by each group with all its members. annoyed me for quite some time, now finally enough to sit down and fix it claudio ok
2004-10-19allow neighbor definitions to depend on interface state.Henning Brauer
with this, if a neighbor is configured as dependent on carp0 for example, the neighbor will remain in state IDLE as long as carp0 is not master. once carp0 becomes master the session(s) depending on it immediately go to CONNECT (or ACTIVE, if they're configured passive), reducing failover time. claudio ok, with some input from ryan as well
2004-10-16oups, unrelated changes crept inHenning Brauer
2004-10-16prefixlen 0 is a special case for prefixlen2mask() as well, claudio okHenning Brauer
2004-10-08Don't access pointers blindly. asp is NULL for withdraws. This fixes a rdeClaudio Jeker
crash noticed by Stefan Wahl and later by henning@. OK henning@
2004-10-07use a static, const and prefilled u_int8_t[16] to check wether the markerHenning Brauer
at the beginning of each BGP message is all 1s instead of looping and comparing one by one
2004-10-05reject an all zero bgpid, following a similar suggestion fromHenning Brauer
pascal.gloor@spale.com
2004-10-01if we're opening a socket for a default listener because no "listen on"Henning Brauer
stetements were found in the config file, and one fails with EPROTONOSUPPORT (this is the case for the default ::1 listener on machines without INET6), remove that listener and move on instead of bailing out. ok claudio
2004-09-28gcc-ism. We don't want it, we don't need it.Claudio Jeker
OK henning@ noticed by deraadt@
2004-09-28one m is enough in incoming, really ;)Henning Brauer
2004-09-28Add prepend-neighbor feature. Prepend the remote-as n times similar toClaudio Jeker
prepend-self. Only for incomming UPDATEs. OK henning@
2004-09-23after receival of a SIGCHLD reset io_pid or rde_pid, respectively, dependentHenning Brauer
on which child went away.
2004-09-22don't bother shrinking the pfd and index2peer arraysHenning Brauer
ok claudio
2004-09-17Fix log messageClaudio Jeker
2004-09-16imsg type is really an enum imsg_type and not an intHenning Brauer
2004-09-16when a cloned peer goes back to IDLE state, don't remove him immediatelyHenning Brauer
but keep him around for some more time (an hour here). fixes an issue Arvid was reporting: when a cloned neighbor rejects our OPEN message due to capability negotiation (or missing implementation of those), we set a marker and retry without. However, if we remove the peer immediately, it gets freshly cloned on the next trial, with default settings, thus including capability negotiation, and thus failes again. this will also help with route flap dampening. ok claudio
2004-09-16imsg API cleanup:Henning Brauer
-kill imsg_compose_pid, imsg_compose_fdpass and imsg_create_pid -extend the original imsg_compose/_create API to take pid & fd too -make imsg_compose do imsg_create + imsg_add + imsg_close instead of duplicating the code -adjust all callers to the new API ok claudio
2004-09-16minor KNFHenning Brauer
2004-09-16cope with ENOBUFS in buf_write()Henning Brauer
2004-09-16malloc the imsg buffers instead of having them staticly, suggested byHenning Brauer
micskye some time ago
2004-09-15if (signalflag) { dowork(); signalflag = 0; } is a race. First clear flag,Otto Moerbeek
then call work(). ok henning@