Statistics
| Branch: | Revision:

iof-bird-daemon / sysdep / linux @ 153f02da

# Date Author Comment
153f02da 12/07/2017 12:06 PM Ondrej Zajicek (work)

Nest: Maintain separate IPv4, IPv6 and LLv6 preferred addresses

Also redesign preferred address selection and update protocols to use
appropriate preferred address.

Based on a previous work by Jan Maria Matejka.

a1f5e514 07/04/2017 09:36 PM Ondrej Zajicek (work)

Implement onlink flag for nexthops

Add proper support for per-nexthop onlink flag in routes to handle next
hop addresses that are not covered by interface IP ranges. Supported by
kernel and static protocols.

Thanks to Vincent Bernat for the idea.

734e9fb8 05/23/2017 11:12 AM Ondrej Zajicek (work)

Minor cleanups and fixes

d19617f0 05/17/2017 12:50 PM Ondrej Zajicek (work)

Merge remote-tracking branch 'origin/int-new' into int-new

05d47bd5 05/16/2017 01:34 PM Jan Moskyto Matejka

Linpool: default allocation size

525a88d8 05/09/2017 12:48 PM Ondrej Zajicek (work)

Merge branch 'master' into int-new

5d6dc930 05/09/2017 11:45 AM Ondrej Zajicek (work)

Some more autoconf cleanups

Replace integer type width detection with C99 fixed-width types.
Also remove some unused or obsolete code.

Thanks to Ruben Kerkhof for the patchset.

97e48b6a 04/12/2017 02:04 PM Jan Moskyto Matejka

Adding also our copy of struct rtvia.

54635f43 04/12/2017 02:04 PM Jan Moskyto Matejka

Include local lwtunnel.h unless found in system

bff21441 03/29/2017 02:10 PM Ondrej Zajicek (work)

Netlink: Change default kernel metric to 32

This avoids collisions with non-BIRD routes in kernel tables.

ed610044 03/29/2017 01:55 PM Ondrej Zajicek (work)

Netlink: Better handling of an error case

7074be22 03/28/2017 04:27 PM Ondrej Zajicek (work)

Netlink: Fix device route delete

d1b8fe93 03/28/2017 02:05 PM Ondrej Zajicek (work)

Netlink: Fix bug in RTA_PRIORITY handling

c609d039 02/22/2017 10:58 AM Jan Moskyto Matejka

Merge branch 'int-new' into nexthop-merged

62e64905 02/20/2017 01:26 AM Ondrej Zajicek (work)

Several minor fixes

c259669f 02/08/2017 01:34 PM Ondrej Zajicek (work)

Merge branch 'master' into int-new

d14f8c3c 12/22/2016 08:38 PM Jan Moskyto Matejka

Netlink: MPLS routes in kernel

Anyway, Bird is now capable to insert both MPLS routes and MPLS encap
routes into kernel.

It was (among others) needed to define platform-specific AF_MPLS to 28
as this constant has been assigned in the linux kernel.

No support for BSD now, it may be added in the future.

5b208e29 12/22/2016 12:09 PM Jan Moskyto Matejka

Removing (struct rta)->cast. Never used.

4e276a89 12/22/2016 12:01 PM Jan Moskyto Matejka

Merged multipath and single-path data structures.

Dropped struct mpnh and mpnh_*()
Now struct nexthop exists, nexthop_*(), and also included struct nexthop
into struct rta.

Also converted RTD_DEVICE and RTD_ROUTER to RTD_UNICAST. If it is needed
to distinguish between these two cases, RTD_DEVICE is equivalent to...

2c33da50 12/20/2016 07:36 PM Jan Moskyto Matejka

Netlink: fix occasional netlink hangs on busy machines

9b0a0ba9 11/09/2016 03:36 PM Ondrej Zajicek (work)

Unit Testing for BIRD

- Unit Testing Framework (BirdTest)
- Integration of BirdTest into the BIRD build system
- Tests for several BIRD modules
Based on squashed Pavel Tvrdik's int-test branch, updated for
current int-new branch.
8860e991 11/08/2016 06:27 PM Ondrej Zajicek (work)

Merge branch 'master' into int-new

c8cafc8e 11/08/2016 04:46 PM Ondrej Zajicek (work)

Minor code cleanups

cc5b93f7 11/08/2016 04:04 PM Ondrej Zajicek (work)

Merge tag 'v1.6.2' into int-new

3e236955 11/01/2016 01:52 PM Jan Moskyto Matejka

Build: switch on -Wextra, get rid of most of the warnings

There are several unresolved -Wmissing-field-initializers on older
versions of GCC than 5.1, all of them false positive.

ccd2a3ed 09/29/2016 11:21 AM Jan Moskyto Matejka

Kernel socket missing err_hook fix

Thanks to Tim Weippert for bugreport.

6e75d0d2 09/19/2016 10:29 AM Ondrej Zajicek (work)

KRT: Add krt_scope attribute

Add a new route attribute, krt_scope, to expose the Linux kernel route
scope. Constants from /etc/iproute2/rt_scopes (prefixed by "ips_") are
expected to be used with the attribute. Both import and export are
supported.

Also, the patch fixes device route export to the kernel, by setting link...

4adcb9df 09/15/2016 12:59 PM Ondrej Zajicek (work)

KRT: Add kernel metric protocol option

Kernel routes with different metrics do not clash with each other,
therefore using dedicated metric value is a reliable way to avoid
overwriting routes from other sources (e.g. kernel device routes).

Although kernel route metric could already be set as a route attribute by...

2feaa693 09/14/2016 09:53 AM Ondrej Zajicek (work)

KRT: Support for IPv6 ECMP

Linux represents IPv6 ECMP routes as a sequence of unipath routes with
the same prefix. We have to translate between our representation (one
route with multipath next hop) and the Linux representation in both
directions.

Proper learning of alien IPv6 ECMP routes still not supported....

f9f2e280 08/30/2016 10:43 AM Ondrej Zajicek (work)

KRT: Forbid path merging on BSD

We support ECMP routes only on Linux. Exported routes are checked in
krt_capable(), but a route generated during path merging avoids this
check.

a08a81c6 07/20/2016 01:31 PM Ondrej Zajicek (work)

Netlink: Fix build with older headers missing IFA_FLAGS

e37d2e3e 07/20/2016 01:06 PM Ondrej Zajicek (work)

Netlink: Ignore tentative addresses

Ignore tentative IPv6 addresses and wait until finish of Duplicate
Address Detection (We got notification when an address is no longer
tentative) to avoid problems when protocols try to use interfaces
with tentative link-local addresses....

08b3a24d 05/17/2016 01:21 PM Ondrej Zajicek (work)

IO: Minor changes in socket AF handing

AF can be specified implicitly by saddr or daddr, flags SKF_V4ONLY and
SKF_V6ONLY are to be removed.

af678af0 05/12/2016 04:03 PM Ondrej Zajicek (work)

Merge remote-tracking branch 'origin/master' into int-new

31e9e101 05/10/2016 02:05 PM Stijn Tintel

netlink: update struct msghdr

The netlink code assumes an order for the members of struct msghdr.
This breaks recvmsg and sendmsg with musl libc on mips64. Fix this by
using designated initializers instead.

Signed-off-by: Stijn Tintel <>

0c6dfe52 05/10/2016 12:30 PM Jan Moskyto Matejka

Merge branch 'int-new' into int-new-merged

a8caff32 05/10/2016 12:08 PM Jan Moskyto Matejka

Portability: Fixed C extension error generated by CLang.

sysdep/linux/netlink.c:921:10: error: fields must have a constant size:
'variable length array in structure' extension will never be supported
char buf[128 + KRT_METRICS_MAX*8 + nh_bufsize(a->nexthops)];...

7152e5ef 05/10/2016 12:07 PM Jan Moskyto Matejka

Build system reworked to one global Makefile with includes and no nesting

Also removed the lib-dir merging with sysdep. Updated #include's
accordingly.

Fixed make doc on recent Debian together with moving generated doc into
objdir.

Moved Makefile.in into root dir...

a7baa098 04/13/2016 12:37 PM Ondrej Zajicek (work)

BSD: Add the IPsec SA/SP database entries control

Add code for manipulation with TCP-MD5 keys in the IPsec SA/SP database
at FreeBSD systems. Now, BGP MD5 authentication (RFC 2385) keys are
handled automatically on both Linux and FreeBSD.

Based on patches from Pavel Tvrdik.

7a7ac656 04/08/2016 10:28 AM Jan Moskyto Matejka

Merge branch 'master' into int-new-channels

e86cfd41 04/06/2016 09:46 AM Ondrej Zajicek (work)

KRT: Fix route learn scan when route changed

When a kernel route changed, function krt_learn_scan() noticed that and
replaced the route in internal kernel FIB, but after that, function
krt_learn_prune() failed to propagate the new route to the nest, because...

f4a60a9b 02/01/2016 09:28 AM Ondrej Zajicek (work)

Channels - explicit links between protocols and tables

The patch adds support for channels, structures connecting protocols and
tables and handling most interactions between them. The documentation is
missing yet.

6ffa8f53 01/11/2016 08:29 AM Jan Moskyto Matejka

Hidden AF_INET* inside sysdep/

e691d16a 12/29/2015 04:12 PM Ondrej Zajicek (work)

Explicit ip4_addr / ip6_addr printf support

9a70c8d6 12/29/2015 12:02 PM Jan Moskyto Matejka

Netlink: Removed forgotten if-stub (caused strange errors)

0bf95f99 12/21/2015 04:17 PM Ondrej Zajicek (work)

Follow-up work on integration

Contains some patches from Jan Moskyto Matejka

23c212e7 12/21/2015 02:33 AM Ondrej Zajicek (work)

Follow-up work on integration

29a64162 12/20/2015 03:58 PM Ondrej Zajicek (work)

KRT: Integration of IPv4/IPv6 in sysdep/linux

d7661fbe 12/19/2015 02:57 PM Jan Moskyto Matejka

Removed BITS_PER_IP_ADDRESS, MAX_PREFIX_LENGTH, BIRD_AF

Explicit setting of AF_INET(6|) in IP socket creation. BFD set to listen
on v6, without setting the V6ONLY flag to catch both v4 and v6 traffic.

Squashing and minor changes by Ondrej Santiago Zajicek

9b136840 12/18/2015 07:03 PM Jan Moskyto Matejka

Netlink and BSD: Integrating IPv4 and IPv6

Squashing and minor changes by Ondrej Santiago Zajicek

04ae8dda 11/25/2015 01:24 PM Ondrej Zajicek (work)

Merge branch 'master' into int-new

ad276157 11/24/2015 01:30 PM Jan Moskyto Matejka

Netlink: attribute validation before parsing

Wanted netlink attributes are defined in a table, specifying
their size and neediness. Removing the long conditions that did the
validation before.

Also parsing IPv4 and IPv6 versions regardless on the IPV6 macro.

1e4891e4 11/23/2015 10:13 AM Ondrej Zajicek (work)

Nest: Fix bug in device proto

If an interface address notification is received during device protocol
shutdown/restart, BIRD crashed.

Thanks to Wei Huang for the bugreport.

fce764f9 11/11/2015 10:46 AM Pavel Tvrdík

Fix compiling with --enable-debug option

9ddbfbdd 11/11/2015 10:40 AM Jan Moskyto Matejka

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.

fe9f1a6d 11/05/2015 11:48 AM Ondrej Zajicek (work)

Initial commit on integrated BIRD

New data types net_addr and variants (in lib/net.h) describing
network addresses (prefix/pxlen). Modifications of FIB structures
to handle these data types and changing everything to use these
data types instead of prefix/pxlen pairs where possible....

acb04cfd 10/17/2015 12:43 PM Ondrej Zajicek (work)

Minor changes

641172c6 07/28/2015 10:36 AM Ondrej Zajicek

Netlink: Fixes uninitialized variable

Thanks to Pavel Tvrdik for the bugfix

78a2cc28 06/08/2015 12:24 AM Ondrej Zajicek

KRT: Fixes some minor bugs in kernel protocol

ae80a2de 06/08/2015 12:24 AM Pavel Tvrdík

unsigned [int] -> uint

38e835de 05/13/2015 11:19 AM Ondrej Zajicek

Fix in the last commit

9fdf9d29 05/12/2015 02:42 PM Ondrej Zajicek

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,...

16a3254c 03/31/2015 09:59 PM Ondrej Zajicek

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.

86c3eea0 02/21/2015 08:19 PM Ondrej Zajicek

Use AF_UNSPEC for RTM_GETLINK

This value is specified in documentation.

1123e707 10/02/2014 10:52 AM Ondrej Zajicek

Implements token bucket filter for rate limiting.

8945f73d 06/26/2014 11:30 AM Ondrej Zajicek

Ensures that msg_controllen includes last padding.

Although RFC 3542 allows both cases, Theo de Raadt thinks
he knows better, and msg_controllen without last padding
fails on OpenBSD.

Thanks to Job Snijders for the bugreport.

05476c4d 05/18/2014 09:42 AM Ondrej Zajicek

IPv4/IPv6 integrated socket code.

eb5ea6bd 03/31/2014 11:21 AM Ondrej Zajicek

Fixes build on some old systems.

3216eb03 02/26/2014 11:52 AM Ondrej Zajicek

Fixes longstanding issue with interfaces staying in IF_TMP_DOWN.

Thanks to Pierluigi Rolando and others for the bugreport.

48e5f32d 02/06/2014 04:46 PM Ondrej Zajicek

Many changes in I/O and OSPF sockets and packet handling.

I/O:
- BSD: specify src addr on IP sockets by IP_HDRINCL
- BSD: specify src addr on UDP sockets by IP_SENDSRCADDR
- Linux: specify src addr on IP/UDP sockets by IP_PKTINFO
- IPv6: specify src addr on IP/UDP sockets by IPV6_PKTINFO...

283c7dfa 11/25/2013 05:42 PM Ondrej Zajicek

Merge branch 'master' into add-path

e237b28a 11/25/2013 12:21 AM Ondrej Zajicek

Changes primary addr selection on BSD to respect SIOCGIFADDR ioctl() result.

Thanks to Alexander V. Chernikov for the original patch.

65194bd1 11/23/2013 09:48 PM Ondrej Zajicek

Removes workaround related to import of kernel device routes.

Thanks to Benjamin Cama for notification.

736e143f 11/23/2013 10:50 AM Ondrej Zajicek

Merge branch 'master' into add-path

Conflicts:

filter/filter.c
nest/proto.c
nest/rt-table.c
proto/bgp/bgp.h
proto/bgp/config.Y
f83ce94d 09/26/2013 03:33 PM Ondrej Zajicek

Fixes missing unregister of kernel table handling code.

And some minor fixes.

Thanks to Sergey Popovich for the patch.

c6964c30 07/04/2013 04:02 PM Ondrej Zajicek

Makes krt.c much more readable.

70e212f9 06/25/2013 01:39 PM Ondrej Zajicek

Implements TTL security for OSPF and RIP.

Interfaces for OSPF and RIP could be configured to use (and request)
TTL 255 for traffic to direct neighbors.

Thanks to Simon Dickhoven for the original patch for RIPng.

ef4a50be 06/24/2013 02:37 PM Ondrej Zajicek

Better packet priority and traffic class handling.

Implements support for IPv6 traffic class, sets higher priority for OSPF
and RIP outgoing packets by default and allows to configure ToS/DS/TClass
IP header field and the local priority of outgoing packets.

9810d055 05/28/2013 08:44 AM Ondrej Zajicek

Fixes problems with routing table scans on some platforms.

Negative bit shifts are definitely undefined oprations.

094d2bdb 08/14/2012 02:46 PM Ondrej Zajicek

Implements ADD-PATH extension for BGP.

Allows to send and receive multiple routes for one network by one BGP
session. Also contains necessary core changes to support this (routing
tables accepting several routes for one network from one protocol).
It needs some more cleanup before merging to the master branch.

c06de722 08/06/2012 09:09 AM Ondrej Zajicek

Some minor fixes.

47c447c4 05/11/2012 10:10 AM Ondrej Zajicek

Minor cleanups.

95616c82 05/04/2012 02:38 PM Ondrej Zajicek

Cleanup in sysdep KRT code, part 4.

Adding some files that was accidentally removed
(instead of moved) in cleanup part 2.

f1aceff5 04/30/2012 08:25 PM Ondrej Zajicek

Cleanup in sysdep KRT code, part 2.

Remove support for historic Linux kernels,
merge krt-iface, krt-set and krt-scan stub headers.

396dfa90 04/30/2012 01:31 PM Ondrej Zajicek

Cleanup in sysdep KRT code, part 1.

OS-dependent functions renamed to be more consistent,
prepared to merge krt-set and krt-scan headers.

Name changes:

struct krt_if_params -> struct kif_params
struct krt_if_status -> struct kif_status
struct krt_set/scan_params -> struct krt_params...

3589546a 04/24/2012 09:37 PM Ondrej Zajicek

Merge commit 'origin/master'

334a0ed2 04/21/2012 09:00 AM Ondrej Zajicek

Fixes missing device attributes when exporting routes to kernel.

Thanks to Howden Nick for the bugreport.

f93e6f33 04/19/2012 03:14 PM Ondrej Filip

Small clean up in debug texts

c9df01d3 03/25/2012 05:44 PM Ondrej Zajicek

Fixes several minor bugs in kernel syncer.

9ba2798c 03/23/2012 04:22 PM Ondrej Zajicek

Adds krt_metric linux route attribute.

732a0a25 01/23/2012 12:26 AM Ondrej Zajicek

Fixes problems with creating/removing/renaming ifaces on BSD.

4b3a8ff8 01/09/2012 03:57 PM root

Extend buffer for netlink messages.

a7f23f58 11/06/2011 11:31 PM Ondrej Zajicek

Implements protocol templates.

Based on the patch from Alexander V. Chernikov.
Extended to support almost all protocols.
Uses 'protocol bgp NAME from TEMPLATE { ... }' syntax.

32f95476 10/06/2011 08:48 PM Ondrej Zajicek

Signal problems with route installation to kernel tables.

b1b19433 08/16/2011 09:13 PM Ondrej Zajicek

The generalized TTL security mechanism (RFC 5082) support.

Thanks to Alexander V. Chernikov for the patch.

aca0e79f 07/29/2011 12:52 PM root

Handles missing macro.

e8b89a61 05/15/2011 02:29 PM Ondrej Zajicek

Update and document the privilege restriction.

1bc26957 05/10/2011 12:42 AM Ondrej Zajicek

Allows run with restricted privileges.

Adds option -u and -g to specify user and group.
When different user (than root) is specified,
linux capabilities CAP_NET_* are kept.

71ca7716 04/13/2011 10:32 AM Ondrej Zajicek

Adds support for several Linux kernel route attributes.

83696b39 03/29/2011 12:44 AM Ondrej Zajicek

Hide 6to4 route warnings.