xrootd
|
00001 #ifndef _CMS_SECURITY_H 00002 #define _CMS_SECURITY_H 00003 /******************************************************************************/ 00004 /* */ 00005 /* X r d C m s S e c u r i t y . h h */ 00006 /* */ 00007 /* (c) 2007 by the Board of Trustees of the Leland Stanford, Jr., University */ 00008 /* All Rights Reserved */ 00009 /* Produced by Andrew Hanushevsky for Stanford University under contract */ 00010 /* DE-AC02-76-SFO0515 with the Department of Energy */ 00011 /******************************************************************************/ 00012 00013 // $Id$ 00014 00015 00016 #include <sys/types.h> 00017 #include <sys/socket.h> 00018 00019 #include "XrdSec/XrdSecInterface.hh" 00020 00021 class XrdLink; 00022 class XrdOucTList; 00023 00024 class XrdCmsSecurity 00025 { 00026 public: 00027 00028 static int Authenticate(XrdLink *Link, const char *Token, int tlen); 00029 00030 static int Configure(const char *Lib, const char *Cfn=0); 00031 00032 static const char *getToken(int &size, const char *hostname); 00033 00034 static int Identify(XrdLink *Link, XrdCms::CmsRRHdr &inHdr, 00035 char *authBuff, int abLen); 00036 00037 static char *setSystemID(XrdOucTList *tp, const char *iName, 00038 const char *iHost, char iType); 00039 00040 XrdCmsSecurity() {} 00041 ~XrdCmsSecurity() {} 00042 00043 private: 00044 static XrdSecService *DHS; 00045 }; 00046 #endif