summaryrefslogtreecommitdiffstats
path: root/bgpd
Commit message (Collapse)AuthorAgeFilesLines
* [bgpd] Fixed as-path prepend/exclude ASN handlingDenis Ovsienko2009-06-182-5/+5
| | | | | | | | | - aspath_gettoken(): use as_t to fix 4-byte ASN scanning (bug #484) - set_aspath_prepend_cmd(): use CMD_AS_RANGE in message to match actual range - no_set_aspath_prepend_val_cmd(): idem - set_aspath_exclude_cmd(): idem - no_set_aspath_exclude_val_cmd(): idem
* BGP Community Deletion BugMichael Lambert2009-05-211-1/+1
| | | | | | | | The attached patch was already posted to the list once (thanks to whoever found it first). However, it never made it into the code base. It is a severe to critical bug affecting community deletions on 64-bit machines and is bug #515 in bugzilla.
* BGP make message lists read onlyStephen Hemminger2009-05-152-16/+16
|
* BGP main program cleanupStephen Hemminger2009-05-151-7/+11
| | | | | Check result of daemon() call to fix warning Make local variables static
* BGP make ecommunity variables/functions localStephen Hemminger2009-05-152-3/+2
|
* BGP make some damp function staticStephen Hemminger2009-05-152-6/+5
|
* BGP make community hash table staticStephen Hemminger2009-05-151-1/+1
|
* BGP make message list in bgp_open constStephen Hemminger2009-05-151-4/+6
|
* BGP make receive capability staticStephen Hemminger2009-05-151-1/+1
|
* BGP make flag action table read-onlyStephen Hemminger2009-05-152-7/+7
| | | | | This table should be read-only. Also, comment out some unused code.
* BGP aspath eliminate dead codeStephen Hemminger2009-05-152-3/+5
|
* BGP make some bgp_attr functions staticStephen Hemminger2009-05-152-7/+2
|
* Make BGP FSM table read-only staticStephen Hemminger2009-05-151-1/+1
| | | | The finite state machine table is immutable.
* BGP make attribute variables localStephen Hemminger2009-05-151-5/+5
| | | | | Message lists can be read-only, and hash tables are local to this code.
* Fix compile warningsStephen Hemminger2009-05-151-4/+5
| | | | Fix printf format warning and make capability table 'const static'
* Bgp socket use static initializationStephen Hemminger2009-05-151-6/+5
| | | | Save a little code, getaddrinfo hint can be static initialized.
* Remove assertion when route clears and peer !EstablishedStephen Hemminger2009-05-151-13/+0
| | | | | | It is possible on BGP shutdown for routes to finish clearing while peer is waiting deletion. Therefore the assertion check in bgp_clear_route can be deleted.
* Reference count BGP instanceStephen Hemminger2009-05-143-6/+42
| | | | | | | | | Bug 3436 Add reference counting on BGP structure. Don't free BGP instance until all peer's are deleted. Fix memory leak where self reference created but never freed
* Revert "Wait for peers to clear on BGP shutdown"Stephen Hemminger2009-05-133-15/+0
| | | | This reverts commit 732ebcdfad6e3a786386e38a126c84477d192105.
* Wait for peers to clear on BGP shutdownStephen Hemminger2009-05-113-0/+15
| | | | | | Bugfix 3436 Wait for all items in the peer clear queue to finish before deleting BGP instance.
* Make declarations matchStephen Hemminger2009-05-081-2/+2
| | | | These variables are const.
* Be safer in bgp_terminateStephen Hemminger2009-05-081-2/+6
| | | | | bgp_terminate is used when process SIGHUP, clear workqueue references after freeing them.
* avoid zombie accepted peer entriesTimo Teräs2009-05-071-0/+2
| | | | | | | | | | | Currently, when accepting the connection, it can be left as zombie, when the peer just initiates a connection, but never sends data (and the TCP connection end packets are lost). This happens because for accepted connections a temporary new peer entry is created until OPEN message is exchanged, and this temporary peer entry does not get the hold time parameter set at all. Signed-off-by: Timo Teras <timo.teras@iki.fi>
* Fix "show ip bgp dampened-paths" garbage output.Chris Caputo2009-05-063-10/+8
| | | | | | | | | | | | | | | | | * bgpd/bgp_damp.c: Make bgp_damp_reuse_time_vty() accept a buffer and length, rather than returning a local var buffer whose contents can get trounced. Remove duplicate BGP_UPTIME_LEN define. * bgpd/bgp_damp.h: bgp_damp_reuse_time_vty() prototype change. * bgpd/bgp_route.c: Provide bgp_damp_reuse_time_vty() with a buffer and length. Remove duplicate BGP_UPTIME_LEN define. This problem was noticed in 2005... http://hibernia.jakma.org/~paul/patches/quagga-test.diff ...but the fix didn't make it into the code. Signed-off-by: Chris Caputo <ccaputo at alt.net>
* Compiler warning fixes for when --enable-snmp is configured.Chris Caputo2009-05-061-15/+22
| | | | | Compiled on 32-bit and 64-bit linux gcc 4.1.2 platforms. No run-time testing on 32-bit and limited run-time testing on 64-bit.
* Expanding asn path bufferStephen Hemminger2009-04-301-53/+27
| | | | | | | | Based on: [bgpd] AS4 bugfix by Chris Caputo <ccaputo@alt.net> * bgpd/bgp_aspath.c: (aspath_make_str_count) "assert (len < str_size)" was getting hit under certain 4-byte ASN conditions. New realloc strategy.
* Handle large ASN print formattingDenis Ovsienko2009-04-309-31/+31
| | | | | "%d" -> "%u" 4-byte ASN corrections. Prevent negative number when ASN is above 2^31.
* Align bgp with upstreamStephen Hemminger2009-02-096-4/+16
|
* Convert XMALLOC/memset to XCALLOCStephen Hemminger2009-02-092-16/+7
| | | | Simple conversion of XMALLOC/memset to XCALLOC
* whitespace fixStephen Hemminger2009-02-091-1/+1
|
* Merge branch 'vyatta-update' of /home/shemminger/src/quagga into jennerStephen Hemminger2009-02-0912-32/+32
|\
| * bgp: change () to (void)Stephen Hemminger2009-02-0912-32/+32
| | | | | | | | | | Use Ansi-C prototypes rather than old K&R method of declaring function without arguments
* | Use XCALLOC instead of XMALLOC/memsetStephen Hemminger2008-12-011-6/+2
| | | | | | | | A couple more trivial optimization.
* | Merge branch 'master' of /home/shemminger/src/quagga into jennerStephen Hemminger2008-12-011-0/+31
|\| | | | | | | | | | | Conflicts: lib/checksum.c
| * [bgpd] Add 'show bgp views' commandMichael Lambert2008-11-161-0/+31
| | | | | | | | | | | | | | | | * bgp_vty.c: (show_bgp_views_cmd) new command to list all defined views. (with small edits by Paul Jakma) Signed-off-by: Paul Jakma <paul@quagga.net>
* | Merge in latest quagga (0.99.11)Stephen Hemminger2008-10-2710-3999/+177
|\ \ | | | | | | | | | Merge in current upstream version of quagga.
| * | Merge branch 'master' of /home/shemminger/src/quagga into upstreamStephen Hemminger2008-10-1320-4032/+299
| |\| | | | | | | | | | Resolve all conflicts by using upstream version.
| | * Merge branch 'bgpd/fsm'Paul Jakma2008-10-021-4/+5
| | |\
| | | * [bgpd] Allow accepted peers to progress even if realpeer is in ConnectPaul Jakma2008-09-091-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * bgpd/bgp_packet.c: (bgp_open_receive) Try fix the little race in the FSM, where a accept-peer that progress faster than realpeer gets closed down if realpeer is still just in Connect, by allowing the realpeer to be bgp_stop'ed and doing the regular swapping-of-FSM state.
| | * | [bgpd] Fix definition of an rsclient commandMichael Lambert2008-09-241-1/+1
| | |/ | | | | | | | | | | | | | | | | | | * bgp_route.c: (show_ip_bgp_view_rsclient_route_cmd) Add the missing "ip" to the command string. Signed-off-by: Paul Jakma <paul@quagga.net>
| | * [bgpd] Document the FSM dummy-peer race that sometimes afflicts session setupPaul Jakma2008-09-061-0/+45
| | | | | | | | | | | | | | | | | | | | | * bgp_packet.c: (bgp_open_receive) the accept-peer hack can sometimes cause a race between two peers that try to establish sessions to each other, causing session setup to fail when it should have succeeded. In the worst case, the race can 'loop', causing prolonged failure to establish sessions.
| | * Merge branch 'restricted-mode'Paul Jakma2008-09-043-0/+96
| | |\
| | | * [vty] Add support for a 'restricted mode' with anonymous vty connectionsPaul Jakma2008-08-233-0/+96
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lib/command.h: Add a RESTRICTED_NODE, intended for use with anonymous, 'no login' vtys, to provide a subset of 'view' mode commands. * lib/command.c: Add RESTRICTED_NODE bits, nothing special, just following VIEW_NODE. * lib/vty.c: (vty_auth) enable authentication should fall back to restricted/view node as appropriate. (vty_create) init vty's to restricted/view node as appropriate, for the 'no login' case. (vty_{no_,}restricted_mode_cmd) config commands to enable 'anonymous restricted' in vty configuration. (vty_config_write) 'anonymous restricted' config. (vty_init) Install some commands to restricted mode, and the 'anonymous restricted' config commands into VTY_NODE. * bgpd/*.c: Install some of the safe(r) BGP commands into 'restricted mode', i.e. lookup commands of non-sensitive data. Useful with looking-glass route-servers.
| | | |
| | | \
| | *-. \ Merge commit 'remotes/jocke/ospf_neighbour'; commit ↵Paul Jakma2008-09-011-1/+3
| | |\ \ \ | | | | |/ | | | |/| | | | | | 'remotes/jocke/snmp_crosscompile'
| | | | * Make --enable-snmp cross compile and make libcrypto optional with ↵Joakim Tjernlund2008-08-251-1/+3
| | | |/ | | | | | | | | | | | | | | | | | | | | | | | | --without-crypto Autoconfig work by me, the rest was done by "Kirill K. Smirnov" <lich@math.spbu.ru>
| | * / Revert "[bgpd] Add 'bgp open-accept' option, to send OPEN immediately on ↵Paul Jakma2008-08-264-38/+1
| | |/ | | | | | | | | | | | | | | | | | | | | | accepted conns" Revert commit d664ae1182c29b74b409bc8594b7bd0575e91ce9. An experimental patch which violates RFC4271 quite badly, but managed to accidently sneak its way in.
| | * [administrivia] Update gitignore filesPaul Jakma2008-08-221-1/+1
| | | | | | | | | | | | - Add more stuff, archive libraries, etc..
| | * [administrivia] Git should ignore backup files and .loT filesPaul Jakma2008-08-221-0/+3
| | |
| | * [trivia] Remove ChangeLog files, as this data is now maintained in SCMPaul Jakma2008-08-221-3992/+0
| | |
| | * [bgpd] remove useless check and return in bgp_config_write_dampStephen Hemminger2008-08-222-26/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2008-08-17 Stephen Hemminger <stephen.hemminger@vyatta.com> * bgp_damp.?: (bgp_config_write_damp) remove useless check of statically allocated config storage, and useless return value Signed-off-by: Paul Jakma <paul@quagga.net>