]> granicus.if.org Git - icinga2/commitdiff
Fix cluster permissions for SendNotifications messages
authorGunnar Beutner <gunnar.beutner@netways.de>
Mon, 13 Jun 2016 09:13:25 +0000 (11:13 +0200)
committerGunnar Beutner <gunnar.beutner@netways.de>
Mon, 13 Jun 2016 09:13:25 +0000 (11:13 +0200)
refs #9242

lib/icinga/clusterevents.cpp

index 02b2e79aad207bad728f81446c53511377ae1234..9772109408c06e2b013266f36cb3fa7eac440e9d 100644 (file)
@@ -806,7 +806,7 @@ Value ClusterEvents::SendNotificationsAPIHandler(const MessageOrigin::Ptr& origi
        if (!checkable)
                return Empty;
 
-       if (origin->FromZone && !origin->FromZone->CanAccessObject(checkable)) {
+       if (origin->FromZone && origin->FromZone != Zone::GetLocalZone()) {
                Log(LogNotice, "ClusterEvents")
                    << "Discarding 'send custom notification' message from '" << origin->FromClient->GetIdentity() << "': Unauthorized access.";
                return Empty;