summaryrefslogtreecommitdiff
path: root/mail
diff options
context:
space:
mode:
authorIvan Alejandro <ivanalejandro0@gmail.com>2014-02-17 18:50:53 -0300
committerIvan Alejandro <ivanalejandro0@gmail.com>2014-02-17 18:50:53 -0300
commit6bc9a34e26b20ebabb8a8546df98ac8a0d6d459f (patch)
treebafd823717e9eda7f91c36743f6f5a0ed61a882c /mail
parent02ff011adb0daca62164a4a78e846a4a0a1f2f35 (diff)
pep8 fixes.
Diffstat (limited to 'mail')
-rw-r--r--mail/src/leap/mail/imap/service/imap-server.tac33
1 files changed, 18 insertions, 15 deletions
diff --git a/mail/src/leap/mail/imap/service/imap-server.tac b/mail/src/leap/mail/imap/service/imap-server.tac
index feeca066..651f71b7 100644
--- a/mail/src/leap/mail/imap/service/imap-server.tac
+++ b/mail/src/leap/mail/imap/service/imap-server.tac
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
-# imap-server.tac
+# imap-server.tac
# Copyright (C) 2013,2014 LEAP
#
# This program is free software: you can redistribute it and/or modify
@@ -97,8 +97,10 @@ print "[+] Running LEAP IMAP Service"
bmconf = os.environ.get("LEAP_MAIL_CONF", "")
if not bmconf:
- print "[-] Please set LEAP_MAIL_CONF environment variable pointing to your config."
- sys.exit(1)
+ print ("[-] Please set LEAP_MAIL_CONF environment variable "
+ "pointing to your config.")
+ sys.exit(1)
+
SECTION = "leap_mail"
cp = ConfigParser.ConfigParser()
cp.read(bmconf)
@@ -111,11 +113,11 @@ passwd = unicode(cp.get(SECTION, "passwd"))
port = 1984
if not userid or not uuid:
- print "[-] Config file missing userid or uuid field"
- sys.exit(1)
+ print "[-] Config file missing userid or uuid field"
+ sys.exit(1)
if not passwd:
- passwd = unicode(getpass.getpass("Soledad passphrase: "))
+ passwd = unicode(getpass.getpass("Soledad passphrase: "))
secrets = os.path.expanduser("~/.config/leap/soledad/%s.secret" % (uuid,))
@@ -129,16 +131,17 @@ tempdir = "/tmp/"
# Ad-hoc soledad/keymanager initialization.
-soledad = initialize_soledad(uuid, userid, passwd, secrets, localdb, gnupg_home, tempdir)
+soledad = initialize_soledad(uuid, userid, passwd, secrets,
+ localdb, gnupg_home, tempdir)
km_args = (userid, "https://localhost", soledad)
-km_kwargs = {
- "token": "",
- "ca_cert_path": "",
- "api_uri": "",
- "api_version": "",
- "uid": uuid,
- "gpgbinary": "/usr/bin/gpg"
-}
+km_kwargs = {
+ "token": "",
+ "ca_cert_path": "",
+ "api_uri": "",
+ "api_version": "",
+ "uid": uuid,
+ "gpgbinary": "/usr/bin/gpg"
+}
keymanager = KeyManager(*km_args, **km_kwargs)
##################################################