From: ̅ȗ̵ (tensaich@epnetworks.co.kr)
Date: Tue Dec 03 2002 - 17:43:07 PST
Hi Everybody...
I have a question about the "Cflow.pm"
I'm using the perl and making the next source..
By the way , the result has a matter...
===================== source code =======================================
#!/usr/local/bin/perl
#use Cflow;
use Cflow qw(:flowvars find);
use strict;
Cflow::verbose(1);
Cflow::find(\&wanted, <*.flows*>);
find(\&wanted, @ARGV? @ARGV : <*.flows*>);
sub wanted {
### test print ######
print "####$Cflow::unix_secs####\n";
printf("%s %15.15s.%-5hu %15.15s.%-5hu %2hu %10u %10u\n",
$localtime,
$srcip,
$srcport,
$dstip,
$dstport,
$protocol,
$pkts,
$bytes)
}
====================== result ========================================
####0####
1970/01/01 09:00:00 0.0.0.3.0 0.0.0.38.1036 61
12 2886731521
####3####
1970/01/01 09:00:03 1.0.0.0.897 0.1.103.38.13690 129
201326592 0
####671088646####
1991/04/08 14:30:46 38.0.0.0.3244 39.0.0.4.4103 0
16777219 0
####0####
1970/01/01 09:00:00 0.3.129.53.0 122.12.0.0.7937 0
1730558464 897
####0####
1970/01/01 09:00:00 172.16.7.1.0 0.0.3.0.0 1
1038818344 1536
####452985354####
1984/05/10 06:15:54 2.157.198.1.52992 249.196.132.6.0 91
54938285 1695619840
####15851####
1970/01/01 13:24:11 0.3.0.0.1036 0.38.0.0.0 28
830480 117506048
####135168####
1970/01/02 22:32:48 103.38.58.0.0 0.0.3.129.256 0
520185638 973078528
####65539####
1970/01/02 03:12:19 0.12.172.16.16 7.1.0.0.0 7
15851 472383488
####114557224####
1973/08/19 06:27:04 0.0.0.0.22371 0.0.0.108.4731 2
3204587520 419889432
####50637826####
1971/08/10 11:03:46 0.1.53.3.1286 218.2.2.6.6146 7
1344276106 67405826
####81199629####
1972/07/29 04:27:09 4.27.4.215.1057 2.13.4.32.1239 4
34407463 81199629
####3609332996####
1948/04/10 19:01:40 184.4.215.2.47620 13.4.185.4.55042 190
218413828 3607235844
####80151767####
1972/07/17 01:22:47 13.4.193.8.525 1.174.2.13.1219 2
81199629 79955159
####4127512322####
1964/09/11 05:13:46 13.5.239.4.3333 215.2.13.5.61700 13
3607235845 4077180674
The $Cflow::locatime is incorrectness....
plz. reply the good answer.....!!
have a nice day...^^
_______________________________________________
Cflowd mailing list
Cflowd@caida.org
http://login.caida.org/mailman/listinfo/cflowd
This archive was generated by hypermail 2.1.4 : Tue Dec 03 2002 - 17:57:46 PST