XRootD
Loading...
Searching...
No Matches
XrdNetPMark Class Referenceabstract

#include <XrdNetPMark.hh>

Inheritance diagram for XrdNetPMark:
Collaboration diagram for XrdNetPMark:

Classes

class  Handle

Public Member Functions

 XrdNetPMark ()
virtual ~XrdNetPMark ()
virtual Handle * Begin (XrdNetAddrInfo &addr, Handle &handle, const char *tident)=0
virtual Handle * Begin (XrdSecEntity &Client, const char *path=0, const char *cgi=0, const char *app=0)=0

Static Public Member Functions

static bool getEA (const char *cgi, int &ecode, int &acode)

Static Public Attributes

static const int maxTotID = 65535
static const int minTotID = 65

Static Protected Attributes

static const int btsActID = 6
static const int maxActID = maxTotID & mskActID
static const int maxExpID = maxTotID >> btsActID
static const int minActID = minTotID & mskActID
static const int minExpID = minTotID >> btsActID
static const int mskActID = 63

Detailed Description

Definition at line 40 of file XrdNetPMark.hh.

Constructor & Destructor Documentation

◆ XrdNetPMark()

XrdNetPMark::XrdNetPMark ( )
inline

Definition at line 81 of file XrdNetPMark.hh.

81{}

Referenced by XrdNetPMarkCfg::Config().

Here is the caller graph for this function:

◆ ~XrdNetPMark()

virtual XrdNetPMark::~XrdNetPMark ( )
inlinevirtual

Definition at line 82 of file XrdNetPMark.hh.

82{} // This object cannot be deleted!

Member Function Documentation

◆ Begin() [1/2]

virtual Handle * XrdNetPMark::Begin ( XrdNetAddrInfo & addr,
Handle & handle,
const char * tident )
pure virtual

Implemented in XrdNetPMarkCfg.

References getEA(), and tident.

Here is the call graph for this function:

◆ Begin() [2/2]

virtual Handle * XrdNetPMark::Begin ( XrdSecEntity & Client,
const char * path = 0,
const char * cgi = 0,
const char * app = 0 )
pure virtual

Implemented in XrdNetPMarkCfg.

◆ getEA()

bool XrdNetPMark::getEA ( const char * cgi,
int & ecode,
int & acode )
static

Definition at line 40 of file XrdNetPMark.cc.

41{
42
43 ecode = acode = 0;
44// If we have cgi, see if we can extract rge codes from there
45//
46 if (cgi) {
47 const char *stP = strstr(cgi, "scitag.flow=");
48 if (stP) {
49 char *eol;
50 int eacode = strtol(stP + 12, &eol, 10);
51 if (*eol == '&' || *eol == 0) {
52 if (eacode >= XrdNetPMark::minTotID && eacode <= XrdNetPMark::maxTotID) {
53 ecode = eacode >> XrdNetPMark::btsActID;
54 acode = eacode & XrdNetPMark::mskActID;
55 }
56 // According to the specification, if the provided scitag.flow has an incorrect value
57 // the packets will be marked with a scitag = 0
58 return true;
59 }
60 }
61 }
62
63 // No go
64 //
65 return false;
66}
static const int minTotID
static const int btsActID
static const int maxTotID
static const int mskActID

References btsActID, maxTotID, minTotID, and mskActID.

Referenced by Begin().

Here is the caller graph for this function:

Member Data Documentation

◆ btsActID

const int XrdNetPMark::btsActID = 6
staticprotected

Definition at line 94 of file XrdNetPMark.hh.

Referenced by getEA().

◆ maxActID

const int XrdNetPMark::maxActID = maxTotID & mskActID
staticprotected

Definition at line 99 of file XrdNetPMark.hh.

Referenced by XrdNetPMark::Handle::Valid().

◆ maxExpID

const int XrdNetPMark::maxExpID = maxTotID >> btsActID
staticprotected

Definition at line 98 of file XrdNetPMark.hh.

Referenced by XrdNetPMark::Handle::Valid().

◆ maxTotID

const int XrdNetPMark::maxTotID = 65535
static

Definition at line 90 of file XrdNetPMark.hh.

Referenced by getEA().

◆ minActID

const int XrdNetPMark::minActID = minTotID & mskActID
staticprotected

Definition at line 97 of file XrdNetPMark.hh.

Referenced by XrdNetPMark::Handle::Valid().

◆ minExpID

const int XrdNetPMark::minExpID = minTotID >> btsActID
staticprotected

Definition at line 96 of file XrdNetPMark.hh.

Referenced by XrdNetPMark::Handle::Valid().

◆ minTotID

const int XrdNetPMark::minTotID = 65
static

From the specifications: Valid value for scitag is a single positive integer > 64 and <65536 (16bit). Any other value is considered invalid.

Definition at line 89 of file XrdNetPMark.hh.

Referenced by getEA().

◆ mskActID

const int XrdNetPMark::mskActID = 63
staticprotected

Definition at line 95 of file XrdNetPMark.hh.

Referenced by getEA().


The documentation for this class was generated from the following files: