diff -Nur -x '*.orig' -x '*.rej' smeserver-coova-chilli-0.2/root/etc/e-smith/templates/opt/chilli/hotspotlogin-conf.pl/all mezzanine_patched_smeserver-coova-chilli-0.2/root/etc/e-smith/templates/opt/chilli/hotspotlogin-conf.pl/all --- smeserver-coova-chilli-0.2/root/etc/e-smith/templates/opt/chilli/hotspotlogin-conf.pl/all 2010-07-29 13:54:12.000000000 +0200 +++ mezzanine_patched_smeserver-coova-chilli-0.2/root/etc/e-smith/templates/opt/chilli/hotspotlogin-conf.pl/all 2010-07-29 13:53:43.000000000 +0200 @@ -1,4 +1,4 @@ -$conf\{companyname\} = "{"$DomainName";}"; +$conf\{domain\} = "{"$DomainName";}"; $conf\{contactinfo\} = "admin\@{"$DomainName";}"; $conf\{uamsecret\} = "{($chilli{'uamsecret'} || 'azerty');}"; $conf\{userpassword\} = 1; diff -Nur -x '*.orig' -x '*.rej' smeserver-coova-chilli-0.2/root/opt/chilli/cgi-bin/hotspotlogin.cgi mezzanine_patched_smeserver-coova-chilli-0.2/root/opt/chilli/cgi-bin/hotspotlogin.cgi --- smeserver-coova-chilli-0.2/root/opt/chilli/cgi-bin/hotspotlogin.cgi 2008-09-02 14:06:16.000000000 +0200 +++ mezzanine_patched_smeserver-coova-chilli-0.2/root/opt/chilli/cgi-bin/hotspotlogin.cgi 2010-07-29 13:51:59.000000000 +0200 @@ -37,12 +37,11 @@ # Login page need https if (!($ENV{HTTPS} =~ /^on$/)) { - print "Content-type: text/html\n\n -$conf{companyname}/title> +<title>$conf{domain}/title> <meta http-equiv=\"Cache-control\" content=\"no-cache\"> <meta http-equiv=\"Pragma\" content=\"no-cache\"> <link rel=\"stylesheet\" type=\"text/css\" href=\"/chilli/css/sme.css\" /> @@ -55,25 +54,37 @@ } $loginpath = $ENV{'SCRIPT_NAME'}; - - # Make sure that the form parameters are clean $OK_CHARS='-a-zA-Z0-9_.@&=%!'; -$| = 1; -if ($ENV{'CONTENT_LENGTH'}) { - read (STDIN, $_, $ENV{'CONTENT_LENGTH'}); -} +$_ = (<STDIN> || ''); s/[^$OK_CHARS]/_/go; $input = $_; # Make sure that the get query parameters are clean $OK_CHARS='-a-zA-Z0-9_.@&=%!'; -$_ = $query=$ENV{'QUERY_STRING'}; +$_ = $query=$ENV{QUERY_STRING}; s/[^$OK_CHARS]/_/go; $query = $_; + + + + #Read form parameters which we care about @array = split('&',$input); +$replyencoded = ''; +$username = ''; +$password = ''; +$challenge = ''; +$button = ''; +$res = ''; +$uamip = ''; +$uamport = ''; +$userurl = ''; +$timeleft = ''; +$redirurl = ''; +$mac = ''; + foreach $var ( @array ) { @array2 = split('=',$var); @@ -81,8 +92,6 @@ if ($array2[0] =~ /^Password$/) { $password = $array2[1]; } if ($array2[0] =~ /^challenge$/) { $challenge = $array2[1]; } if ($array2[0] =~ /^button$/) { $button = $array2[1]; } - if ($array2[0] =~ /^logout$/) { $logout = $array2[1]; } - if ($array2[0] =~ /^prelogin$/) { $prelogin = $array2[1]; } if ($array2[0] =~ /^res$/) { $res = $array2[1]; } if ($array2[0] =~ /^uamip$/) { $uamip = $array2[1]; } if ($array2[0] =~ /^uamport$/) { $uamport = $array2[1]; } @@ -107,12 +116,10 @@ # This should be changed in 'standard' cgi script also if ($array2[0] =~ /^reply$/) { $replyencoded = $array2[1]; } - if ($array2[0] =~ /^userurl$/) { $userurl = $array2[1]; } if ($array2[0] =~ /^timeleft$/) { $timeleft = $array2[1]; } if ($array2[0] =~ /^redirurl$/) { $redirurl = $array2[1]; } if ($array2[0] =~ /^mac$/) { $mac = $array2[1]; } - if ($array2[0] =~ /^nasid$/) { $nasid = $array2[1]; } } # This should be added to 'standard' cgi script also @@ -338,7 +345,7 @@ function popUp(URL) { if (self.name != \"chillispot_popup\") { - chillispot_popup = window.open(URL, 'chillispot_popup', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=500,height=300'); + chillispot_popup = window.open(URL, 'chillispot_popup', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=500,height=310'); } } @@ -394,15 +401,14 @@ } function doOnBeforeUnLoad(result) { if ((result==12) && (self.name=='chillispot_popup')) { - document.location.href=('http://$uamip:$uamport/logoff'); + document.location.href=('http://$uamip:$uamport/logoff'); window.close(); } } function fillGuestAccess() { form1.UserName.value = 'guest'; - form1.Password.value='guest'; - + form1.Password.value = 'guest'; } </script> @@ -425,7 +431,7 @@ <INPUT TYPE=\"hidden\" NAME=\"userurl\" VALUE=\"$userurldecode\"> <INPUT TYPE=\"hidden\" NAME=\"mac\" VALUE=\"$mac\"> - <table style=\"width: 170px;\"> + <table style=\"width: 570px;\"> <tr> <td align=\"right\">$lang{username}:</td> <td><input type=\"text\" name=\"UserName\" size=\"14\" maxlength=\"128\"></td> @@ -446,7 +452,7 @@ print " </table></form>"; - if($lang{loginstring}) { print "<div style=\"width: 90%; height:365px; overflow:auto; padding-right : 12px; align:center; \"><table><td>$lang{loginstring}</td></table></div>"; } + if($lang{loginstring}) { print "<div style=\"width: 90%; height:330px; overflow:auto; padding-right : 12px; align:center;\"><table><td>$lang{loginstring}</td></table></div>"; } print "</center></body></html>"; } diff -Nur -x '*.orig' -x '*.rej' smeserver-coova-chilli-0.2/root/opt/chilli/lang/hotspotlogin.en.pl mezzanine_patched_smeserver-coova-chilli-0.2/root/opt/chilli/lang/hotspotlogin.en.pl --- smeserver-coova-chilli-0.2/root/opt/chilli/lang/hotspotlogin.en.pl 2010-07-29 13:54:12.000000000 +0200 +++ mezzanine_patched_smeserver-coova-chilli-0.2/root/opt/chilli/lang/hotspotlogin.en.pl 2010-07-29 13:52:55.000000000 +0200 @@ -18,4 +18,4 @@ # Custom resource vars $lang{loginstring} = "If you have any question, please contact <a href=mailto:$conf{contactinfo}>$conf{contactinfo}</a>"; $lang{loggedinstring} = "Welcome!<br>Closing this windows will disconnect you.."; -$lang{loggedoutstring} = "Thanks for using $conf{companyname}"; +$lang{loggedoutstring} = "Thanks for using $conf{domain} hotspot service"; diff -Nur -x '*.orig' -x '*.rej' smeserver-coova-chilli-0.2/root/opt/chilli/lang/hotspotlogin.fr.pl mezzanine_patched_smeserver-coova-chilli-0.2/root/opt/chilli/lang/hotspotlogin.fr.pl --- smeserver-coova-chilli-0.2/root/opt/chilli/lang/hotspotlogin.fr.pl 2008-09-02 13:28:03.000000000 +0200 +++ mezzanine_patched_smeserver-coova-chilli-0.2/root/opt/chilli/lang/hotspotlogin.fr.pl 2010-07-29 13:52:36.000000000 +0200 @@ -19,4 +19,4 @@ $lang{loginstring} = "Pour toute question relative au fonctionnement de cet accès, vous pouvez contacter le responsable <a href=mailto:$conf{contactinfo}>$conf{contactinfo}</a>"; $lang{loggedinstring} = "Bienvenue!<br>La fermeture de cette fenêtre terminera votre session."; -$lang{loggedoutstring} = "$conf{companyname} vous remercie"; +$lang{loggedoutstring} = "$conf{domain} vous remercie";