Email

Gmail 屏蔽 mutt

  • December 21, 2018

當我嘗試使用 mutt 登錄 gmail 時,它會閃現一個帶有 url 的快速 Webalert,例如 accounts.gmail.com 之類的東西。我看到或複制它太快了。然後它說登錄失敗。

然後我收到一封來自 Gmail 的電子郵件,內容是:

Google Account: sign-in attempt blocked

Hi Adam, 

We recently blocked a sign-in attempt to your Google Account [a...@gmail.com]. 

Sign in attempt details
Date & Time: Wednesday, December 10, 2014 11:55:21 PM UTC 
Location: Utah, USA 

If this wasn't you
Please review your Account Activity page at         https://security.google.com/settings/security/activity to see if anything looks suspicious.     Whoever tried to sign in to your account knows your password; we recommend that you change it right away. 

If this was you
You can switch to an app made by Google such as Gmail to access your account (recommended) or change your settings at https://www.google.com/settings/security/lesssecureapps so that your account is no longer protected by modern security standards. 

To learn more, see https://support.google.com/accounts/answer/6010255. 

Sincerely,
The Google Accounts team

我可以轉到連結並啟用“訪問安全性較低的應用程序”,然後我就可以正常登錄,但是有沒有辦法使用 mutt 登錄而無需在 Gmail 中打開這個安全性較低的選項?

更新:

我在 mac os x Yosemite 當我執行 mutt -v 時,在編譯選項中,它確實包含 +USE_SSL_OPENSSL 我沒有使用Google兩步驗證我沒有使用應用程序特定密碼這是我的消息當我嘗試登錄時得到:

Reading imaps://imap.gmail.com:993/INBOX...
Looking up imap.gmail.com...
Connecting to imap.gmail.com...
TLSv1.2 connection using TLSv1/SSLv3 (ECDHE-RSA-AES128-GCM-SHA256)
Logging in...
[WEBALERT https://accounts.google.com/ContinueSignIn?sarp=1&scc=1&plt=AKgnsbsm0P......

我找到了這個答案,但它沒有用:https ://stackoverflow.com/a/25209735/1665818

我終於通過啟用Google兩步驗證並為 mutt 使用應用程序專用密碼來讓它工作。

更多詳情:

我在我的 Google 帳戶上啟用了兩步驗證,這意味著當我登錄 Google 時,我必須從文本或 Google Authenticator 應用程序中輸入密碼。

然後我必須為 mutt 獲取一個特定於應用程序的密碼。您可以在此處生成應用專用密碼。

然後我使用該應用程序專用密碼而不是我的普通密碼登錄 mutt。然後我不必輸入密碼。

引用自:https://unix.stackexchange.com/questions/172666