[mew-dist 27336] mew-imap-proxy-server
Tatsuya Kinoshita
tats at example.com
2006年 9月 24日 (日) 00:58:30 JST
mew-pop-proxy-server関連のdoc fixと、ついでにmew-imap-proxy-server,
mew-imap-proxy-portを実装してみましたのでパッチを添付します。
手元には環境が無く動作は試せていません。どなたか試してみていただけ
ませんか?
--
木下達也
-------------- next part --------------
Unlimited permission is granted to use, copy, distribute and/or modify
this patch. There is NO WARRANTY.
--- mew.orig/info/mew.texi
+++ mew/info/mew.texi
@@ -11430,14 +11430,16 @@
"pop-server", "pop-port", "pop-ssh-server", "pop-ssl", "pop-ssl-port",
"pop-user", "pop-auth", "pop-auth-list",
"pop-size", "pop-header-only", "pop-delete", "pop-body-lines",
+"pop-proxy-server", "pop-proxy-port",
"imap-server", "imap-port", "imap-ssh-server", "imap-ssl", "imap-ssl-port",
"imap-user", "imap-auth", "imap-auth-list",
"imap-size", "imap-header-only", "imap-delete",
"imap-trash-folder", "imap-queue-folder", "imap-spam-field", "imap-spam-word",
+"imap-proxy-server", "imap-proxy-port",
"nntp-server", "nntp-port", "nntp-ssh-server", "nntp-ssl", "nntp-ssl-port",
"nntp-user", "nntp-size", "nntp-header-only",
"nntp-msgid-user", "nntp-msgid-domain",
-"ssl-cert-directory", "ssl-verify-level',
+"ssl-cert-directory", "ssl-verify-level",
"inbox-folder", "queue-folder", "postq-folder",
"mailbox-type", "mbox-command", "mbox-command-arg",
"signature-file", "content-type", "refile-guess-alist",
--- mew.orig/mew-config.el
+++ mew/mew-config.el
@@ -276,6 +276,12 @@
(defun mew-imap-ssl-port (&optional case)
(mew-cfent-value case "imap-ssl-port" mew-imap-ssl-port))
+(defun mew-imap-proxy-server (&optional case)
+ (mew-cfent-value case "imap-proxy-server" mew-imap-proxy-server))
+
+(defun mew-imap-proxy-port (&optional case)
+ (mew-cfent-value case "imap-proxy-port" mew-imap-proxy-port))
+
(defun mew-imap-user (&optional case)
(mew-cfent-value case "imap-user" mew-imap-user))
--- mew.orig/mew-imap.el
+++ mew/mew-imap.el
@@ -1162,6 +1162,8 @@
(sshsrv (mew-imap-ssh-server case))
(sslp (mew-imap-ssl case))
(sslport (mew-imap-ssl-port case))
+ (proxysrv (mew-imap-proxy-server case))
+ (proxyport (mew-imap-proxy-port case))
;; dirty but necessary for migration
(mailbox (unless (eq directive 'list)
(mew-imap-utf-7-encode-string
@@ -1189,6 +1191,8 @@
(setq lport (mew-ssl-pnm-to-lport sslname))
(when lport
(setq process (mew-imap-open pnm mew-ssl-localhost lport no-msg)))))
+ (proxysrv
+ (setq process (mew-imap-open pnm proxysrv proxyport no-msg)))
(t
(setq process (mew-imap-open pnm server port no-msg))))
(if (null process)
--- mew.orig/mew-imap2.el
+++ mew/mew-imap2.el
@@ -397,6 +397,8 @@
(sshsrv (mew-imap-ssh-server case))
(sslp (mew-imap-ssl case))
(sslport (mew-imap-ssl-port case))
+ (proxysrv (mew-imap-proxy-server case))
+ (proxyport (mew-imap-proxy-port case))
process sshname sshpro sslname sslpro lport tls)
(cond
(sshsrv
@@ -414,6 +416,8 @@
(setq lport (mew-ssl-pnm-to-lport sslname))
(when lport
(setq process (mew-imap2-open pnm mew-ssl-localhost lport)))))
+ (proxysrv
+ (setq process (mew-imap2-open pnm proxysrv proxyport)))
(t
(setq process (mew-imap2-open pnm server port))))
(if (null process)
--- mew.orig/mew-vars.el
+++ mew/mew-vars.el
@@ -737,15 +737,15 @@
:type 'boolean)
(defcustom mew-pop-proxy-server nil
- "*The name of PROXY server connecting to POP server."
+ "*The name of POP proxy server."
:group 'mew-pop
:type '(choice (const :tag "Not use" nil)
(string :tag "Pop proxy server")))
(defcustom mew-pop-proxy-port nil
- "*The port of PROXY proxy."
+ "*The port for POP proxy."
:group 'mew-pop
- :type 'string)
+ :type '(choice string (const nil)))
(defvar mew-pop-timeout-time 4)
@@ -854,6 +854,17 @@
:group 'mew-imap
:type '(choice (const nil) (repeat string)))
+(defcustom mew-imap-proxy-server nil
+ "*The name of IMAP proxy server."
+ :group 'mew-imap
+ :type '(choice (const :tag "Not use" nil)
+ (string :tag "Imap proxy server")))
+
+(defcustom mew-imap-proxy-port nil
+ "*The port for IMAP proxy."
+ :group 'mew-imap
+ :type '(choice string (const nil)))
+
(defvar mew-imap-timeout-time 4)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
--- mew.orig/mew-vars2.el
+++ mew/mew-vars2.el
@@ -1018,13 +1018,16 @@
\"imap-user\", \"imap-auth\", \"imap-auth-list\",
\"imap-size\", \"imap-header-only\", \"imap-delete\",
\"imap-trash-folder\", \"imap-queue-folder\", \"imap-spam-field\", \"imap-spam-word\",
+\"imap-proxy-server\", \"imap-proxy-port\",
\"nntp-server\", \"nntp-port\", \"nntp-ssh-server\", \"nntp-ssl\", \"nntp-ssl-port\",
\"nntp-user\", \"nntp-size\", \"nntp-header-only\",
\"nntp-msgid-user\", \"nntp-msgid-domain\",
+\"ssl-cert-directory\", \"ssl-verify-level\",
\"inbox-folder\", \"queue-folder\", \"postq-folder\",
\"mailbox-type\", \"mbox-command\", \"mbox-command-arg\",
-\"use-retrieve\", \"signature-file\", \"content-type\", \"refile-guess-alist\",
-\"spam-prog\", \"spam-prog-args\", \"ham-prog\", \"ham-prog-args\".
+\"signature-file\", \"content-type\", \"refile-guess-alist\",
+\"spam-prog\", \"spam-prog-args\", \"ham-prog\", \"ham-prog-args\",
+\"use-old-pgp\".
from = name <user at example.com>
message-id = *random*.smtp-msgid-user at example.com
Mew-dist メーリングリストの案内