93 service[0] ==
'/' || (service[1] ==
':' && service[2] ==
'/'))) {
101 gROOT->GetListOfSockets()->Add(
this);
111 gROOT->GetListOfSockets()->Add(
this);
155 gROOT->GetListOfSockets()->Add(
this);
206 if (
fSocket == -1) {
return 0; }
211 if (soc == -1) {
delete socket;
return 0; }
212 if (soc == -2) {
delete socket;
return (
TSocket*) -1; }
226 gROOT->GetListOfSockets()->Add(socket);
312 Error(
"Authenticate",
"can't load %s",srvlib.
Data());
316 Error(
"Authenticate",
"can't locate %s",srvlib.
Data());
325 Error(
"Authenticate",
"can't find SrvAuthenticate");
334 Warning(
"Authenticate",
"can't find SrvAuthCleanup");
340 Error(
"Authenticate",
"config dir undefined");
352 Info(
"Authenticate",
"OpenHost = %s", openhost.
Data());
359 std::string ctkn =
"";
361 auth = (*fgSrvAuthHook)(sock, confdir, tmpdir, user,
365 Info(
"Authenticate",
"auth = %d, type= %d, ctkn= %s",
366 auth,
type, ctkn.c_str());
R__EXTERN TVirtualMutex * gROOTMutex
static void SetAuthOpt(UChar_t &opt, UChar_t mod)
Kind of macro to parse input options Modify opt according to modifier mod.
TVirtualMutex * gSrvAuthenticateMutex
Int_t(* SrvClup_t)(TSeqCollection *)
Int_t(* SrvAuth_t)(TSocket *sock, const char *, const char *, std::string &, Int_t &, Int_t &, std::string &, TSeqCollection *)
R__EXTERN TSystem * gSystem
#define R__LOCKGUARD2(mutex)
#define R__LOCKGUARD(mutex)
virtual void Delete(Option_t *option="")=0
Delete this object.
This class represents an Internet Protocol (IP) address.
const char * GetHostName() const
virtual void SetTitle(const char *title="")
Set the title of the TNamed.
virtual void SetName(const char *name)
Set the name of the TNamed.
R__ALWAYS_INLINE Bool_t TestBit(UInt_t f) const
virtual void Warning(const char *method, const char *msgfmt,...) const
Issue warning message.
void SetBit(UInt_t f, Bool_t set)
Set or unset the user status bits as specified in f.
virtual void Error(const char *method, const char *msgfmt,...) const
Issue error message.
virtual void Info(const char *method, const char *msgfmt,...) const
Issue info message.
static const TString & GetRootSys()
Get the rootsys directory in the installation. Static utility function.
static SrvAuth_t fgSrvAuthHook
virtual Int_t GetLocalPort()
Get port # to which server socket is bound. In case of error returns -1.
static UChar_t fgAcceptOpt
static void SetAcceptOptions(UChar_t Opt)
Set default options for Accept according to modifier 'mod'.
Bool_t Authenticate(TSocket *)
Check authentication request from the client on new open connection.
static SrvClup_t fgSrvAuthClupHook
virtual ~TServerSocket()
Destructor: cleanup authentication stuff (if any) and close.
static void ShowAcceptOptions()
Print default options for Accept.
static UChar_t GetAcceptOptions()
Return default options for Accept.
virtual TSocket * Accept(UChar_t Opt=0)
Accept a connection on a server socket.
virtual TInetAddress GetLocalInetAddress()
Return internet address of host to which the server socket is bound, i.e.
TSeqCollection * fSecContexts
virtual void Close(Option_t *opt="")
Close the socket.
TInetAddress GetInetAddress() const
TSecContext * fSecContext
const char * Data() const
virtual int GetServiceByName(const char *service)
Get port # of internet service.
virtual TInetAddress GetSockName(int sock)
Get Internet Protocol (IP) address of host and port #.
virtual Func_t DynFindSymbol(const char *module, const char *entry)
Find specific entry point in specified library.
virtual char * GetServiceByPort(int port)
Get name of internet service.
virtual int AcceptConnection(int sock)
Accept a connection.
virtual TInetAddress GetPeerName(int sock)
Get Internet Protocol (IP) address of remote host and port #.
virtual int Load(const char *module, const char *entry="", Bool_t system=kFALSE)
Load a shared library.
virtual Bool_t AccessPathName(const char *path, EAccessMode mode=kFileExists)
Returns FALSE if one can access a file using the specified access mode.
virtual int AnnounceTcpService(int port, Bool_t reuse, int backlog, int tcpwindowsize=-1)
Announce TCP/IP service.
virtual int AnnounceUnixService(int port, int backlog)
Announce unix domain service.
virtual const char * TempDirectory() const
Return a user configured or systemwide directory to create temporary files in.
char * DynamicPathName(const char *lib, Bool_t quiet=kFALSE)
Find a dynamic library called lib using the system search paths.
This class implements a mutex interface.