git://git.onelab.eu
/
sfa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
701599b
)
try legacy user hrn format
author
Tony Mack
<tmack@paris.CS.Princeton.EDU>
Mon, 13 Aug 2012 15:25:21 +0000
(11:25 -0400)
committer
Tony Mack
<tmack@paris.CS.Princeton.EDU>
Mon, 13 Aug 2012 15:25:21 +0000
(11:25 -0400)
sfa/client/sfaclientlib.py
patch
|
blob
|
history
diff --git
a/sfa/client/sfaclientlib.py
b/sfa/client/sfaclientlib.py
index
ef039e2
..
c5c5b80
100644
(file)
--- a/
sfa/client/sfaclientlib.py
+++ b/
sfa/client/sfaclientlib.py
@@
-133,7
+133,12
@@
class SfaClientBootstrap:
self.assert_private_key()
registry_proxy = SfaServerProxy (self.registry_url, self.private_key_filename(),
certificate_filename)
self.assert_private_key()
registry_proxy = SfaServerProxy (self.registry_url, self.private_key_filename(),
certificate_filename)
- credential_string=registry_proxy.GetSelfCredential (certificate_string, self.hrn, "user")
+ try:
+ credential_string=registry_proxy.GetSelfCredential (certificate_string, self.hrn, "user")
+ except:
+ # some urns hrns may replace non hierarchy delimiters '.' with an '_' instead of escaping the '.'
+ hrn = Xrn(self.hrn).get_hrn().replace('\.', '_')
+ credential_string=registry_proxy.GetSelfCredential (certificate_string, hrn, "user")
self.plain_write (output, credential_string)
self.logger.debug("SfaClientBootstrap: Wrote result of GetSelfCredential in %s"%output)
return output
self.plain_write (output, credential_string)
self.logger.debug("SfaClientBootstrap: Wrote result of GetSelfCredential in %s"%output)
return output