summaryrefslogtreecommitdiff
path: root/src/leap/mail/imap/service/imap-server.tac
diff options
context:
space:
mode:
authorKali Kaneko <kali@leap.se>2015-11-26 21:27:23 -0400
committerKali Kaneko <kali@leap.se>2015-12-15 02:30:19 -0400
commit8ddddd77478984777be79e817458183a41f0a978 (patch)
treedb50d1332acd997df5bb732a2dcf0acde3d80207 /src/leap/mail/imap/service/imap-server.tac
parentcbfc7cd2acb1ab1d58030ab9a5205a295be1ca5d (diff)
[feat] credentials handling: use twisted.cred
Diffstat (limited to 'src/leap/mail/imap/service/imap-server.tac')
-rw-r--r--src/leap/mail/imap/service/imap-server.tac9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/leap/mail/imap/service/imap-server.tac b/src/leap/mail/imap/service/imap-server.tac
index 2045757..c4d602d 100644
--- a/src/leap/mail/imap/service/imap-server.tac
+++ b/src/leap/mail/imap/service/imap-server.tac
@@ -1,3 +1,4 @@
+#!/usr/bin/env python
# -*- coding: utf-8 -*-
# imap-server.tac
# Copyright (C) 2013,2014 LEAP
@@ -27,6 +28,9 @@ userid = 'user@provider'
uuid = 'deadbeefdeadabad'
passwd = 'supersecret' # optional, will get prompted if not found.
"""
+
+# TODO -- this .tac file should be deprecated in favor of bitmask.core.bitmaskd
+
import ConfigParser
import getpass
import os
@@ -112,7 +116,7 @@ tempdir = "/tmp/"
print "[~] user:", userid
soledad = initialize_soledad(uuid, userid, passwd, secrets,
- localdb, gnupg_home, tempdir)
+ localdb, gnupg_home, tempdir, userid=userid)
km_args = (userid, "https://localhost", soledad)
km_kwargs = {
"token": "",
@@ -131,7 +135,8 @@ keymanager = KeyManager(*km_args, **km_kwargs)
def getIMAPService():
- factory = imap.LeapIMAPFactory(uuid, userid, soledad)
+ soledad_sessions = {userid: soledad}
+ factory = imap.LeapIMAPFactory(soledad_sessions)
return internet.TCPServer(port, factory, interface="localhost")