-#
-from sfa.trust.rights import *
-from sfa.util.faults import *
-from sfa.util.namespace import urn_to_hrn
+from sfa.util.xrn import urn_to_hrn
from sfa.util.method import Method
-from sfa.util.parameter import Parameter, Mixed
+
from sfa.trust.credential import Credential
+from sfa.storage.parameter import Parameter, Mixed
+
class GetCredential(Method):
"""
Retrive a credential for an object
origin_hrn = Credential(string=valid_creds[0]).get_gid_caller().get_hrn()
self.api.logger.info("interface: %s\tcaller-hrn: %s\ttarget-hrn: %s\tmethod-name: %s"%(self.api.interface, origin_hrn, hrn, self.name))
- manager = self.api.get_interface_manager()
-
- return manager.get_credential(self.api, xrn, type)
+ return self.api.manager.GetCredential(self.api, xrn, type, self.api.auth.client_gid.get_urn())