xrootd
Loading...
Searching...
No Matches
XrdOucGMap.hh
Go to the documentation of this file.
1#ifndef __XRDOUCGMAP_H__
2#define __XRDOUCGMAP_H__
3/******************************************************************************/
4/* */
5/* X r d O u c G M a p . h h */
6/* */
7/* (c) 2006 by the Board of Trustees of the Leland Stanford, Jr., University */
8/* All Rights Reserved */
9/* Produced by Andrew Hanushevsky for Stanford University under contract */
10/* DE-AC02-76-SFO0515 with the Department of Energy */
11/* */
12/* This file is part of the XRootD software suite. */
13/* */
14/* XRootD is free software: you can redistribute it and/or modify it under */
15/* the terms of the GNU Lesser General Public License as published by the */
16/* Free Software Foundation, either version 3 of the License, or (at your */
17/* option) any later version. */
18/* */
19/* XRootD is distributed in the hope that it will be useful, but WITHOUT */
20/* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or */
21/* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public */
22/* License for more details. */
23/* */
24/* You should have received a copy of the GNU Lesser General Public License */
25/* along with XRootD in a file called COPYING.LESSER (LGPL license) and file */
26/* COPYING (GPL license). If not, see <http://www.gnu.org/licenses/>. */
27/* */
28/* The copyright holder's institutional names and contributor's names may not */
29/* be used to endorse or promote products derived from this software without */
30/* specific prior written permission of the institution or contributor. */
31/******************************************************************************/
32
33#include "XrdOuc/XrdOucHash.hh"
36
37class XrdOucTrace;
38class XrdSysError;
40{
41public:
42 XrdSecGMapEntry_t(const char *v, const char *u, int t) : val(v), user(u), type(t) { }
45 int type;
46};
47
49{
50public:
51
52//------------------------------------------------------------------------------
65//------------------------------------------------------------------------------
66
67virtual int dn2user(const char *dn, char *user, int ulen, time_t now = 0);
68
69
70//------------------------------------------------------------------------------
88//------------------------------------------------------------------------------
89#define XrdOucGMapArgs XrdSysError *eDest, \
90 const char *mapfn, \
91 const char *parms
93
94//------------------------------------------------------------------------------
96//------------------------------------------------------------------------------
97
98virtual ~XrdOucGMap() {}
99
100//------------------------------------------------------------------------------
102//------------------------------------------------------------------------------
103
104bool isValid() const { return valid; }
105
106private:
107//------------------------------------------------------------------------------
109//------------------------------------------------------------------------------
110
111bool valid;
114time_t mf_mtime;
115time_t notafter;
117
120bool dbg;
121
123
124//------------------------------------------------------------------------------
126//------------------------------------------------------------------------------
127
128int load(const char *mf, bool force = 0);
129};
130
131/******************************************************************************/
132/* X r d O u c g e t G M a p */
133/******************************************************************************/
134
135//------------------------------------------------------------------------------
156//------------------------------------------------------------------------------
157
158//------------------------------------------------------------------------------
164//------------------------------------------------------------------------------
165
174
175#endif
XrdOucGMap * XrdOucgetGMap(XrdOucGMapArgs)
#define XrdOucGMapArgs
Definition XrdOucGMap.hh:89
Definition XrdOucGMap.hh:49
time_t mf_mtime
Definition XrdOucGMap.hh:114
XrdOucGMap(XrdOucGMapArgs)
virtual int dn2user(const char *dn, char *user, int ulen, time_t now=0)
bool valid
Internal members.
Definition XrdOucGMap.hh:111
bool isValid() const
Validity checker.
Definition XrdOucGMap.hh:104
bool dbg
Definition XrdOucGMap.hh:120
virtual ~XrdOucGMap()
Destructor.
Definition XrdOucGMap.hh:98
XrdSysXSLock xsl
Definition XrdOucGMap.hh:122
XrdSysError * elogger
Definition XrdOucGMap.hh:118
long timeout
Definition XrdOucGMap.hh:116
XrdOucHash< XrdSecGMapEntry_t > mappings
Definition XrdOucGMap.hh:112
XrdOucTrace * tracer
Definition XrdOucGMap.hh:119
int load(const char *mf, bool force=0)
Internal methods.
XrdOucString mf_name
Definition XrdOucGMap.hh:113
time_t notafter
Definition XrdOucGMap.hh:115
Definition XrdOucHash.hh:128
Definition XrdOucString.hh:254
Definition XrdOucTrace.hh:36
Definition XrdOucGMap.hh:40
XrdOucString user
Definition XrdOucGMap.hh:44
int type
Definition XrdOucGMap.hh:45
XrdOucString val
Definition XrdOucGMap.hh:43
XrdSecGMapEntry_t(const char *v, const char *u, int t)
Definition XrdOucGMap.hh:42
Definition XrdSysError.hh:90
Definition XrdSysXSLock.hh:45