diff --git a/lacre/daemon.py b/lacre/daemon.py index 9a0a428..dffad4d 100644 --- a/lacre/daemon.py +++ b/lacre/daemon.py @@ -25,7 +25,7 @@ lacre.init_logging(conf.get_item("logging", "config")) LOG = logging.getLogger(__name__) import lacre.mailgate as gate -import lacre.keycache as kcache +import lacre.keyring as kcache class MailEncryptionProxy: @@ -53,7 +53,7 @@ class MailEncryptionProxy: return RESULT_OK -def _init_controller(keys: kcache.KeyCache, tout: float = 2.5): +def _init_controller(keys: kcache.KeyCache, tout: float = 5): proxy = MailEncryptionProxy(keys) host, port = conf.daemon_params() LOG.info(f"Initialising a mail Controller at {host}:{port}") diff --git a/lacre/keycache.py b/lacre/keyring.py similarity index 98% rename from lacre/keycache.py rename to lacre/keyring.py index 3a3ad99..49d8527 100644 --- a/lacre/keycache.py +++ b/lacre/keyring.py @@ -1,4 +1,4 @@ -"""A cache of OpenPGP keys known to Lacre. +"""Data structures and utilities to make keyring access easier. IMPORTANT: This module has to be loaded _after_ initialisation of the logging module. diff --git a/lacre/mailgate.py b/lacre/mailgate.py index 4f139b6..1743b5e 100644 --- a/lacre/mailgate.py +++ b/lacre/mailgate.py @@ -40,7 +40,7 @@ from M2Crypto import BIO, SMIME, X509 import logging import lacre.text as text import lacre.config as conf -import lacre.keycache as kcache +import lacre.keyring as kcache from lacre.mailop import KeepIntact, InlineOpenPGPEncrypt, MimeOpenPGPEncrypt diff --git a/test/modules/test_lacre_keycache.py b/test/modules/test_lacre_keycache.py index 2f0be90..4c7f496 100644 --- a/test/modules/test_lacre_keycache.py +++ b/test/modules/test_lacre_keycache.py @@ -1,4 +1,4 @@ -from lacre.keycache import KeyCache +from lacre.keyring import KeyCache import unittest