Bird 2.0 includes IPv4 and IPv6 support in a single daemon.
When UNIFIED_DAEMON is set to True, queries are always done with the
"ipv4" backend (which handles both protocols), and distinctions between
IPv4 and IPv4 are removed in the UI.
The current parsing method (ugly regexp) is hard to understand and prone
to breakage:
- Bird 1.4 changed the date format, which broke the parser ()
- Bird 2.0 changed the format of the "Table" field, which again broke the parser (#36)
The new method is much simpler, does not involve any regexp, and should
thus resist small syntax changes in Bird's output.
Important limitation: parsing will be messed up if the date contains a
space character. There is no space in the default date format of Bird
(checked with Bird 1.3 to Bird 2.0), but since the date format is
configurable in Bird, it may happen anyway. In particular, setting
"timeformat protocol iso long" in Bird will break bird-lg's parser.
Fixes#36
The current parsing method (ugly regexp) is hard to understand and prone
to breakage:
- Bird 1.4 changed the date format, which broke the parser ()
- Bird 2.0 changed the format of the "Table" field, which again broke the parser (#36)
The new method is much simpler, does not involve any regexp, and should
thus resist small syntax changes in Bird's output.
Important limitation: parsing will be messed up if the date contains a
space character. There is no space in the default date format of Bird
(checked with Bird 1.3 to Bird 2.0), but since the date format is
configurable in Bird, it may happen anyway. In particular, setting
"timeformat protocol iso long" in Bird will break bird-lg's parser.
Fixes#36
Add the options
```BIND_IP = "0.0.0.0"
BIND_PORT = 5000```
which allows to bind lgproxy.py to an IP/interface.
As ports on routers shouldn't be exposed too much, it probably also makes sense to others to have this function. Tested.