From 2fb66ce07e790fad4070960bd28ef3b7d2cf3c34 Mon Sep 17 00:00:00 2001 From: rettenbe Date: Tue, 12 May 2009 09:29:38 +0000 Subject: [PATCH] change handling of incoming msgs from other si-server to be compatible with older si-server versions git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@13648 594d385d-05f5-0310-b6e9-bd551577e9d8 --- gosa-si/gosa-si-server | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/gosa-si/gosa-si-server b/gosa-si/gosa-si-server index af76ab68c..684315b33 100755 --- a/gosa-si/gosa-si-server +++ b/gosa-si/gosa-si-server @@ -1072,8 +1072,15 @@ sub msg_to_decrypt { # msg is from a gosa-si-server if(( !$msg ) || ( !$msg_hash ) || ( !$module )){ - #($msg, $msg_hash, $module) = &input_from_known_server($next_msg, $heap->{'remote_ip'}, $session_id); - ($msg, $msg_hash, $module) = &input_from_known_server($next_msg, $msg_source, $session_id); + if (not defined $msg_source) + { + # Only needed, to be compatible with older gosa-si-server versions + ($msg, $msg_hash, $module) = &input_from_known_server($next_msg, $heap->{'remote_ip'}, $session_id); + } + else + { + ($msg, $msg_hash, $module) = &input_from_known_server($next_msg, $msg_source, $session_id); + } } # msg is from a gosa-si-client if(( !$msg ) || ( !$msg_hash ) || ( !$module )){ @@ -1104,7 +1111,8 @@ sub msg_to_decrypt { } else { - daemon_log("$session_id ERROR: incoming message contains no msg source. Processing aborted: $tmp_next_msg", 1); + my $foreign_host = defined $msg_source ? $msg_source : $heap->{'remote_ip'}; + daemon_log("$session_id ERROR: incoming message from host '$foreign_host' cannot be understood. Processing aborted: $tmp_next_msg", 1); } $error++; -- 2.30.2