EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: About PCAS Access Control
From: "张玉亮" <[email protected]>
To: "tech-talk" <[email protected]>
Date: Tue, 14 Dec 2010 10:54:20 +0800
Hi all,
 
Here is my question. I want to add  access control to my PCAS, but I do not  know what the pUserName and pHostName in the following function refer to clearly.
virtual casChannel *createChannel ( const casCtx &ctx,const char * const pUserName,const char * const pHostName);
In "Channel Access Protable Server API Tutorial" it said that points to a string representing the user's name and  pHostName points to a string representing the server tool's host. For example, I have two EDM clients application run on the same linux PC, does the user's name refer to the PC name or something else.
 
I have implemented the createChannel function and  writeAccess function like this:
 
casChannel *exPV::createChannel ( const casCtx &ctx,
        const char * const  /*pUserName*/, 
        const char * const  /*pHostName*/)
{
    return new exChannel ( ctx,"zhangyul","Administrator");
}
///////////////////////////////////////////////////////////////////
bool exChannel::writeAccess () const
{
      if (strcmp(User.string(), "zhangyul") == 0)
return aitFalse;
      else
return aitTrue;
}
 
However, I found that any client could not write the PCAS's PV, I think my understanding is totally wrong about user's name and the host name!!
 
Thank you!
 
Zhang Yuliang

Replies:
Re: About PCAS Access Control William Lu
RE: About PCAS Access Control Jeff Hill

Navigate by Date:
Prev: RE: How to cross compile procServ? Davidsaver, Michael
Next: Controls Group vacancies Diamond Light Source mark.heron
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: RE: How to cross compile procServ? Davidsaver, Michael
Next: Re: About PCAS Access Control William Lu
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 20 Dec 2010 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·