Captive portal da farklı dns kullanan bilgisayarlarda login gelmemesi (çözüldü)
-
ihtiyacı olana yeni sürümde eklenmesi gekeren kod parçası:
$cprules .= "# Rules to allow DNS queries to external servers from unauthenticated users\n"; $cprules .= captiveportal_create_ipfw_rule("add", $rulenum, "allow udp from any to any 53 out"); $cprules .= captiveportal_create_ipfw_rule("add", $rulenum, "allow tcp from any to any 53 out"); $cprules .= captiveportal_create_ipfw_rule("add", $rulenum, "allow udp from any to any 53 in keep-state"); $cprules .= captiveportal_create_ipfw_rule("add", $rulenum, "allow tcp from any to any 53 in keep-state");
peki nereye eklenecek? tabiiki aşağıdaki kodun hemen üstüne:
$cprules .= "# redirect non-authenticated clients to captive portal\n"; $cprules .= captiveportal_create_ipfw_rule("add", $rulenum, "fwd 127.0.0.1,{$listenporthttp} tcp from any to any dst-port 80 in");
herkese iyi eğlenceler...