mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-03 16:56:54 +00:00
FritzBoxUtils.pm: fix login for old Firmware Versions (Forum #87526)
git-svn-id: https://svn.fhem.de/fhem/trunk@16691 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
831df62fa7
commit
26dee9f194
@ -34,11 +34,12 @@ FB_doCheckPW($$$)
|
||||
|
||||
if($data =~ m/iswriteaccess/) { # Old version
|
||||
my @d = ( "login:command/response=$chlAnsw",
|
||||
"getpage=../html/de/internet/connect_status.txt" );
|
||||
"getpage=../html/login_sid.xml" );
|
||||
$data = join("&", map {join("=", map {urlEncode($_)} split("=",$_,2))} @d);
|
||||
$data = GetFileFromURL(FB_host2URL($host)."cgi-bin/webcm", undef, $data, 1);
|
||||
my $isOk = ($data =~ m/checkStatus/);
|
||||
return $isOk;
|
||||
my $sid = $1 if($data =~ /<SID>(\w+)<\/SID>/i);
|
||||
$sid = undef if($sid =~ m/^0*$/);
|
||||
return $sid;
|
||||
|
||||
} else { # FritzOS >= 5.50
|
||||
my @d = ( "response=$chlAnsw", "page=/login_sid.lua" );
|
||||
|
Loading…
x
Reference in New Issue
Block a user