alangecker / bigbluebutton-docker

merged into https://github.com/bigbluebutton/docker
GNU Lesser General Public License v3.0
98 stars 33 forks source link

Setup script doesnt parse IPv4/v6 correctly #48

Closed trickert76 closed 4 years ago

trickert76 commented 4 years ago

I found out, that the IP 192.168.0.1 is not accepted by the regex. On the otherhand 300.300.300.300 is accepted. The same with the IPv6 regex, because it makes the v4 regex. I'm not able to enter a IPv6 address manually in the setup.

alangecker commented 4 years ago

ah thanks for reporing this issue!

I've just pushed a fix, it should work now: https://github.com/alangecker/bigbluebutton-docker/commit/2b28bac2fe7d969b41ea66c13cce2f23e4687075

it still matches a lot of invalid IP adresses like 300.300.300.300 or 2000a5::::f, so its only a rough validation, but at least all valid IP adresses should now be accepted.

exact validation is, escpecially for IPv6, quite unreadable... :D

source: https://helloacm.com/how-to-valid-ipv6-addresses-using-bash-and-regex/