#include <XrdNetSecurity.hh>
Public Member Functions | |
void | AddHost (char *hname) |
void | AddNetGroup (char *hname) |
char * | Authorize (struct sockaddr *addr) |
void | Merge (XrdNetSecurity *srcp) |
void | Trace (XrdOucTrace *et=0) |
XrdNetSecurity () | |
~XrdNetSecurity () | |
Private Member Functions | |
char * | hostOK (char *hname, const char *ipname, const char *why) |
Private Attributes | |
XrdOucNList_Anchor | HostList |
XrdNetTextList * | NetGroups |
XrdOucHash< char > | OKHosts |
XrdSysMutex | okHMutex |
XrdOucTrace * | eTrace |
int | lifetime |
Static Private Attributes | |
static const char * | TraceID |
Definition at line 26 of file XrdNetSecurity.hh.
XrdNetSecurity::XrdNetSecurity | ( | ) | [inline] |
XrdNetSecurity::~XrdNetSecurity | ( | ) | [inline] |
Definition at line 41 of file XrdNetSecurity.hh.
void XrdNetSecurity::AddHost | ( | char * | hname | ) |
Definition at line 71 of file XrdNetSecurity.cc.
References XrdOucHash< T >::Add(), DEBUG, XrdNetDNS::getHostName(), Hash_dofree, HostList, XrdOucNList_Anchor::Insert(), and OKHosts.
Referenced by XrdCmsConfig::xallow(), and XrdConfig::xallow().
void XrdNetSecurity::AddNetGroup | ( | char * | hname | ) |
Definition at line 90 of file XrdNetSecurity.cc.
References DEBUG, NetGroups, and XrdNetTextList::next.
Referenced by XrdCmsConfig::xallow(), and XrdConfig::xallow().
char * XrdNetSecurity::Authorize | ( | struct sockaddr * | addr | ) |
Definition at line 108 of file XrdNetSecurity.cc.
References DEBUG, XrdOucHash< T >::Find(), XrdOucNList_Anchor::Find(), free(), XrdNetDNS::getHostName(), HostList, hostOK(), inet_ntop(), XrdSysMutex::Lock(), NetGroups, XrdNetTextList::next, okHMutex, OKHosts, XrdNetTextList::text, and XrdSysMutex::UnLock().
Referenced by XrdNet::do_Accept_TCP(), and XrdNet::do_Accept_UDP().
void XrdNetSecurity::Merge | ( | XrdNetSecurity * | srcp | ) |
Definition at line 153 of file XrdNetSecurity.cc.
References HostList, NetGroups, XrdNetTextList::next, XrdOucNList_Anchor::Pop(), XrdOucNList_Anchor::Replace(), and XrdNetTextList::text.
Referenced by XrdNet::Secure().
void XrdNetSecurity::Trace | ( | XrdOucTrace * | et = 0 |
) | [inline] |
char * XrdNetSecurity::hostOK | ( | char * | hname, | |
const char * | ipname, | |||
const char * | why | |||
) | [private] |
Definition at line 186 of file XrdNetSecurity.cc.
References XrdOucHash< T >::Add(), DEBUG, Hash_dofree, lifetime, okHMutex, OKHosts, and XrdSysMutex::UnLock().
Referenced by Authorize().
XrdOucNList_Anchor XrdNetSecurity::HostList [private] |
XrdNetTextList* XrdNetSecurity::NetGroups [private] |
Definition at line 49 of file XrdNetSecurity.hh.
Referenced by AddNetGroup(), Authorize(), Merge(), and XrdNetSecurity().
XrdOucHash<char> XrdNetSecurity::OKHosts [private] |
Definition at line 51 of file XrdNetSecurity.hh.
Referenced by AddHost(), Authorize(), and hostOK().
XrdSysMutex XrdNetSecurity::okHMutex [private] |
XrdOucTrace* XrdNetSecurity::eTrace [private] |
int XrdNetSecurity::lifetime [private] |
const char * XrdNetSecurity::TraceID [static, private] |
Definition at line 56 of file XrdNetSecurity.hh.