- os.execute("luci-splash lease "..mac.." >/dev/null 2>&1")
- luci.http.redirect(luci.model.uci.cursor():get("freifunk", "community", "homepage"))
+ uci:foreach("luci_splash", "blacklist",
+ function(s) if s.mac:lower() == mac or s.mac == mac then blacklisted = true end
+ end)
+ if blacklisted then
+ luci.http.redirect(luci.dispatcher.build_url("splash" ,"blocked"))
+ else
+ os.execute("luci-splash lease "..mac.." >/dev/null 2>&1")
+ luci.http.redirect(luci.model.uci.cursor():get("freifunk", "community", "homepage"))
+ end