From 02ff011adb0daca62164a4a78e846a4a0a1f2f35 Mon Sep 17 00:00:00 2001 From: Ivan Alejandro Date: Mon, 17 Feb 2014 18:46:12 -0300 Subject: Update keymanager kwargs, related to #5120. --- mail/src/leap/mail/imap/service/imap-server.tac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'mail/src/leap') diff --git a/mail/src/leap/mail/imap/service/imap-server.tac b/mail/src/leap/mail/imap/service/imap-server.tac index b65bb17..feeca06 100644 --- a/mail/src/leap/mail/imap/service/imap-server.tac +++ b/mail/src/leap/mail/imap/service/imap-server.tac @@ -132,7 +132,7 @@ tempdir = "/tmp/" soledad = initialize_soledad(uuid, userid, passwd, secrets, localdb, gnupg_home, tempdir) km_args = (userid, "https://localhost", soledad) km_kwargs = { - "session_id": "", + "token": "", "ca_cert_path": "", "api_uri": "", "api_version": "", -- cgit v1.2.3 From 6bc9a34e26b20ebabb8a8546df98ac8a0d6d459f Mon Sep 17 00:00:00 2001 From: Ivan Alejandro Date: Mon, 17 Feb 2014 18:50:53 -0300 Subject: pep8 fixes. --- mail/src/leap/mail/imap/service/imap-server.tac | 33 ++++++++++++++----------- 1 file changed, 18 insertions(+), 15 deletions(-) (limited to 'mail/src/leap') diff --git a/mail/src/leap/mail/imap/service/imap-server.tac b/mail/src/leap/mail/imap/service/imap-server.tac index feeca06..651f71b 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) ################################################## -- cgit v1.2.3