mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-25 14:44:32 +02:00
Abort verified JSON-RPC connections with no valid endpoint
This commit is contained in:
parent
520aed6049
commit
353386f404
@ -834,6 +834,12 @@ void ApiListener::NewClientHandlerInternal(
|
||||
if (ctype == ClientJsonRpc) {
|
||||
Log(LogNotice, "ApiListener", "New JSON-RPC client");
|
||||
|
||||
if (verify_ok && !endpoint) {
|
||||
Log(LogWarning, "ApiListener")
|
||||
<< "Unknown endpoint '" << identity << "' with valid certificate. Aborting JSON-RPC connection.";
|
||||
return;
|
||||
}
|
||||
|
||||
if (endpoint && endpoint->GetConnected()) {
|
||||
Log(LogInformation, "ApiListener")
|
||||
<< "Ignoring JSON-RPC connection " << conninfo
|
||||
|
Loading…
x
Reference in New Issue
Block a user