Bug #17107
openbridge configured without an IP causes issue with custom src interface in System Logs > Settings
0%
Description
If you have:
- a single-member bridge configured (commonly for a span/mirror port for packet sniffing) and
- Status > System Logs > Settings > Remote Logging Options > Enable Remote Logging > Send log messages to remote syslog server enabled and
- a custom interface selected for Source Address
…you'll notice that whatever interface you've chosen does get saved to config.xml, but will not be reflected in the GUI after switching to another page or logging out and back in:
This is due to a subtle bug in the link_interface_to_bridge() function combined with the PHP code in status_logs_settings.php that does not account for bridge interfaces without a configured IP. This results in `null` being returned when displaying the options menu, showing "Default (any)" instead of the chosen interface.
Patch fixes this, adding an optional arg to link_interface_to_bridge to specify not to return results for bridges with no configured v4 or v6
short writeup + patch, with screenshots: https://gist.github.com/luckman212/46cff39b610cedde610cca70bd674597
Files
→L Updated by → luckman212 about 9 hours ago
Probably affects CE as well, I didn't test…
→L Updated by → luckman212 about 8 hours ago
Oh, and as far as this…
- "Finds out a bridge group" just sounded a bit strange
- INPUTS was wrong, it's not $ip it's $int
- there's no arbitrary 99 limit on bridge if numbering to my knowledge