X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~mdw/git/tripe/blobdiff_plain/5251b9bbd6fc17db7999e1ec3a53ee0b1597aae8..98444c8a3e57ce3b15dd8fd6237357063b286f26:/mon/tripemon.in diff --git a/mon/tripemon.in b/mon/tripemon.in index 0404e21e..d96601fb 100644 --- a/mon/tripemon.in +++ b/mon/tripemon.in @@ -1423,31 +1423,11 @@ class CryptoInfo (TrivialWindow): me.add(table) crypto = conn.algs() - table.info('Diffie-Hellman group', - '%s (%d-bit order, %d-bit elements)' % - (crypto['kx-group'], - int(crypto['kx-group-order-bits']), - int(crypto['kx-group-elt-bits'])), - len = 42) - table.info('Data encryption', - '%s (%d-bit key; %s)' % - (crypto['cipher'], - int(crypto['cipher-keysz']) * 8, - crypto['cipher-blksz'] == '0' - and 'stream cipher' - or '%d-bit block' % (int(crypto['cipher-blksz']) * 8)), - newlinep = True) - table.info('Message authentication', - '%s (%d-bit key; %d-bit tag)' % - (crypto['mac'], - int(crypto['mac-keysz']) * 8, - int(crypto['mac-tagsz']) * 8), - newlinep = True) - table.info('Hash function', - '%s (%d-bit output)' % - (crypto['hash'], - int(crypto['hash-sz']) * 8), - newlinep = True) + firstp = True + for label, format in cryptolayout: + table.info(label, format_stat(format, crypto), + len = 42, newlinep = not firstp) + firstp = False me.show_all()