Ignore:
Timestamp:
Dec 14, 2010 6:58:28 PM (13 years ago)
Author:
Ted Faber <faber@…>
Branches:
axis_example, compt_changes, info-ops, master
Children:
c092b7f
Parents:
2627eb3
Message:

Move proofs around. Lots of changes, including fault handling.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • fedd/federation/deter_internal_access.py

    r2627eb3 re83f2f2  
    215215        aid = "%s" % auth_attr
    216216        attrs = req.get('fedAttr', [])
    217         if not self.auth.check_attribute(fid, auth_attr):
     217        access_ok, proof = self.auth.check_attribute(fid, auth_attr,
     218                with_proof=True)
     219        if not access_ok:
    218220            raise service_error(service_error.access, "Access denied")
    219221        else:
     
    271273                'allocID': req['allocID'],
    272274                'allocationLog': logv,
    273                 'segmentdescription': { 'topdldescription': rtopo.to_dict() }
     275                'segmentdescription': { 'topdldescription': rtopo.to_dict() },
     276                'proof': proof.to_dict(),
    274277                }
    275278        retval = copy.deepcopy(self.state[aid]['started'])
     
    289292
    290293        self.log.debug("Terminate request for %s" %aid)
    291         if not self.auth.check_attribute(fid, auth_attr):
     294        access_ok, proof = self.auth.check_attribute(fid, auth_attr,
     295                with_proof=True)
     296        if not access_ok:
    292297            raise service_error(service_error.access, "Access denied")
    293298
     
    308313        self.state[aid]['vlan'] = None
    309314        self.state_lock.release()
    310         return { 'allocID': req['allocID'] }
     315        return { 'allocID': req['allocID'], 'proof': proof.to_dict() }
Note: See TracChangeset for help on using the changeset viewer.