From 6750b6e04e5ec317c98a4ee1c3f1412c577ce0e8 Mon Sep 17 00:00:00 2001 From: jpawlowski Date: Tue, 11 Oct 2016 08:28:22 +0000 Subject: [PATCH] 74_THINKINGCLEANER.pm: prevent people from using roomba's own address for webhook backwards connection to FHEM git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@12321 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- FHEM/74_THINKINGCLEANER.pm | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/FHEM/74_THINKINGCLEANER.pm b/FHEM/74_THINKINGCLEANER.pm index 979ddc2b0..66bfd9186 100644 --- a/FHEM/74_THINKINGCLEANER.pm +++ b/FHEM/74_THINKINGCLEANER.pm @@ -883,6 +883,12 @@ sub THINKINGCLEANER_Attr(@) { && $attrName eq "webhookHttpHostname" && $attrVal !~ /^([A-Za-z_.0-9]+\.[A-Za-z_.0-9]+)|[0-9:]+$/ ); + return +"Invalid value for attribute $attrName: needs to be different from the defined name/address of your Roomba, we need to know how Rooma can connect back to FHEM here!" + if ( $attrVal + && $attrName eq "webhookHttpHostname" + && $attrVal eq $hash->{DeviceName} ); + return "Invalid value for attribute $attrName: FHEMWEB instance $attrVal not existing" if (