Back to index

nordugrid-arc-nox  1.1.0~rc6
IdentityMap.h
Go to the documentation of this file.
00001 #ifndef __ARC_SEC_IDENTITYMAP_H__
00002 #define __ARC_SEC_IDENTITYMAP_H__
00003 
00004 #include <arc/ArcConfig.h>
00005 #include <arc/message/Message.h>
00006 #include <arc/message/SecHandler.h>
00007 #include <arc/security/PDP.h>
00008 
00009 namespace ArcSec {
00010 
00011 class LocalMap {
00012  public:
00013   LocalMap(void) {};
00014   virtual ~LocalMap(void) {};
00015   virtual std::string ID(Arc::Message* msg) = 0;
00016 };
00017 
00019 
00022 class IdentityMap : public SecHandler {
00023  private:
00024 
00025   typedef struct {
00026     PDP* pdp;
00027     LocalMap* uid;
00028   } map_pair_t;
00029 
00030   std::list<map_pair_t> maps_;
00031 
00032  public:
00033   IdentityMap(Arc::Config *cfg, Arc::ChainContext* ctx);
00034   virtual ~IdentityMap(void);
00035   virtual bool Handle(Arc::Message* msg) const;
00036 };
00037 
00038 } // namespace ArcSec
00039 
00040 #endif /* __ARC_SEC_IDENTITYMAP_H__ */
00041