mod_portcheck: Include '*' in allowed characters so '*:port' works
authorKim Alvefur <zash@zash.se>
Sat, 19 Feb 2022 01:42:12 +0100
changeset 4903 adecfb36349e
parent 4902 999e7cb7f6d9
child 4904 cc5ac0f0f32d
mod_portcheck: Include '*' in allowed characters so '*:port' works
mod_portcheck/mod_portcheck.lua
--- a/mod_portcheck/mod_portcheck.lua	Fri Feb 18 23:40:41 2022 +0100
+++ b/mod_portcheck/mod_portcheck.lua	Sat Feb 19 01:42:12 2022 +0100
@@ -4,7 +4,7 @@
 local commands = module:shared("admin_shell/commands")
 
 function commands.portcheck(session, line)
-	for desc, interface, port in line:gmatch("%s(%[?([%x:.]+)%]?:(%d+))") do
+	for desc, interface, port in line:gmatch("%s(%[?([%x:.*]+)%]?:(%d+))") do
 		if interface == "*" then
 			interface = "0.0.0.0";
 		end