From 4d2bb1aac0a7b8a3075c3e903e6249430c184553 Mon Sep 17 00:00:00 2001 From: rudolfkoenig Date: Wed, 27 Dec 2017 15:03:48 +0000 Subject: [PATCH] 96_allowed.pm: Fix globalpassword for telnet (Forum #81612) git-svn-id: https://svn.fhem.de/fhem/trunk@15709 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/FHEM/96_allowed.pm | 1 - fhem/fhem.pl | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/fhem/FHEM/96_allowed.pm b/fhem/FHEM/96_allowed.pm index 3ae9bc257..8f0062394 100644 --- a/fhem/FHEM/96_allowed.pm +++ b/fhem/FHEM/96_allowed.pm @@ -175,7 +175,6 @@ allowed_Authenticate($$$$) my $pw = AttrVal($aName, "password", undef); if(!$pw) { $pw = AttrVal($aName, "globalpassword", undef); - return 2 if($pw && !defined($param)); $pw = undef if($pw && $cl->{NAME} =~ m/_127.0.0.1_/); } return 0 if(!$pw); diff --git a/fhem/fhem.pl b/fhem/fhem.pl index 1a84af0f2..79c75e6bf 100755 --- a/fhem/fhem.pl +++ b/fhem/fhem.pl @@ -5356,7 +5356,7 @@ SecurityCheck() my @fnd; foreach my $sdev (devspec2array("TYPE=(telnet|FHEMWEB)")) { next if(!$defs{$sdev} || $defs{$sdev}{TEMPORARY}); - my $hash = { SNAME=>$sdev, TYPE=>$defs{$sdev}{TYPE} }; + my $hash = { SNAME=>$sdev, TYPE=>$defs{$sdev}{TYPE}, NAME=>"SecurityCheck"}; push(@fnd, " $sdev is not password protected") if(!Authenticate($hash, undef)); }