summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 8ba3fd0)
raw | patch | inline | side by side (parent: 8ba3fd0)
author | rettenbe <rettenbe@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 29 May 2008 07:54:25 +0000 (07:54 +0000) | ||
committer | rettenbe <rettenbe@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 29 May 2008 07:54:25 +0000 (07:54 +0000) |
* under construction
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@11093 594d385d-05f5-0310-b6e9-bd551577e9d8
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@11093 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-si/gosa-si-server-nobus | patch | blob | history | |
gosa-si/modules/ServerPackages.pm | patch | blob | history | |
gosa-si/tests/client.php | patch | blob | history |
index 4fab869890287a40b1d083628adac29658f749df..dc94baabaec451e47b986fb34da861bcda814fcb 100755 (executable)
if (not $done) {
if (($target eq $server_address) && (not exists $msg_hash->{'forward_to_gosa'})) {
$done = 1;
+ print STDERR "target is own address without forward_to_gosa-tag -> process here\n";
}
}
$res = $known_clients_db->select_dbentry($sql);
if (keys(%$res) > 0) {
$done = 1;
+ print STDERR "target is a client address in known_clients -> process here\n";
}
}
$heap->{'client'}->put($msg);
}
$done = 1;
+ print STDERR "target is own address with forward_to_gosa-tag -> forward to gosa\n";
}
+
}
# target is a client address in foreign_clients -> forward to registration server
&send_msg_to_target($msg, $regserver, $regserver_key, $header, $session_id);
}
$done = 1;
+ print STDERR "target is a client address in foreign_clients -> forward to registration server\n";
}
}
my $hostkey = $res->{1}->{'hostkey'};
&send_msg_to_target($msg, $target, $hostkey, $header, $session_id);
$done = 1;
+ print STDERR "target is a server address -> forward to server\n";
}
}
if( $error == 0) {
daemon_log("$session_id INFO: Incoming msg (session_id=$session_id) with header '".@{$msg_hash->{'header'}}[0]."'", 5);
daemon_log("$session_id DEBUG: Processing module ".$module, 7);
+
+ known_modules
+ }
+
+ if ($error == 0) {
$answer_l = &{ $module."::process_incoming_msg" }($msg, $msg_hash, $session_id);
if ( 0 < @{$answer_l} ) {
# targets of msg are all gosa-si-server in known_server_db
elsif( $answer_target eq "KNOWN_SERVER" ) {
# answer is for all server in known_server
- my $sql_statement= "SELECT * FROM known_server";
+ my $sql_statement= "SELECT * FROM $known_server_tn";
my $query_res = $known_server_db->select_dbentry( $sql_statement );
while( my ($hit_num, $hit) = each %{ $query_res } ) {
my $host_name = $hit->{hostname};
my $host_key = $hit->{hostkey};
- $answer =~ s/KNOWN_SERVER/$host_name/g;
+ $answer =~ s/<target>KNOWN_SERVER<\/target>/<target>$host_name<\/target>/g;
my $error = &send_msg_to_target($answer, $host_name, $host_key, $answer_header, $session_id);
&update_jobdb_status_for_send_msgs($answer, $error);
}
index d70afd40e6a34e6df05a8198261ddd7f803677dc..8e64273455bd42db862ec0c3152ba0a807dd6769 100644 (file)
no strict 'refs';
@out_msg_l = &{$event_hash->{$header}."::$header"}($msg, $msg_hash, $session_id);
} else {
+ &main::daemon_Log("$session_id ERROR: ServerPackages: no event handler defined for '$header'", 1);
+ @out_msg_l = ();
}
return @out_msg_l;
index 325c38680dc227f5065b5c9b0c3064d0ae05b774..135bb44a1a25d8f2863f6003ebcee4d9bb798364 100755 (executable)
--- a/gosa-si/tests/client.php
+++ b/gosa-si/tests/client.php
#$data = "<xml> <header>gosa_krb5_create_principal</header> <target>00:01:6c:9d:aa:16</target> <principal>horst@WIRECARD.SYS</principal><source>GOSA</source><max_life>666</max_life></xml>";
#$data = "<xml> <header>gosa_krb5_modify_principal</header> <target>00:01:6c:9d:b9:fa</target> <principal>horst@WIRECARD.SYS</principal><source>GOSA</source><max_life>666</max_life></xml>";
- $data = "<xml> <header>new_ping</header> <target>10.89.1.131:20081</target> <source>GOSA</source> <forward_to_gosa></forward_to_gosa> </xml>";
+ #$data = "<xml> <header>new_ping</header> <target>10.89.1.131:20083</target> <source>GOSA</source> <forward_to_gosa></forward_to_gosa> </xml>";
+ $data = "<xml> <header>new_ping</header> <target>00:0c:29:02:e5:4d</target> <source>GOSA</source> </xml>";
$sock->write($data);
$answer = "nothing";