544 Commits
Author SHA1 Message Date
Pavel Tvrdik 6dc69a00f7 Use IP_ONESBCAST at FreeBSD
IP_ONESBCAST allows send universal broadcast via requested interface
using directed broadcast.
2016-04-06 15:57:14 +02:00
Pavel Tvrdík 9d4042a171 io.c: init some uninitialized variables 2016-03-30 17:16:12 +02:00
Pavel Tvrdík 51e8192c4c Clearness of code of usage variable argument lists
All cases are exiting from BIRD, so the patch is a little useless,
however it will be good for copiage of this code.
2016-03-30 17:11:17 +02:00
Pavel Tvrdík f6dd038802 Merge branch 'master' into birdtest 2015-11-12 16:20:37 +01:00
Pavel TvrdíkandOndrej Zajicek (work) fce764f90e Fix compiling with --enable-debug option 2015-11-11 11:46:38 +01:00
Jan Moskyto MatejkaandOndrej Zajicek (work) 9ddbfbddf8 Netlink: Allow more than 256 routing tables.
Since 2.6.19, the netlink API defines RTA_TABLE routing attribute to
allow 32-bit routing table IDs. Using this attribute to index routing
tables at Linux, instead of 8-bit rtm_table field.
2015-11-11 11:40:49 +01:00
Ondrej Zajicek (work) 9b9a7143c4 Conf: Fixes bug in symbol lookup during reconfiguration
Symbol lookup by cf_find_symbol() not only did the lookup but also added
new void symbols allocated from cfg_mem linpool, which gets broken when
lookups are done outside of config parsing, which may lead to crashes
during reconfiguration.

The patch separates lookup-only cf_find_symbol() and config-modifying
cf_get_symbol(), while the later is called only during parsing. Also
new_config and cfg_mem global variables are NULLed outside of parsing.
2015-11-09 00:42:02 +01:00
Ondrej Zajicek (work) 3aed0a6ff7 IO: Fix the previous bugfix
I should check it after making some trivial changes. The original patch
from Alexander has it right.
2015-11-03 11:27:27 +01:00
Ondrej Zajicek (work) 338f85ca77 IO: Handle fd values too big for select()
If the number of sockets is too much for select(), we should at least
handle it with proper error messages and reject new sockets instead of
breaking the event loop.

Thanks to Alexander V. Chernikov for the patch.
2015-11-03 11:08:57 +01:00
Ondrej Zajicek (work) acb04cfdc5 Minor changes 2015-10-17 14:43:37 +02:00
Pavel Tvrdík 810090517b _GNU_SOURCE for setresuid() 2015-08-19 14:57:54 +02:00
Pavel Tvrdík e96f1ea735 Make async_*_flag as global shared variables 2015-08-19 14:57:54 +02:00
Pavel Tvrdík 39059e21b7 Birdtest: Add unfinished filter test
Add birdtest utils for testing parsing configurations files
Add tests with parsing filter examples
2015-08-14 16:14:32 +02:00
Ondrej ZajicekandPavel Tvrdík 0f38795b33 Netlink: Fixes uninitialized variable
Thanks to Pavel Tvrdik for the bugfix
2015-08-13 14:38:41 +02:00
Pavel Tvrdík 856250c27f Birdtest: Purge 'int main()' from lib/birdlib.a #2
All origin static functions from sysdep/unix/main.c were rewrited to
non-static.

All origin static global variables from sysdep/unix/main.c was rewrited
to extern.

It is possible create executables bird, birdc and birdcl as well as run
unit tests without mockuping

After remake new BIRD's build system will be this commit reverting...
2015-08-05 12:36:40 +02:00
Pavel Tvrdík ce8d15a02d Birdtest: Purge 'int main()' from lib/birdlib.a #1
We need link lib/birdlib.a and remaining */all.o to tests (mockups suck)

Code from sysdep/unix/main.c is moved without 'int main()' function
   to the sysdep/unix/main_helper.c

Yes, it is dirty...
After remake new BIRD's build system will be this commit reverting...

Actually it is not possible to build executable bird, birdc nor birdcl
due duplicity of functions in main_helper.o in lib/birdlib.a and
lib/main.o
2015-08-05 12:36:40 +02:00
Pavel Tvrdík f594ab67bb Revert "Birdtest: U64_C() macro"
This reverts commit 804ee1458d.

And make better solution with stdint.h and UINT64_C macro.
Thanks to Ondrej Zajicek.
2015-08-04 10:31:50 +02:00
Pavel Tvrdík 804ee1458d Birdtest: U64_C() macro 2015-08-03 14:41:20 +02:00
Ondrej Zajicek 641172c6e5 Netlink: Fixes uninitialized variable
Thanks to Pavel Tvrdik for the bugfix
2015-07-28 12:36:03 +02:00
Ondrej Zajicek 8d9eef1771 BGP multipath support
Kernel option 'merge paths' allows to merge routes exported to kernel
protocol (currently BGP and static routes) to multipath routes.
2015-06-08 02:24:08 +02:00
Ondrej Zajicek 78a2cc289f KRT: Fixes some minor bugs in kernel protocol 2015-06-08 02:24:08 +02:00
Pavel TvrdíkandOndrej Zajicek ae80a2de95 unsigned [int] -> uint 2015-06-08 02:24:08 +02:00
Pavel TvrdíkandOndrej Zajicek e348ef01b4 unsgined char -> byte 2015-06-08 02:24:08 +02:00
Pavel Tvrdík ddb80bd8c5 unsigned [int] -> uint 2015-05-19 08:53:34 +02:00
Pavel Tvrdík 8e8a438322 unsgined char -> byte 2015-05-19 08:14:04 +02:00
Ondrej Zajicek 38e835dede Fix in the last commit 2015-05-13 13:19:26 +02:00
Ondrej Zajicek 9fdf9d29b6 KRT: Add support for plenty of kernel route metrics
Linux kernel route metrics (RTA_METRICS netlink route attribute) are
represented and accessible as new route attributes:

krt_mtu, krt_window, krt_rtt, krt_rttvar, krt_sstresh, krt_cwnd, krt_advmss,
krt_reordering, krt_hoplimit, krt_initcwnd, krt_rto_min, krt_initrwnd,
krt_quickack, krt_lock_mtu, krt_lock_window, krt_lock_rtt, krt_lock_rttvar,
krt_lock_sstresh, krt_lock_cwnd, krt_lock_advmss, krt_lock_reordering,
krt_lock_hoplimit, krt_lock_rto_min, krt_feature_ecn, krt_feature_allfrag
2015-05-12 16:42:22 +02:00
Ondrej Zajicek 7069fc9e72 KRT: Fixes route reload
Did not really worked
2015-04-25 21:41:43 +02:00
Ondrej Zajicek c5ff44a703 KRT: Fixes learning of preferred kernel routes.
When a new route was imported from kernel and chosen as preferred, then
the old best route was propagated as a withdraw to the kernel protocol.
Under some circumstances such withdraw propagated to the BSD kernel could
remove the new alien route and thus reverting the import.
2015-04-25 20:43:43 +02:00
Ondrej Zajicek 90097f4fb9 KRT: Support for RTM_CHANGE on BSD 2015-04-22 10:53:15 +02:00
Ondrej Zajicek deec752ef9 NEWS and version update 2015-04-20 12:27:00 +02:00
Ondrej Zajicek b867a87c2f Fixes port range socket option 2015-04-19 00:31:59 +02:00
Ondrej Zajicek 304ac2e861 Minor fixes 2015-04-12 10:47:17 +02:00
Ondrej Zajicek 16a3254c4c Understand IFF_MULTICAST flag on ifaces in Linux
Unfortunately, some interfaces support multicast but do not have
this flag set, so we use it only as a positive hint.

Thanks to Clint Armstrong for noticing the problem.
2015-03-31 23:59:40 +02:00
Ondrej Zajicek 9aed29e605 BGP: Enhanced route refresh (RFC 7313) support
Also hook feed_done is renamed to feed_end.
2015-03-29 18:29:49 +02:00
Ondrej Zajicek af454f9b7c Fixes bug in debug dumps
Using 'dump sockets' in IPv6 mode caused crash due to mismatched format string.

Thanks to Pavel Tvrdik for noticing it.
2015-03-02 09:42:44 +01:00
Ondrej Zajicek 8bcb5fb1e8 Implement latency tracking, internal event log and watchdog 2015-03-02 09:41:14 +01:00
Ondrej Zajicek 9c89560e6c Use IP_PORTRANGE_HIGH for BFD where available 2015-02-22 20:14:14 +01:00
Ondrej Zajicek 86c3eea0f3 Use AF_UNSPEC for RTM_GETLINK
This value is specified in documentation.
2015-02-21 21:19:49 +01:00
Ondrej Zajicek 2bbc308321 Store protocol config size inside protocol structure
Make proto_config_new() use this info instead of supplied size.

Thanks to Alexander V. Chernikov for the patch.
2015-02-21 21:08:23 +01:00
Pavel TvrdikandOndrej Zajicek e598853e68 Add const to a param msg at functions log_msg, log_rl, die, bug and debug 2015-02-21 19:32:57 +01:00
Pavel TvrdikandOndrej Zajicek 4a591d4b94 Replacing GNU old-style field designator extension 2015-02-21 19:31:36 +01:00
Ondrej Filip ec2194fa7a Version 1.5.0pre 2014-11-05 11:07:25 +01:00
Ondrej Zajicek 6f8bbaa10b Fininshing integrated OSPF. 2014-11-03 10:42:55 +01:00
Ondrej Zajicek 88a183c6c9 Integrated IP functions. 2014-10-24 11:11:43 +02:00
Ondrej Zajicek cfdea7b85f NEWS and version update. 2014-10-05 23:59:18 +02:00
Ondrej Zajicek 1123e70740 Implements token bucket filter for rate limiting. 2014-10-02 12:52:50 +02:00
Ondrej Zajicek 252c7e4d0b Refresh kernel protocol when interface disappears.
When an interface goes down, (Linux) kernel removes routes pointing to
that ifacem but does not send withdraws for them. We rescan the
kernel table to ensure synchronization.

Thanks to Alexander Demenshin for the bugreport.
2014-10-02 12:52:50 +02:00
Ondrej Zajicek 0479b44373 Fixes some warnings. 2014-10-02 12:52:50 +02:00
Ondrej Filip 7c00551749 Version 1.4.4. 2014-07-09 23:46:02 +02:00