Skip to content

Commit

Permalink
secgsi: fine tune message bucket content
Browse files Browse the repository at this point in the history
Do not add on last message; deactivate unused buckets
  • Loading branch information
gganis authored and simonmichal committed Mar 18, 2019
1 parent 6485034 commit 70a9395
Showing 1 changed file with 12 additions and 9 deletions.
21 changes: 12 additions & 9 deletions src/XrdSecgsi/XrdSecProtocolgsi.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2896,16 +2896,18 @@ int XrdSecProtocolgsi::AddSerialized(char opt, kXR_int32 step, String ID,
// allow to prove authenticity of counter part
//
// Generate new random tag and create a bucket
String RndmTag;
XrdSutRndm::GetRndmTag(RndmTag);
//
// Get bucket
brt = 0;
if (!(brt = new XrdSutBucket(RndmTag,kXRS_rtag))) {
PRINT("error creating random tag bucket");
return -1;
if (!(opt == 'c' && step == kXGC_sigpxy)) {
String RndmTag;
XrdSutRndm::GetRndmTag(RndmTag);
//
// Get bucket
brt = 0;
if (!(brt = new XrdSutBucket(RndmTag,kXRS_rtag))) {
PRINT("error creating random tag bucket");
return -1;
}
buf->AddBucket(brt);
}
buf->AddBucket(brt);
//
// Get cache entry
if (!hs->Cref) {
Expand Down Expand Up @@ -3470,6 +3472,7 @@ int XrdSecProtocolgsi::ClientDoPxyreq(XrdSutBuffer *br, XrdSutBuffer **bm,
return 0;
}
delete req;
(*bm)->Deactivate(kXRS_x509_req);

// Send back the signed request as bucket
if ((bck = npxy->Export())) {
Expand Down

0 comments on commit 70a9395

Please sign in to comment.