Back to index

nordugrid-arc-nox  1.1.0~rc6
charon.h
Go to the documentation of this file.
00001 #ifndef __ARC_CHARON_H__
00002 #define __ARC_CHARON_H__
00003 
00004 #include <string>
00005 #include <list>
00006 
00007 #include <arc/infosys/RegisteredService.h>
00008 #include <arc/security/ArcPDP/Evaluator.h>
00009 #include <arc/security/PDP.h>
00010 #include <arc/infosys/InformationInterface.h>
00011 
00012 namespace ArcSec {
00013 
00016 class Charon: public Arc::RegisteredService {
00017  protected:
00018   class PolicyLocation {
00019    public:
00020     std::string path;
00021     bool reload;
00022     time_t mtime;
00023     time_t ctime;
00024     PolicyLocation(const std::string& location,bool reload);
00025     bool IsModified(void);
00026   };
00027   Glib::Mutex lock_;
00028   Arc::NS ns_;
00029   Arc::Logger logger_;
00030   std::string endpoint_;
00031   std::string expiration_;
00032   std::list<PolicyLocation> locations_;
00033   std::string evaluator_name_;
00034   Evaluator* eval;
00035   //Arc::InformationContainer infodoc;
00036   Arc::MCC_Status make_soap_fault(Arc::Message& outmsg, const std::string& msg = "");
00037   bool load_policies(void);
00038   bool policies_modified(void);
00039  public:
00040   Charon(Arc::Config *cfg);
00041   virtual ~Charon(void);
00042   virtual Arc::MCC_Status process(Arc::Message& inmsg,Arc::Message& outmsg);
00043   bool RegistrationCollector(Arc::XMLNode &doc);
00044 };
00045 
00046 } // namespace ArcSec
00047 
00048 #endif
00049