#include "pvif.h"
|
std::vector< char > | user |
|
std::vector< char > | host |
|
std::vector< std::vector< char > > | groups |
|
Definition at line 91 of file pvif.h.
Definition at line 72 of file pvif.cpp.
74 pva::PeerInfo::const_shared_pointer info(req->getPeerInfo());
75 std::string usertemp, hosttemp;
77 if(info && info->identified) {
78 hosttemp = info->peer;
79 if(info->authority==
"ca") {
80 usertemp = info->account;
81 size_t sep = usertemp.find_last_of(
'/');
82 if(sep != std::string::npos) {
84 usertemp = usertemp.substr(sep+1);
88 usertemp = info->authority +
"/" + info->account;
91 const char role[] =
"role/";
93 groups.resize(info->roles.size());
95 for(pva::PeerInfo::roles_t::const_iterator it(info->roles.begin()), end(info->roles.end()); it!=end; ++it, idx++) {
96 groups[idx].resize((*it).size()+
sizeof(role));
102 groups[idx].begin()+
sizeof(role)-1);
108 hosttemp = req->getRequesterName();
112 size_t sep = hosttemp.find_first_of(
':');
113 if(sep == std::string::npos) {
114 sep = hosttemp.size();
116 hosttemp.resize(sep);
118 host.resize(hosttemp.size()+1);
122 host[hosttemp.size()] =
'\0';
124 user.resize(usertemp.size()+1);
128 user[usertemp.size()] =
'\0';
void copy(PVValueArray< T > &pvFrom, size_t fromOffset, size_t fromStride, PVValueArray< T > &pvTo, size_t toOffset, size_t toStride, size_t count)
Copy a subarray from one scalar array to another.
std::vector< std::vector< char > > groups
std::vector<std::vector<char> > ASCred::groups |
std::vector<char> ASCred::host |
std::vector<char> ASCred::user |
The documentation for this struct was generated from the following files: