git://git.onelab.eu
/
sfa.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
print out explicit warning when xmlsec1 cannot be found in PATH
[sfa.git]
/
sfa
/
trust
/
credential.py
diff --git
a/sfa/trust/credential.py
b/sfa/trust/credential.py
index
c4e6982
..
a32a49a
100644
(file)
--- a/
sfa/trust/credential.py
+++ b/
sfa/trust/credential.py
@@
-272,11
+272,13
@@
class Credential(object):
if os.path.isfile(path + '/' + 'xmlsec1'):
self.xmlsec_path = path + '/' + 'xmlsec1'
break
if os.path.isfile(path + '/' + 'xmlsec1'):
self.xmlsec_path = path + '/' + 'xmlsec1'
break
+ if not self.xmlsec_path:
+ logger.warn("Could not locate binary for xmlsec1 - SFA will be unable to sign stuff !!")
def get_subject(self):
if not self.gidObject:
self.decode()
def get_subject(self):
if not self.gidObject:
self.decode()
- return self.gidObject.get_
printable_
subject()
+ return self.gidObject.get_subject()
# sounds like this should be __repr__ instead ??
def get_summary_tostring(self):
# sounds like this should be __repr__ instead ??
def get_summary_tostring(self):
@@
-364,8
+366,6
@@
class Credential(object):
if not self.gidObject:
self.decode()
return self.gidObject
if not self.gidObject:
self.decode()
return self.gidObject
-
-
##
# Expiration: an absolute UTC time of expiration (as either an int or string or datetime)
##
# Expiration: an absolute UTC time of expiration (as either an int or string or datetime)
@@
-404,8
+404,7
@@
class Credential(object):
if isinstance(privs, str):
self.privileges = Rights(string = privs)
else:
if isinstance(privs, str):
self.privileges = Rights(string = privs)
else:
- self.privileges = privs
-
+ self.privileges = privs
##
# return the privileges as a Rights object
##
# return the privileges as a Rights object