mirror of https://github.com/Icinga/icinga2.git
Merge pull request #7747 from Icinga/bugfix/heartbeat-unauthenticated-7746
Don't send event::Heartbeat to unauthenticated peers
This commit is contained in:
commit
bf2d6abfad
|
@ -36,13 +36,15 @@ void JsonRpcConnection::HandleAndWriteHeartbeats(boost::asio::yield_context yc)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
SendMessageInternal(new Dictionary({
|
if (m_Endpoint) {
|
||||||
{ "jsonrpc", "2.0" },
|
SendMessageInternal(new Dictionary({
|
||||||
{ "method", "event::Heartbeat" },
|
{ "jsonrpc", "2.0" },
|
||||||
{ "params", new Dictionary({
|
{ "method", "event::Heartbeat" },
|
||||||
{ "timeout", 120 }
|
{ "params", new Dictionary({
|
||||||
}) }
|
{ "timeout", 120 }
|
||||||
}));
|
}) }
|
||||||
|
}));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue