root/trunk/src/dataFlowSet.h @ 118

Revision 114, 2.6 KB (checked in by andreu, 14 years ago)

add some counters in software (see renetcol_mib.h & dataFlowSet.c

  • Property svn:eol-style set to native
Line 
1/*
2 * File: dataFlowSet.h
3 *
4 * Authors: ANDREU Francois-Xavier
5 *
6 * Copyright (C) 2005 2006 2007 GIP RENATER
7 */
8
9/*  This file is part of renetcol.
10 *
11 *  renetcol is free software; you can redistribute it and/or modify
12 *  it under the terms of the GNU General Public License as published by
13 *  the Free Software Foundation; either version 2 of the License, or
14 *  (at your option) any later version.
15 *
16 *  renetcol is distributed in the hope that it will be useful,
17 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
18 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
19 *  GNU General Public License for more details.
20 *
21 *  You should have received a copy of the GNU General Public License
22 *  along with renetcol; if not, write to the Free Software
23 *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
24 */
25#ifndef DATAFLOWSET_H
26#define DATAFLOWSET_H
27
28#define _GNU_SOURCE
29#include "routers_mgmt.h"
30#include "tplflset_mgmt.h"
31#include "template.h"
32#include "msg_mgmt.h"
33#include "get_conf.h"
34#include "as.h"
35#include "pop.h"
36#include "prefix_mgmt.h"
37#include "renetcolParam.h"
38
39#define TRESHOLD_TEMPLATE_ID 300
40
41struct IPFLowCache {
42  unsigned char ipProt; /* not write in file, just to know IP version */
43  unsigned long bytes;
44  unsigned long pkts;
45  unsigned short inSnmp;
46  unsigned short outSnmp;
47  unsigned long v4AdS;
48  unsigned long v4AdD;
49  uint32_t tabAdd6S[4];
50  uint32_t tabAdd6D[4];
51  unsigned char tProt;
52  unsigned short sPort;
53  unsigned short dPort;
54  unsigned char maskD;
55  unsigned char maskS;
56  unsigned long routerAd;
57  unsigned long liveTime;
58};
59
60struct MPLSFlowCache {
61  unsigned char ipProt; /* not write in file, just to know IP version */
62  unsigned long routerAd;
63  unsigned short mplsLabel1;
64  unsigned long v4AdS;
65  unsigned long v4AdD;
66  uint32_t tabAdd6S[4];
67  uint32_t tabAdd6D[4]; 
68};
69
70struct AggCache {
71  unsigned short mode;
72  unsigned char dscp;
73  unsigned char maskS;
74  unsigned char maskD;
75  unsigned char tProt;
76  unsigned char ipProt;
77  unsigned short sPort;
78  unsigned short dPort; 
79  unsigned char sens; /* In/out field 61 */
80  unsigned short inputSnmp;
81  unsigned short outputSnmp;
82  unsigned long bytes;
83  unsigned long pkts;
84  unsigned long routerAd;
85  unsigned long v4AdS;
86  unsigned long v4AdD;
87  uint32_t tabAdd6S[4];
88  uint32_t tabAdd6D[4];
89#ifdef ASACC
90  unsigned short asS;
91  unsigned short asD;
92#endif
93  /*  unsigned short mplsLabel1;
94      unsigned long ifAdd; */
95};
96
97
98short 
99checkDataFlowSet(short,
100                 struct MyPtrs *,
101                 int,
102                 struct PrefixV4 *, size_t,
103                 struct PrefixV4 *, size_t
104                 );
105
106#endif /* DATAFLOWSET_H */
Note: See TracBrowser for help on using the browser.