I'm working on application which involves login to a email server vie IMAP. When I'm logining at Gmail, I always get "Web login required." and a link to "Control, protect, and secure your account, all in one place". I've enabled using less secure applications in the setting and IMAP in the Gmail settings and still the error.
The "web login required error" means that Gmail
- is not recognizing your password or
- you are signing from a new location or device or
- you have enabled 2-Step Verification for your account.
- You need to generate an Application specific password for MsgExtract.
See Generating an application password when 2-Step verification is enabled in Gmail Google detects your login as suspicious. It could be because you are login in from a different country.
Refer to the following page on how to proceed to solve this issue: