Main Page   Namespace List   Alphabetical List   Compound List   File List   Compound Members   File Members  

webbroker.h

Go to the documentation of this file.
00001 /***************************************************************************
00002                                  webbroker.h
00003                              -------------------
00004     begin                : Fri Feb 1 2002
00005     copyright            : (C) 2002 by Constantinos A. Kotsokalis
00006     email                : ckotso@grnet.gr
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  *                                                                         *
00011  *   This program is free software; you can redistribute it and/or modify  *
00012  *   it under the terms of the GNU General Public License as published by  *
00013  *   the Free Software Foundation; either version 2 of the License, or     *
00014  *   (at your option) any later version.                                   *
00015  *                                                                         *
00016  ***************************************************************************/
00017 
00018 #ifndef WEBBROKER_H
00019 #define WEBBROKER_H
00020 
00026 class WebBroker;
00027 
00028 #include <cc++/socket.h>
00029 #include <cc++/thread.h>
00030 
00031 #ifdef  CCXX_NAMESPACES
00032     using namespace std;
00033     using namespace ost;
00034 #endif
00035 
00036 #include "collector.h"
00037 #include "timeslot.h"
00038 #include "timestamp.h"
00039 #include "ifpair.h"
00040 #include "stripper.h"
00041 
00042 #include <string>
00043 #include <map>
00044 
00045 class webTCPSocket : public TCPSocket {
00046 protected:
00047     bool OnAccept(const InetHostAddress &ia, tpport_t port);
00048 
00049 public:
00050     InetHostAddress websrv;
00051     webTCPSocket(InetAddress &ia, uint16_t port) : TCPSocket(ia, port) {};
00052 };
00053 
00054 class WebBroker : public Thread  {
00055 public: 
00056     WebBroker(uint16_t&, InetHostAddress&, Mutex *, Collector *);
00057     virtual ~WebBroker();
00058     virtual void run();
00059 
00060 private:
00061     Collector *collector;
00062     Mutex *mtx;
00063     uint16_t port;
00064     InetHostAddress websrv;
00065     virtual vector<string> ProcessRequest(string);
00066     virtual vector<string> retInterfaces();
00067     virtual vector<string> retData(vector<string>);
00068     virtual vector<string> retAttacks(vector<string>);
00069 };
00070 
00071 #endif

Generated on Thu Jun 26 00:23:13 2003 for Panoptis by doxygen1.2.18