{"id":2015,"date":"2018-05-08T00:00:56","date_gmt":"2018-05-07T16:00:56","guid":{"rendered":"https:\/\/cloudbool.com\/archive\/?p=464"},"modified":"2018-05-08T00:00:56","modified_gmt":"2018-05-07T16:00:56","slug":"use-xinetd-to-resolve-gmail-smtp-imap","status":"publish","type":"post","link":"https:\/\/cloudbool.com\/archive\/use-xinetd-to-resolve-gmail-smtp-imap.html","title":{"rendered":"\u5229\u7528xinetd\u89e3\u51b3Gmail\u65e0\u6cd5\u6536\u53d1\u90ae\u4ef6\u95ee\u9898"},"content":{"rendered":"<p>\u56e0\u4e3a\u4e00\u76f4\u662f\u7528\u7684macOS\uff0c\u90ae\u4ef6\u6536\u53d1\u7528\u7684\u662f\u7cfb\u7edf\u81ea\u5e26\u7684mail.app\uff0c\u4e4b\u524d\u8fd8\u7528\u7684\u597d\u597d\u7684\uff0c\u8fd9\u6bb5\u65f6\u95f4\u4e0d\u77e5\u9053\u4ec0\u4e48\u65f6\u5019\u5f00\u59cb\u53d1\u73b0\u5c31\u65e0\u6cd5\u6b63\u5e38\u4f7f\u7528Gmail\u6536\u53d1\u90ae\u4ef6\u4e86\u3002\u672c\u6765\u4ee5\u4e3a\u662f\u5be1\u5987\u7f51\u4e00\u65f6\u534a\u4f1a\u62bd\u98ce\u5c31\u6ca1\u7ba1\uff0c\u4f46\u662f\u6700\u8fd1\u53d1\u73b0\u60c5\u51b5\u8d8a\u6765\u8d8a\u4e25\u91cd\u4e86\uff0c\u4e25\u91cd\u5f71\u54cd\u90ae\u4ef6\u7684\u6536\u53d1\uff0c\u53ea\u80fd\u60f3\u529e\u6cd5\u901a\u8fc7\u81ea\u5df1\u7684\u670d\u52a1\u5668\u6536\u53d1\u90ae\u4ef6\u4e86\u3002<br \/>\n<!--more--><br \/>\n\u672c\u6765\u60f3\u770b\u770bmail.app\u81ea\u8eab\u662f\u5426\u652f\u6301\u4ee3\u7406\u8bbe\u7f6e\u7684\uff0c\u4f46\u662f\u627e\u4e86\u4e00\u5708\u518d\u52a0\u4e0aGoogle\u4e86\u4e00\u628a\u4e4b\u540e\u53d1\u73b0\u8fd9\u8d27\u672c\u8eab\u4e0d\u652f\u6301\u8d70\u4ee3\u7406\u3002\u4f46\u662f\u4e4b\u524d\u770b\u6709\u7f51\u53cb\u8bf4\uff0c\u5f00\u542fSS\u4e4b\u540e\u53ef\u4ee5\u6b63\u5e38\u4f7f\u7528mail.app\uff0c\u4e8e\u662f\u6253\u5f00\u8bb8\u4e45\u4e0d\u7528\u7684SS\u4e4b\u540e\u53d1\u73b0\uff0c\u6709\u7684\u65f6\u5019\u8fd8\u771f\u80fd\u6b63\u5e38\u6536\u53d1\u90ae\u4ef6\u4e86\u3002<br \/>\n\u4f46\u662f\u8d70SS\u4e4b\u540e\u8fd8\u662f\u53d1\u73b0\u6709\u95ee\u9898\uff0c\u8fd8\u662f\u4f1a\u95f4\u6b47\u6027\u7684\u6536\u4e0d\u5230\u90ae\u4ef6\u6216\u8005\u6709\u5ef6\u8fdf\uff0c\u4e8e\u662f\u6211\u53c8\u5728\u60f3\uff0c\u80fd\u4e0d\u80fd\u901a\u8fc7\u5f3a\u5927\u7684Nginx\u6765\u89e3\u51b3\u8fd9\u4e2a\u95ee\u9898\u3002<br \/>\nGoogle\u4e86\u4e00\u628a\u4e4b\u540e\u53d1\u73b0\uff0c\u7528Nginx\u8fd8\u662f\u592a\u9ebb\u70e6\uff0c\u4f46\u662f\u53d1\u73b0\u4e86\u4e00\u4e2a\u66f4\u6709\u6548\u7684\u529e\u6cd5\uff0c\u5c31\u662f\u4f7f\u7528xinetd\u901a\u8fc7\u7aef\u53e3\u8f6c\u53d1\u7684\u65b9\u5f0f\u5c06Gmail\u76f8\u5173\u6d41\u91cf\u901a\u8fc7\u4ee3\u7406\u670d\u52a1\u5668\u8f6c\u53d1\u7ed9Gmail\u5b9e\u73b0\u6b63\u5e38\u6536\u53d1Gmail\u3002<br \/>\n\u5b89\u88c5xinetd\u4e5f\u5f88\u7b80\u5355\uff0c\u4e00\u884c\u547d\u4ee4\u5c31\u89e3\u51b3\uff0c\u62ff\u4e86\u624b\u4e0a\u4e00\u4e2a<a href=\"https:\/\/cloudbool.com\/archive\/go\/virmach\">Virmach<\/a>\u5bb6\u7684128MB KVM VPS\u8bd5\u4e86\u4e0b\uff0c\u7cfb\u7edf\u662fDebian9\uff0c\u4e00\u884c\u547d\u4ee4\u5c31\u89e3\u51b3\uff1a<\/p>\n<pre><code>apt install xinetd\n<\/code><\/pre>\n<p>\u7136\u540e\u589e\u52a0\u914d\u7f6e\uff1a<\/p>\n<pre><code>cd \/etc\/xinetd.d\/\nvim gmail\nservice imap\n{\n    type = UNLISTED\n    port = 993\n    bind = 0.0.0.0\n    socket_type = stream\n    wait = no\n    user = nobody\n    redirect = imap.gmail.com 993\n    per_source = UNLIMITED\n    cps = 100 2\n}\nservice smtp-465\n{\n    type = UNLISTED\n    port = 465\n    bind = 0.0.0.0\n    socket_type = stream\n    wait = no\n    user = nobody\n    redirect = smtp.gmail.com 465\n    per_source = UNLIMITED\n    cps = 100 2\n}\nservice smtp-587\n{\n    type = UNLISTED\n    port = 587\n    bind = 0.0.0.0\n    socket_type = stream\n    wait = no\n    user = nobody\n    redirect = smtp.gmail.com 587\n    per_source = UNLIMITED\n    cps = 100 2\n}\n<\/code><\/pre>\n<p>\u4fdd\u5b58\u4e4b\u540e\uff0c\u91cd\u542f\u4e00\u4e0bxinetd\uff1a<\/p>\n<pre><code>systemctl restart xinetd\n<\/code><\/pre>\n<p>\u56e0\u4e3a\u6211\u53ea\u9700\u8981\u672c\u5730\u7684\u90ae\u4ef6\u5ba2\u6237\u7aef\u4f7f\u7528\uff0c\u4e8e\u662f\u53ea\u8981\u5728\u672c\u5730hosts\u6587\u4ef6\u6dfb\u52a0\u4e24\u884c\u8bb0\u5f55\u5c31\u884c\uff1a<\/p>\n<pre><code>sudo vim \/etc\/hosts\nxxx.xxx.xxx.xxx smtp.gmail.com\nxxx.xxx.xxx.xxx imap.gmail.com\n<\/code><\/pre>\n<p>\u9000\u51famail.app\u518d\u6b21\u6253\u5f00\uff0c\u53d1\u73b0\u5c31\u80fd\u6b63\u5e38\u4f7f\u7528\u4e86\uff0c\u5b8c\u7f8e~<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u56e0\u4e3a\u4e00\u76f4\u662f\u7528\u7684macOS\uff0c\u90ae\u4ef6\u6536\u53d1\u7528\u7684\u662f\u7cfb\u7edf\u81ea\u5e26\u7684mail.app\uff0c\u4e4b\u524d\u8fd8\u7528\u7684\u597d\u597d\u7684\uff0c\u8fd9\u6bb5\u65f6\u95f4\u4e0d\u77e5\u9053\u4ec0\u4e48\u65f6\u5019\u5f00 &hellip;<\/p>\n<p class=\"read-more\"> <a class=\"\" href=\"https:\/\/cloudbool.com\/archive\/use-xinetd-to-resolve-gmail-smtp-imap.html\"> <span class=\"screen-reader-text\">\u5229\u7528xinetd\u89e3\u51b3Gmail\u65e0\u6cd5\u6536\u53d1\u90ae\u4ef6\u95ee\u9898<\/span> \u67e5\u770b\u5168\u6587 &raquo;<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""}},"footnotes":""},"categories":[182],"tags":[220],"class_list":["post-2015","post","type-post","status-publish","format-standard","hentry","category-linux","tag-xinetd"],"_links":{"self":[{"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/posts\/2015","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/comments?post=2015"}],"version-history":[{"count":0,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/posts\/2015\/revisions"}],"wp:attachment":[{"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/media?parent=2015"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/categories?post=2015"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/tags?post=2015"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}