mon/tripemon.in: Split out crypto-specific pieces of `statslayout'.
authorMark Wooding <mdw@distorted.org.uk>
Wed, 6 Sep 2017 20:03:18 +0000 (21:03 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Thu, 14 Jun 2018 09:34:25 +0000 (10:34 +0100)
One notices that these are suspiciously similar to (though less good)
than the things displayed by CryptoInfo.  It would be nice if we could
share them somehow...

No functional change yet.

mon/tripemon.in

index b65d8e1..1e62f03 100644 (file)
@@ -1259,18 +1259,21 @@ statsxlate = \
 ## How to lay out the stats dialog.  Format is (LABEL, FORMAT): LABEL is
 ## the label to give the entry box; FORMAT is the format string to write into
 ## the entry.
-statslayout = \
-  [('Start time', '%(start-time)s'),
-   ('Private key', '%(current-key)s'),
-   ('Diffie-Hellman group',
+cryptolayout = \
+  [('Diffie-Hellman group',
     '%(kx-group)s '
     '(%(kx-group-order-bits)s-bit order, '
     '%(kx-group-elt-bits)s-bit elements)'),
    ('Cipher',
     '%(cipher)s (%(cipher-keysz)s-bit key, %(cipher-blksz)s-bit block)'),
    ('Mac', '%(mac)s (%(mac-keysz)s-bit key, %(mac-tagsz)s-bit tag)'),
-   ('Hash', '%(hash)s (%(hash-sz)s-bit output)'),
-   ('Last key-exchange', '%(last-keyexch-time)s'),
+   ('Hash', '%(hash)s (%(hash-sz)s-bit output)')]
+
+statslayout = \
+  [('Start time', '%(start-time)s'),
+   ('Private key', '%(current-key)s')] + \
+  cryptolayout + \
+  [('Last key-exchange', '%(last-keyexch-time)s'),
    ('Last packet', '%(last-packet-time)s'),
    ('Packets in/out',
     '%(packets-in)s (%(bytes-in)s) / %(packets-out)s (%(bytes-out)s)'),