From 339fbb23e3879f9ad9716a7b917dcc18ebed0ba5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pavel=20K=C3=A1cha?= <ph@cesnet.cz> Date: Wed, 31 Jul 2013 13:53:26 +0200 Subject: [PATCH] Soucasti jmena id souboru je nyni i typ pozadovane zpravy (nebo any) (#1132) --- src/warden-client/doc/README | 15 +++++++++++++++ src/warden-client/lib/WardenClientReceive.pm | 2 +- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/src/warden-client/doc/README b/src/warden-client/doc/README index 40b0a80..7f58223 100644 --- a/src/warden-client/doc/README +++ b/src/warden-client/doc/README @@ -159,6 +159,21 @@ D. Update (Update of previously installed the Warden client package) Note: You must be root for running this script. + 6. Note that unlike version 2.1, in 2.2 the name of the file in which id of + the last received message is stored have changed. Previously, name was + "CALLER_NAME.id" (where CALLER_NAME is the name of calling script), + whereas now name contains name of requested message type + "CALLER_NAME-TYPE.id". + + Should you want to continue downloading events where previous version + left off, you will have to rename the file by hand. + + For example, where name of the file was "./var/example-receiver.pl.id" + and downloaded type was "portscan", new name should be + "./var/example-receiver.pl-portscan.id". If caller passes undef as + requested type to receive all types, new name should be + "./var/example-receiver.pl-any.id" + -------------------------------------------------------------------------------- E. Uninstallation diff --git a/src/warden-client/lib/WardenClientReceive.pm b/src/warden-client/lib/WardenClientReceive.pm index de274d8..faf2d29 100755 --- a/src/warden-client/lib/WardenClientReceive.pm +++ b/src/warden-client/lib/WardenClientReceive.pm @@ -40,7 +40,7 @@ sub getNewEvents # set name of ID file for each client aplication my $caller_name = $FindBin::Script; - my $id_file = $vardir . $caller_name . ".id"; + my $id_file = $vardir . $caller_name . "-". ($requested_type || "any") . ".id"; #----------------------------------------------------------------------------- # get last ID from ID file (if exist) or -- GitLab