extra files for db and testing
authorvb
Wed, 25 Jun 2014 18:48:18 +0200
changeset 2f1fc3afacfd6
parent 1 06e02338bdd8
child 3 bd4014e15899
child 4 140c907a66be
extra files for db and testing
db/create_system_db.sql
db/dic2csv.py
db/safewords.py
test/DF9B1541-sec.key
test/DF9B1541.key
test/Makefile
test/msg.asc
test/signature.asc
test/t1.txt
test/t2.txt
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/db/create_system_db.sql	Wed Jun 25 18:48:18 2014 +0200
     1.3 @@ -0,0 +1,8 @@
     1.4 +CREATE TABLE wordlist (
     1.5 +   lang text,
     1.6 +   id integer,
     1.7 +   word text,
     1.8 +   entropy integer
     1.9 +);
    1.10 +
    1.11 +CREATE UNIQUE INDEX wordlist_pk on wordlist (lang, id);
     2.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.2 +++ b/db/dic2csv.py	Wed Jun 25 18:48:18 2014 +0200
     2.3 @@ -0,0 +1,54 @@
     2.4 +#! /usr/bin/env python3
     2.5 +
     2.6 +from argparse import ArgumentParser
     2.7 +from fileinput import FileInput, hook_encoded
     2.8 +import re, itertools, sys
     2.9 +
    2.10 +try:
    2.11 +    from math import log2
    2.12 +except:
    2.13 +    from math import log
    2.14 +    def log2(x): return log(x) / log(2)
    2.15 +
    2.16 +word = re.compile(r"(\S*?)(/|\s.*|$)")
    2.17 +unwanted = re.compile(r"(^\d|[^']*')")
    2.18 +space = re.compile(r'^\s')
    2.19 +
    2.20 +p = ArgumentParser(description="create dictionary csv out of hunspell data")
    2.21 +p.add_argument('--hunspell', '-H', type=str, default="/usr/share/hunspell",
    2.22 +    help='directory where hunspell dictionary files reside (default: /usr/share/hunspell)')
    2.23 +p.add_argument('--lang', '-l', type=str, default="en_US",
    2.24 +    help='use dictionary for language LANG (default: en_US)')
    2.25 +p.add_argument('--encoding', '-e', type=str, default="utf-8",
    2.26 +    help='file encoding (default: utf-8)')
    2.27 +
    2.28 +args = p.parse_args()
    2.29 +
    2.30 +_all = (
    2.31 +    word.match(line).group(1).upper()
    2.32 +        for line in FileInput(
    2.33 +                args.hunspell + "/" + args.lang + ".dic",
    2.34 +                openhook=hook_encoded(args.encoding)
    2.35 +            )
    2.36 +        if not space.match(line)
    2.37 +)
    2.38 +_words = [w for w in _all if len(w) > 2 and not unwanted.match(w)]
    2.39 +_words.sort()
    2.40 +_words = [w for w, g in itertools.groupby(_words)]
    2.41 +
    2.42 +if len(_words) > 65536:
    2.43 +    _words = _words[:65536]
    2.44 +elif len(_words) < 65536:
    2.45 +    sys.stderr.write(
    2.46 +            "warning for {}: only {:.2f} bit in wordlist, that makes {:.2f} bit for 5 words\n".format(
    2.47 +                    args.lang,
    2.48 +                    log2(len(_words)),
    2.49 +                    log2(len(_words))*5
    2.50 +                )
    2.51 +        )
    2.52 +    _words.extend(_words[:65536-len(_words)])
    2.53 +
    2.54 +assert len(_words) == 65536, "lenght is {}".format(len(_words))
    2.55 +
    2.56 +for i, w in enumerate(_words):
    2.57 +    print("{l},{i},{w}".format(l=args.lang[:2], i=i, w=w))
     3.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     3.2 +++ b/db/safewords.py	Wed Jun 25 18:48:18 2014 +0200
     3.3 @@ -0,0 +1,42 @@
     3.4 +#!/usr/bin/env python3
     3.5 +
     3.6 +from sqlite3 import connect
     3.7 +from os import environ
     3.8 +from argparse import ArgumentParser
     3.9 +from re import sub
    3.10 +
    3.11 +try:
    3.12 +    environ["ALLUSERSPROFILE"]
    3.13 +except KeyError:
    3.14 +    db_file = "/usr/local/share/pEp/system.db"
    3.15 +else:
    3.16 +    db_file = environ["ALLUSERSPROFILE"] + r"\pEp\system.db"
    3.17 +
    3.18 +p = ArgumentParser(description="show safewords instead of hex fingerprint")
    3.19 +p.add_argument('--db-path', '-d', type=str, default=db_file,
    3.20 +        help='path to pEp system db (default: ' + db_file + ')')
    3.21 +p.add_argument('--lang', '-l', type=str, default="en",
    3.22 +        help='use dictionary for language LANG (default: en)')
    3.23 +p.add_argument('--short', '-s', action='store_true',
    3.24 +        help='display the first 5 of the safewords')
    3.25 +p.add_argument('hex', metavar="hex", type=str, nargs='+',
    3.26 +        help='hex values of fingerprint')
    3.27 +
    3.28 +args = p.parse_args()
    3.29 +
    3.30 +c = connect(args.db_path).cursor()
    3.31 +hex_string = sub(r"\W", "", "".join(args.hex))
    3.32 +
    3.33 +def hex_word(s):
    3.34 +    n = min(20, len(s)) if args.short else len(s)
    3.35 +    for i in range(0, n, 4):
    3.36 +        yield s[i:i+4]
    3.37 +
    3.38 +r = []
    3.39 +
    3.40 +for arg in hex_word(hex_string):
    3.41 +    c.execute("select word from wordlist where id = {} and lang = lower('{}')".format(
    3.42 +            str(int(arg, 16)), args.lang))
    3.43 +    r.append(c.fetchall()[0][0])
    3.44 +
    3.45 +print(" ".join(r))
     4.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     4.2 +++ b/test/DF9B1541-sec.key	Wed Jun 25 18:48:18 2014 +0200
     4.3 @@ -0,0 +1,106 @@
     4.4 +-----BEGIN PGP PRIVATE KEY BLOCK-----
     4.5 +Version: GnuPG v2.0.22 (MingW32)
     4.6 +
     4.7 +lQcYBFLefd0BEADB97Pmcz0yfkOWD2978HRUCUa7H4JpuDHZs+hurMlkuE7mLGh5
     4.8 +PAQ61/nL5gppl0cHFNlO7doG2gcRixWZfeQZywkJia5xNzcdjyAiC5jZ6IQpXk2T
     4.9 +wwzBIDYrU+9DhppY5hnE90yDv0MBS2SVjDergZTPDBbIYPTtPf5h51pVULCAtiyN
    4.10 +2Htv3M3tDwJJ9IrLFpJL+ClocgrmeDANKbico63qlBl9NjiUqdnt5INoE6/SnKSu
    4.11 +zaBE37C+/10bswFpjjVffyhu+hplxp6MlalZZYJEip6rmDe0P+nMbEmNvNuUmZwc
    4.12 +sPwvr1vRwhGGpZao2j4/SnDsKNNmsLrwyVEQboHYcKIgLEuHY4WtHDUt6umu7zdt
    4.13 +I6VDUoiSuNkVB+TM51HeQOoLZJ4Evcrdh6zKB2wWMW1RJQIknlMDwnRhHj+WJD06
    4.14 +texTzvAfDdsHV6NNs2WeUKesyivCyaKMPU7o95D+ZMi22CQ2qUCSLegivpnk/gKS
    4.15 +pM+JqwyAPnzJBW43qr13zA0tWMO2nzSzcYnRhTNTGeqkxn7t2Uc0ItMk360Xy7n6
    4.16 +yI2AL79daP0NGM9P0F4wD44FCnrvcDO0gbk3zJJnynnfFSF6Dk4/2sRUPsp2gm9B
    4.17 +hiHFt4w13mySETjd0sbcQYbpHZbJEPm2YY/q7rTCCCA106vg1S2IduY2GwARAQAB
    4.18 +AA//QydAc/UKx2v6dz4B0W2GwL9zav52NqbML3x/aK3Ojd3Xhw3x36M9Lagvdf2/
    4.19 +Nh5nO1bnA1IKrVuXneXCxSDWM23dQ52UtOKyZLv0GoVcVnkPJIlfH1ykkkpWJrsI
    4.20 +955m2odTfaNGrMgvaQfSm4nvjiOvQt2DF72lnmtbokaoOihU60Lm+vbriWdvLfcH
    4.21 +ylXtJXG7laylnWD6UB9lN3Ft1mE+qZu7lWOLxEBn0FpQelxyf163D0PmjGHLfdzI
    4.22 +PfpD72kKJnVOKNnTANB6fN6lwmsH5jX9yBfLlU6ZYapN7tHnTbO+3hoSPWofRmhD
    4.23 +jBPRLMVeTqg1nzVlN0TRe+Ke+xAMkrlAcC2xJyU4vi9VgGJNeXZk0m0aDpxGaHwS
    4.24 +p1lskMQoKO9cswCeBGUbWmuhC6MXPwUpN3s1r7GSwQGB8O1xQbSghTqozgIwlu/H
    4.25 +JRfC8yvQJpxK9UtFJ1t41vq/urxxlL2BC67ms9u1W+/yY/bgrKPAlP7QcYJqXFQa
    4.26 +b+1xmL2gG0avgGISzu86hN3VLFZ6xKyIfgrAP4N44ZrJ2dvgR6jCpU6qg4Mzkiuf
    4.27 +j7dnLRfRcjRT3K+a62Ma1cd0DqeFdYHyOO6u/68I50doj5X8NDJQLy6zwOtzmbKz
    4.28 +5l7DLZbX9hnhvrk0mMOflLq0+adr5KloGGYcQHtpfF8VKy0IAM0wqLeGWmkSMQeA
    4.29 +jj77lpF3JR1OObw7Od8GewMuGBOZjdc5EC2CvLwM040dT2a93QJb5qF08AHKi8g/
    4.30 +GKGnSZ3YqfSuHOxqtAycURUWsR/5qVc2aEcueimq9RvKPOH+jihhcJofgYS85xuD
    4.31 +pIZRCpHITiWaWeE2FxlATzOAldReThNm1W6uaQ/A0VFZ4It1jvHeHtiL1v9KHwH+
    4.32 +7MQCK0hQ0MxrK5RudPFLTky4FAfIXSOTUZBzzrL5kiFxEcLARj1UVZjD7BvwZOQT
    4.33 +gNVYOA7BfsqfH17NEnkaZTFUUVb1+nggzl4/Csv+1ZPkHnfzv3KpTRE1Mh7oXs1B
    4.34 +cvo/Ds0IAPH/obEvqL3sSJtxDWuPd6iKhcJ5EbbrFi4XQNjFy/sJTVmX9HWfwDF3
    4.35 +WU9qPfKuF5f9EN/VH/ge7amlnJvHMRBfnvk8ViAiitucZAc4HzFIIyLB2SWRE6RX
    4.36 +AUplhRKn/9LAz8Q+VgHDSlvk3KuwE1CYQXg2qNHjw2xeWepDHgshGBFlnmx69Lcv
    4.37 +atiqwKlvFCJND9eu022ViDJ4gYxH2S9DpBuVqhAaZLa4jWssOGn28vUEv9gD7zAA
    4.38 +02ja08cO8Zkf9+aawN+XiYYKuSaPwg4K31SFP/VTkJv0sA9YBaqLOqjnvjjZ0igO
    4.39 +4gmP3zR65gpWLn6liZig4sGRp7XrCIcIAMxGghMsK6NNb7prVTJ7GiOnsgAmIiNf
    4.40 +BqmkcESNJBRSglKPW2fQ5D6TY0IUrNDZyf8lyO/5whnEVdzzapMr/jzcdX2lCByo
    4.41 +tTtxkU6UivAS3AXwSkqH+CG4WdrkkLziCMTH/pGmOH/BiVdkvEyAlSzt1ECpHKP1
    4.42 +hWIrJfBC6xc9c1c5wySqX6422fBG6G79soLaAxpITl+VQ0VyRG+RG6V0OrafGfnR
    4.43 +glZB58jUjBVW6Cs8AvIW1D3BXL1zb2M+Bwa2pgaoopp4ZX7/aqmfFpUhlYFXud2r
    4.44 +K/z0Ua7wHi1bEHbWxMdPLCfTWGv0AJJItQfY9n+GR+awzoMyVwS0TV542bQ/Vm9s
    4.45 +a2VyIEJpcmsgKFRlc3RrZXkgLSBkb24ndCB1c2UpIDx2b2xrZXIuYmlya0BkaWdp
    4.46 +dGFsZWtoby5jb20+iQI/BBMBAgApBQJS3n3dAhsDBQkB4TOABwsJCAcDAgEGFQgC
    4.47 +CQoLBBYCAwECHgECF4AACgkQ3VW/Kd+bFUGMYA//XifXG1F9g983n/VVZiP9k04c
    4.48 +xU+H8oez5WAjl1UIUEBwmDpbA1Ts7OAcozyclwdY36ud2b2v3SPzMXsHy/ttcpzo
    4.49 +lHJMIdvBNCiIc1GOCidR9GKgNZS/ffJgyyhZ6JkoQLPapHv+zPCvschlHR7HmbyX
    4.50 +MX79QgDu6bN11JIGWiu2xq/mH2IUg5Xp5VyRlE0zWrNwu4es72t8qzHxprVrMIo7
    4.51 +2Ar8hk5Z3bRvPK4vi8EINubEfYeFbELopMGPWMgeZz8CTeeB8W7ut9FgYdQFFJkz
    4.52 +ZTAT/KhBzsu2Nvzpj7DoMhCsee5hksP200S+Wgdtvs/l4brNQqwxD20J9lGqK8th
    4.53 +FBbxQ+jf2xvAd+2/6L9FhtaDEExpc6hbbleXU0p8AYjPOcGIpGzU4v+pgafMbSk+
    4.54 +LtchFPUUCjtIlqHoqZ1xVnxdb+B5PxhhJGfIHy72zibTvfh/qEz4FRBISb7ma13q
    4.55 +WsdplNsoeqBb5qnQuQkXaM+MLqzowVQ3V9csj6VNHTvCrKYZjQzsLduLz8GgApQY
    4.56 +hsZqfotI4MVx/s6Aon8ZYpXDvY2dzoNAS3Q9ADzrI+mMHlEgzYZwsmEWcdAGc+1X
    4.57 +kV4PKCpPA0mVzDSGDaJ13qxK66NV1pqZisqVEcuhCZ8aB2N1Yk2VnDdmT1MwcAAb
    4.58 +jCbRyJe+sqb9ReEPIXudBxgEUt593QEQALwSjvQuRsVyI8p2DS8NdGTOEe+11NJr
    4.59 +1pIWy0JRYVW+zhAhXZwKhdueCTW+zcrB/ygKokCj2/Kh7GgnyJf7SGpBGnoMTGHt
    4.60 +M7WjiZr7E26FvQIVUMfE+P4h1lVDrHX4Ah3zJRasGQRlVHvJiC5875X0f3wNqPmN
    4.61 +LDYf8IG9kEaL3n6H0tG8p+VZAELZxgbdt0LMBa/TK/hp8OtaDmO4ME7+Nudg5Uth
    4.62 +7zHhmBwhij4bSre37+HM9u12RnYf1SCbManmR51OtbjmNWA4H+Tb8sa22zgxNmhz
    4.63 +CQ3bggXeMLIP9lpVNC9rk3uH0Adb7rjpbh0y0lzzUmfKO6yasoC9zznzdiHhsKAh
    4.64 +mfn4F+GlcMjUhgGtnHKbq81RVfS8cT/XIWdCLT/nogJ3xiv7G/uDNjq1A/X2Vah0
    4.65 +T8eMvvBOmnRdwQtblK3CfpMsFzqDZht9C/c6py/wPuHQZti4G2K4zFwP4nN0vTEv
    4.66 +3EkZ3+wCK7Lw8nWu+d2DzzXl3r3+l6wqQ3DdGv8JyL6tnSlR+D2kgDeLYqpbaMHr
    4.67 ++LJsZN8d5Lf/ilJqxaeiEB0tYg11yi64D9AbjwURV7BnuDbh2eNeIg0wQ63dLjQ8
    4.68 +aZF4Y/rxgWvOAo2/lveUOUMcPcuOBFN+pFchKqosALwQ75JYib5gYo0tgtUkhpJM
    4.69 +jnJFMUquLOxbABEBAAEAD/4tXma41d8Bq26h3QeCJcNBvApMorcDybrZxADlbx9F
    4.70 +YYFxF7NuvIUc/QsouW4IbvL/9Ey+viiFZ/VRDOPRce8+npTmA0h7yQ5Tz28XAWFn
    4.71 +JID7WywA/O251GzRZcFZNepA0lJMnVhtnIocUHn3CPF84Z3NTbhI9vrG1b6ddZ6z
    4.72 +vfL+4AIF0XZJF8a92a3xIxQd23y1tQHi65+QDsnw2VJiA+Y3u8KkhCwBAvRAOQER
    4.73 +yWClYAxQkrKwhvspbLVrp7R70U7OTln9EB+pJfDfswVmVV8dt5Vx7eotuxmrE7X4
    4.74 +hmw9z1cG53MM9i7DT7SPS9Rh28wuWw4ydnEdyrWr4930qVLoXnP5zvA9rVfVg9Ou
    4.75 +EvPRT2B7Ht9ygyuc+RnzLKdLgt1/riJQHMDrTlyKV4MZR31Pkwofc1AusVptfnm/
    4.76 +B3X6moxVdhHKc+r/uAVGuUFdyBfyPql5oyLCkqSnW7DCroxbAbGoT2kgzW7DIM+v
    4.77 +qSttqdD7TCY6Os7nL5dmkHDyfP53xgkcn1gMEsthnMuu1q40DGFHqEOHhOGw+14P
    4.78 +3NH0/cA3QnU3h/4vWXnich+0BmvsXJyQh04qR9g9yf8vP8k5EiPkL1sKtX8B2zAj
    4.79 +YrXEqpWKu4YXJo3SBFQN+r7l/kZKm7cnRRdGU8p7sUkoqKgnXZM+H522H535u0jZ
    4.80 +nQgAz02bJQddSQFdTsARz91JJthExBnphzZnLNTLulRN5rVotsXX7vffsZdTQABl
    4.81 +juRfe/S/TlurC4NtaEXsZpmkTb3Mzg/Q4tC9bLpfbd00F9B76rpvxbXo8roZpdNM
    4.82 +QnNy0CaBhtAH5TjeKtnNcF3hYHf9esaDTQBTrERUDJCX9ERls9VSOyb13SLENgPm
    4.83 +qXmuuooRFRt1/gbmq62JEpqREVgdTxqGqjQWwQwWXLbRYWC7KKTrG87KSGny0LRi
    4.84 +UfY5yPyzwRSe8R6hv+XpeBz4017CHzHn2mWY7ENqbyYI30NaYroK66+1e1uToXzG
    4.85 +ydOxiJ7bwBDIGuCrXqH22XcsVwgA6EB/Iv56xO/yKHjz5J254ZxXtk228LY+se4t
    4.86 +BUWb20hcAbuNH6H2a8cyD98WEBVQmmBtbDCE754IU+poZGiVjfwBT6vvk/cuCx8a
    4.87 +NAzY0DVmk/aXI9PiHP2DPZf5kZsgIzW/ESjGZqtIsWrYgIujnI6I/euE8dvbKAHv
    4.88 +OnkKlCpP2AquKtPXhreY0s3iJY0WF5FECM3yoCCEAQOr0P6wnqTSt6BDZCpVaILD
    4.89 +4KXnDuYaQABH6/txyYmWOJFH+vNZdLnPfhdcCEqWU+Y5A4qS6ekBY5ZjPTnjGDtV
    4.90 +670I29hAXsz4szuHr3xhDYXzrmmVQ93Hs3y/35mnTZv11eo9nQf+K9W58hNpV9mx
    4.91 +TOK2LOWNuFwkEakhP6VxtyHR1swpJV+krabNxLEprMBQLwX0gj2gPKhF2q9joZGh
    4.92 +GPwHjshDQd2znU05zm7b444RU0f+hdAAy15nAJaZ5VyRt3frrpSOq4/FlNrjXycO
    4.93 +2oLsMbcAbHrWa7bYAkNFTLePgE6LCuIL8fGXT6w/dJwkIHTFKFpKL1zcr/SC/tS8
    4.94 +Yt0Sph2GxFu4/5hOmtuUXf16vX9TrgVP1s9crOKA9V77piXJvzx84/nNl9ykO6Uw
    4.95 +p+rm26TZku19/5SQL+EqhmykqZ9an0+1hZH2F3gp3NZ7dEiaQ7lNVWT85/Ki0g/4
    4.96 +yio8jnNtH5sBiQIlBBgBAgAPBQJS3n3dAhsMBQkB4TOAAAoJEN1VvynfmxVB86MP
    4.97 +/irZ3rtclMnbCDBqloMdD1GW9Imtl4BSKKhunEKNWeCUD536/NCgerbxOKoaEfZ7
    4.98 +QkVKTd0UGXh6Y87o1gWCXPSCF6NYjbf3mKkEPm/UGK8W3lcTse91cq5oMaygQAHb
    4.99 +ky/p4FbqRPzSpq6gMY+jXPnf2BFZkKf9m3S4Z8HRD51pGeSisvcqLNUr6qufs9mQ
   4.100 +t1xtZjWnio4NiYkW71oIgeYxRMR82nvOyXTAiHGrpT4kWMxyFoqj68Gl1/ATNzai
   4.101 +kai2pb9rzwHRiLk+m/ldrsKJ2lGGG3QRgFMgdcGeTA0O09cLCO90KAzz6VCZXxDB
   4.102 +LANPhNhBtJLJ9TD3VkcW7L2oj5nlhNhoezj/dv2Gcv9IGyjZ5Gx7mMIRZIqvdvBu
   4.103 +XkbQg7fTaKKpZXsLXVeNPlv34raBLe+dTsAJac7Q5GvQ1YxnuAWVZfvLXr0QeuZO
   4.104 +9/45gqnpA6mNM6YNoMHIAMbMyDIp5ebGtsEPDAu57QgcvqHXjDKX3GiR9VgnYKJG
   4.105 +jNE+ehJFr5Xa7Q0ZmcuKgWv/7slOMvaubYVDeoKP2cH9kd7Tlqh1pkjrVZnNDRDK
   4.106 +h0RfvsvEISo7QuWvio+Hs3aDGdcCIde38FgtpqbsZFiG9Wjf0K2fR8asntc6uIBm
   4.107 +H0O110myJNSAZ1UqOSdI52vQf8O6y0D3CDhhXQJNvxRi
   4.108 +=NZw5
   4.109 +-----END PGP PRIVATE KEY BLOCK-----
     5.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     5.2 +++ b/test/DF9B1541.key	Wed Jun 25 18:48:18 2014 +0200
     5.3 @@ -0,0 +1,52 @@
     5.4 +-----BEGIN PGP PUBLIC KEY BLOCK-----
     5.5 +Version: GnuPG v2.0.22 (MingW32)
     5.6 +
     5.7 +mQINBFLefd0BEADB97Pmcz0yfkOWD2978HRUCUa7H4JpuDHZs+hurMlkuE7mLGh5
     5.8 +PAQ61/nL5gppl0cHFNlO7doG2gcRixWZfeQZywkJia5xNzcdjyAiC5jZ6IQpXk2T
     5.9 +wwzBIDYrU+9DhppY5hnE90yDv0MBS2SVjDergZTPDBbIYPTtPf5h51pVULCAtiyN
    5.10 +2Htv3M3tDwJJ9IrLFpJL+ClocgrmeDANKbico63qlBl9NjiUqdnt5INoE6/SnKSu
    5.11 +zaBE37C+/10bswFpjjVffyhu+hplxp6MlalZZYJEip6rmDe0P+nMbEmNvNuUmZwc
    5.12 +sPwvr1vRwhGGpZao2j4/SnDsKNNmsLrwyVEQboHYcKIgLEuHY4WtHDUt6umu7zdt
    5.13 +I6VDUoiSuNkVB+TM51HeQOoLZJ4Evcrdh6zKB2wWMW1RJQIknlMDwnRhHj+WJD06
    5.14 +texTzvAfDdsHV6NNs2WeUKesyivCyaKMPU7o95D+ZMi22CQ2qUCSLegivpnk/gKS
    5.15 +pM+JqwyAPnzJBW43qr13zA0tWMO2nzSzcYnRhTNTGeqkxn7t2Uc0ItMk360Xy7n6
    5.16 +yI2AL79daP0NGM9P0F4wD44FCnrvcDO0gbk3zJJnynnfFSF6Dk4/2sRUPsp2gm9B
    5.17 +hiHFt4w13mySETjd0sbcQYbpHZbJEPm2YY/q7rTCCCA106vg1S2IduY2GwARAQAB
    5.18 +tD9Wb2xrZXIgQmlyayAoVGVzdGtleSAtIGRvbid0IHVzZSkgPHZvbGtlci5iaXJr
    5.19 +QGRpZ2l0YWxla2hvLmNvbT6JAj8EEwECACkFAlLefd0CGwMFCQHhM4AHCwkIBwMC
    5.20 +AQYVCAIJCgsEFgIDAQIeAQIXgAAKCRDdVb8p35sVQYxgD/9eJ9cbUX2D3zef9VVm
    5.21 +I/2TThzFT4fyh7PlYCOXVQhQQHCYOlsDVOzs4ByjPJyXB1jfq53Zva/dI/MxewfL
    5.22 ++21ynOiUckwh28E0KIhzUY4KJ1H0YqA1lL998mDLKFnomShAs9qke/7M8K+xyGUd
    5.23 +HseZvJcxfv1CAO7ps3XUkgZaK7bGr+YfYhSDlenlXJGUTTNas3C7h6zva3yrMfGm
    5.24 +tWswijvYCvyGTlndtG88ri+LwQg25sR9h4VsQuikwY9YyB5nPwJN54Hxbu630WBh
    5.25 +1AUUmTNlMBP8qEHOy7Y2/OmPsOgyEKx57mGSw/bTRL5aB22+z+Xhus1CrDEPbQn2
    5.26 +Uaory2EUFvFD6N/bG8B37b/ov0WG1oMQTGlzqFtuV5dTSnwBiM85wYikbNTi/6mB
    5.27 +p8xtKT4u1yEU9RQKO0iWoeipnXFWfF1v4Hk/GGEkZ8gfLvbOJtO9+H+oTPgVEEhJ
    5.28 +vuZrXepax2mU2yh6oFvmqdC5CRdoz4wurOjBVDdX1yyPpU0dO8KsphmNDOwt24vP
    5.29 +waAClBiGxmp+i0jgxXH+zoCifxlilcO9jZ3Og0BLdD0APOsj6YweUSDNhnCyYRZx
    5.30 +0AZz7VeRXg8oKk8DSZXMNIYNonXerErro1XWmpmKypURy6EJnxoHY3ViTZWcN2ZP
    5.31 +UzBwABuMJtHIl76ypv1F4Q8he7kCDQRS3n3dARAAvBKO9C5GxXIjynYNLw10ZM4R
    5.32 +77XU0mvWkhbLQlFhVb7OECFdnAqF254JNb7NysH/KAqiQKPb8qHsaCfIl/tIakEa
    5.33 +egxMYe0ztaOJmvsTboW9AhVQx8T4/iHWVUOsdfgCHfMlFqwZBGVUe8mILnzvlfR/
    5.34 +fA2o+Y0sNh/wgb2QRovefofS0byn5VkAQtnGBt23QswFr9Mr+Gnw61oOY7gwTv42
    5.35 +52DlS2HvMeGYHCGKPhtKt7fv4cz27XZGdh/VIJsxqeZHnU61uOY1YDgf5Nvyxrbb
    5.36 +ODE2aHMJDduCBd4wsg/2WlU0L2uTe4fQB1vuuOluHTLSXPNSZ8o7rJqygL3POfN2
    5.37 +IeGwoCGZ+fgX4aVwyNSGAa2ccpurzVFV9LxxP9chZ0ItP+eiAnfGK/sb+4M2OrUD
    5.38 +9fZVqHRPx4y+8E6adF3BC1uUrcJ+kywXOoNmG30L9zqnL/A+4dBm2LgbYrjMXA/i
    5.39 +c3S9MS/cSRnf7AIrsvDyda753YPPNeXevf6XrCpDcN0a/wnIvq2dKVH4PaSAN4ti
    5.40 +qltowev4smxk3x3kt/+KUmrFp6IQHS1iDXXKLrgP0BuPBRFXsGe4NuHZ414iDTBD
    5.41 +rd0uNDxpkXhj+vGBa84Cjb+W95Q5Qxw9y44EU36kVyEqqiwAvBDvkliJvmBijS2C
    5.42 +1SSGkkyOckUxSq4s7FsAEQEAAYkCJQQYAQIADwUCUt593QIbDAUJAeEzgAAKCRDd
    5.43 +Vb8p35sVQfOjD/4q2d67XJTJ2wgwapaDHQ9RlvSJrZeAUiiobpxCjVnglA+d+vzQ
    5.44 +oHq28TiqGhH2e0JFSk3dFBl4emPO6NYFglz0ghejWI2395ipBD5v1BivFt5XE7Hv
    5.45 +dXKuaDGsoEAB25Mv6eBW6kT80qauoDGPo1z539gRWZCn/Zt0uGfB0Q+daRnkorL3
    5.46 +KizVK+qrn7PZkLdcbWY1p4qODYmJFu9aCIHmMUTEfNp7zsl0wIhxq6U+JFjMchaK
    5.47 +o+vBpdfwEzc2opGotqW/a88B0Yi5Ppv5Xa7CidpRhht0EYBTIHXBnkwNDtPXCwjv
    5.48 +dCgM8+lQmV8QwSwDT4TYQbSSyfUw91ZHFuy9qI+Z5YTYaHs4/3b9hnL/SBso2eRs
    5.49 +e5jCEWSKr3bwbl5G0IO302iiqWV7C11XjT5b9+K2gS3vnU7ACWnO0ORr0NWMZ7gF
    5.50 +lWX7y169EHrmTvf+OYKp6QOpjTOmDaDByADGzMgyKeXmxrbBDwwLue0IHL6h14wy
    5.51 +l9xokfVYJ2CiRozRPnoSRa+V2u0NGZnLioFr/+7JTjL2rm2FQ3qCj9nB/ZHe05ao
    5.52 +daZI61WZzQ0QyodEX77LxCEqO0Llr4qPh7N2gxnXAiHXt/BYLaam7GRYhvVo39Ct
    5.53 +n0fGrJ7XOriAZh9DtddJsiTUgGdVKjknSOdr0H/DustA9wg4YV0CTb8UYg==
    5.54 +=c+rW
    5.55 +-----END PGP PUBLIC KEY BLOCK-----
     6.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     6.2 +++ b/test/Makefile	Wed Jun 25 18:48:18 2014 +0200
     6.3 @@ -0,0 +1,51 @@
     6.4 +include ../Makefile.conf
     6.5 +
     6.6 +ifeq ($(BUILD_FOR),Windoze)
     6.7 +CXX=i686-w64-mingw32-g++
     6.8 +LD=i686-w64-mingw32-c++
     6.9 +LDFLAGS=-lstdc++
    6.10 +else ifeq ($(BUILD_FOR),MINGW32_NT-6.1)
    6.11 +CXX=g++ -std=gnu++11 -DWIN32
    6.12 +LD=g++
    6.13 +LDFLAGS=-pthread -L../src -lpEpEngine -lstdc++
    6.14 +else
    6.15 +CXX=g++ -std=gnu++11
    6.16 +LD=g++
    6.17 +LDFLAGS=-L~/lib -pthread -L../src -lpEpEngine -lstdc++
    6.18 +endif
    6.19 +CXXFLAGS=-g -O0
    6.20 +# CXXFLAGS=-O3 -DNDEBUG
    6.21 +
    6.22 +TARGET=pEpEngineTest
    6.23 +
    6.24 +ifeq ($(BUILD_FOR),Windoze)
    6.25 +all: $(TARGET).exe
    6.26 +
    6.27 +$(TARGET).exe: $(TARGET).o ../src/libpEpEngine.a
    6.28 +	$(CXX) $(LDFLAGS) -o $(TARGET).exe $(TARGET).o ../src/libpEpEngine.a
    6.29 +else ifeq ($(BUILD_FOR),MINGW32_NT-6.1)
    6.30 +all: $(TARGET).exe pEpEngine.dll
    6.31 +
    6.32 +$(TARGET).exe: $(TARGET).o ../src/libpEpEngine.a
    6.33 +	$(CXX) $(LDFLAGS) -o $(TARGET).exe $(TARGET).o ../src/libpEpEngine.a
    6.34 +else
    6.35 +all: $(TARGET)
    6.36 +
    6.37 +$(TARGET): $(TARGET).o
    6.38 +	$(CXX) $(LDFLAGS) -o $(TARGET) $(TARGET).o
    6.39 +endif
    6.40 +
    6.41 +%.o: %.cc ../pEpEngine.h
    6.42 +	$(CXX) $(CXXFLAGS) -c -o $@ $<
    6.43 +
    6.44 +pEpEngine.dll: ../src/pEpEngine.dll
    6.45 +	cp $< $@
    6.46 +
    6.47 +.PHONY: clean
    6.48 +
    6.49 +clean:
    6.50 +	rm -f *.o $(TARGET) *.exe *.a *~ pEpEngine.dll
    6.51 +
    6.52 +test: all
    6.53 +	LD_LIBRARY_PATH=~/lib:../src ./pEpEngineTest
    6.54 +
     7.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     7.2 +++ b/test/msg.asc	Wed Jun 25 18:48:18 2014 +0200
     7.3 @@ -0,0 +1,37 @@
     7.4 +-----BEGIN PGP MESSAGE-----
     7.5 +Version: GnuPG v1
     7.6 +Comment: GPGTools - http://gpgtools.org
     7.7 +
     7.8 +hQIMA0v8ThRgMMUcAQ//f+r+No4dufsFipIKAH0aIQ7/t970jM9h+iRVbI6hapvi
     7.9 ++w9alPbjraH24lDme7MGMOSnxMBXmZG/U/LUTaqUkIG+vUEeO7CHUQ24Y2hOW0H7
    7.10 +6WCsFLBPRhLuT8sZzFTMRZgwwBxtfzeDhMZtmQlXYMxbPS5tHuOG6eEqZzY2WtZc
    7.11 +tpasfiUmfDAOPVuGC+D5S/oA5Idb7dyuqTYhlIq35sKV3zmx4dz7M8sV+G34l8+1
    7.12 +83X2kT6GUqoN/Fbq4Jo7LGB59uPcjc9+P0QNo45pkN/BAIa83dHxkSH6ktMKEDaW
    7.13 +DX3+gVgz+ErAeXvlkKoxWUHdSyzVOXQh0oIaMN/7Fy8472vHl6QLJ8mHwaeCP6ZP
    7.14 +MXY7/Me3dgCBokd4ov5us8pSoNehQIMT4iyYyS0LMxGIC8YSoLYrBYRqVWxlukty
    7.15 +GYegJQ2RMKw9dRnG16NZVHlmWaFELhMt8zZYV8g+3qePnUNPGTpqnz8DUrlvATEN
    7.16 +s1zFhduI+a6appcxy1f8vWvV4nwpZGOM73yRywpJxfLSn86eU2Fs4pMIHX/79nQ0
    7.17 +0LZeebhrZrD/PoAmMdiiiY7ypViOpO7TdahmETK65q7KDreg4ba8PwE8dEZZabww
    7.18 +osMGFkNuMwNgDeRl9idLvC5sw6BfxlEQz9JdOI5AMUjQUUp8cF/EK5HYFqqhob6F
    7.19 +Ag4DeHVCKO8HDkcQB/42VLRXAOBeZi2Q2KlK5k0gdC09Dn7plP3VxAZYilvcWOfv
    7.20 +XnwvYp3uxspgrcbGl+LcdYKX9k1QBzW2J+jJEc8E22yoqeGO1wAG6w5nMvD0ZP2C
    7.21 +pbHSegHAsaa8QktR79T7+/qaLxsk5BPMyvTUslHIB/YgWE9yz/I1LItbyfE7VnjW
    7.22 +EBTGchV/so9kQdS2as4LyjubzwmQ8A+ri8au7E33LuORKfr2vPYVKa25yq8/oA18
    7.23 +oGQPn+/4fYJthnxGUPxz7VmRbs3g1vbta8rk7CDafak9tArXPipaSP85y5EfrbAh
    7.24 +cbZBYwrb6n8wyl+scaaFeOFwvGoAlJ55ll2RqgE1B/4or/DLhAczyGiQ485ZYuMi
    7.25 +xLFx+e5RuOn5s0wVUIq+2VarayvfEbY+5NNz3j+1Q1As/+S0L7bY+8TKTQovvc4Q
    7.26 +FCQrsSViu6J1wRIfNLLFSW6xHW0pcnIUHKJuOopqlYFzBruUQnbObB0HO5Wznwjb
    7.27 +rQ9olCYJyKIrlDdzYO5FDiOTXNlY45WNUmUTpmuNZKUZ2+3TCyPRbm7zRsbFWUmP
    7.28 +ZuBerHzbko6uNqKuQNf6D0aqb8SnhCdhFcxfKq2LeAWymPuXabWC3b6k3N4TBct9
    7.29 +VnJ1iJ6Fig4KA9MdBqiIX7gRhK5q6wuxyu0su7zzgnC9wveMR5/EQajNjAGnGUe5
    7.30 +0sDCAeeKIgN0L2zeoffRoID7FNajQs7rHxGrVccY+NslOIulgMEBHKYSCMwp7FbF
    7.31 +MpSWyhpv43hhBKoGkUK6nKb7BbCSV89DyXPmAqnhl/Hb4YjQoVhNgprwL7JDThIT
    7.32 +8FWrpQdTFqttU1rhIt1T1htmjdoFTZ1n4CtBAmlvwE+fFXeq0r9Oi8UBynVM2sLW
    7.33 +kPAEScxSEdykxKuR5jj2uZWviOf2RZKQ61OutyMuWjqgH07pZBxM2NGMtQIufL9J
    7.34 +a2uO1291DZTlUnJQ0p5JkF4l2zmKxynsgi5YJM5j1L63j9LaDgWKJZPVI6T5zClG
    7.35 +GQGYIFB5+6mHCQLG1bY7+fKK+qrZUv1BGx+CoYl1pyf7nxIAhEPArSFXrEFVHgHB
    7.36 +sCT2cBlyuquSnUQs0z0sPlLmHlZ98VonFwf2f3nVuCq+0WHRnQ9Xe//c4UBbMoWA
    7.37 +a9zqyamBQ+vvwzFSVkg6//R6Grsa9jHcwBogxCHg2C9tOm+dgANVzvtKha8GCNem
    7.38 +9TFmu2s=
    7.39 +=CwSp
    7.40 +-----END PGP MESSAGE-----
     8.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     8.2 +++ b/test/signature.asc	Wed Jun 25 18:48:18 2014 +0200
     8.3 @@ -0,0 +1,7 @@
     8.4 +-----BEGIN PGP SIGNATURE-----
     8.5 +Version: GnuPG v1.4.10 (GNU/Linux)
     8.6 +
     8.7 +iEYEARECAAYFAlNs9EQACgkQb7KfG+Kr+JAXrwCdEkuVvInUBktNmYBdPm8iJlUD
     8.8 +cA8An0N+j49d4GSUYLyf6CfA8FItdCPl
     8.9 +=A3cw
    8.10 +-----END PGP SIGNATURE-----
     9.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     9.2 +++ b/test/t1.txt	Wed Jun 25 18:48:18 2014 +0200
     9.3 @@ -0,0 +1,10 @@
     9.4 +Content-Type: text/plain; charset=us-ascii
     9.5 +Content-Disposition: inline
     9.6 +Content-Transfer-Encoding: quoted-printable
     9.7 +
     9.8 +Ohne Anhang.
     9.9 +--=20
    9.10 +Volker Birk, Oberer Graben 4, CH-8400 Winterthur, Schweiz,
    9.11 +Erde, Solar-System, Orion Arm, Milchstrasse, Lokale Gruppe,
    9.12 +Virgo-Superhaufen, Coma-Virgo-Filament. mailto:dingens@bumens.org
    9.13 +http://fdik.org  D-IRCNet fdik!vb@dragon.pibit.ch
    10.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
    10.2 +++ b/test/t2.txt	Wed Jun 25 18:48:18 2014 +0200
    10.3 @@ -0,0 +1,1 @@
    10.4 +Something else