diff options
author | Kali Kaneko (leap communications) <kali@leap.se> | 2015-12-16 12:27:46 -0400 |
---|---|---|
committer | Kali Kaneko (leap communications) <kali@leap.se> | 2015-12-16 12:37:54 -0400 |
commit | e8c3d389a734350661cdd1fcf6db607f318e75e8 (patch) | |
tree | cddfe955463f55fdce969530f0ee0ea232b1c2ab /src/leap/bonafide/_protocol.py | |
parent | e6752ba23e1d5fbcb02c3f399f3cbf7147455d33 (diff) |
add command to download smtp certificate
Diffstat (limited to 'src/leap/bonafide/_protocol.py')
-rw-r--r-- | src/leap/bonafide/_protocol.py | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/src/leap/bonafide/_protocol.py b/src/leap/bonafide/_protocol.py index 617c93c..f1c3834 100644 --- a/src/leap/bonafide/_protocol.py +++ b/src/leap/bonafide/_protocol.py @@ -114,17 +114,20 @@ class BonafideProtocol(object): d.addCallback(lambda _: '%s logged out' % full_id) return d - def do_stats(self): - log.msg('Calculating Bonafide Service STATS') - mem = resource.getrusage(resource.RUSAGE_SELF).ru_maxrss - return '[+] Bonafide service: [%s sessions] [Mem usage: %s KB]' % ( - len(self._sessions), mem / 1024) + def do_get_smtp_cert(self, full_id): + session = self._get_session(full_id) + d = session.get_smtp_cert() + return d def do_get_vpn_cert(self): pass - def do_get_smtp_cert(self): - pass - def do_update_user(self): pass + + def do_stats(self): + log.msg('Calculating Bonafide Service STATS') + mem = resource.getrusage(resource.RUSAGE_SELF).ru_maxrss + return '[+] Bonafide service: [%s sessions] [Mem usage: %s KB]' % ( + len(self._sessions), mem / 1024) + |