muquit / mailsend-go

mailsend-go is a multi-platform command line tool to send mail via SMTP protocol
Other
168 stars 16 forks source link

Android build not work #36

Closed pedroalbanese closed 3 years ago

pedroalbanese commented 3 years ago

Hello, I'm trying to run the program on a smartphone with Android armel. I get the error that the connection was refused

2020/12/28 21:05:45 ERROR: dial tcp: lookup smtp.gmail.com on [::1]:53: read udp [::1]:33152->[::1]:53: read: connection refused

How to proceed?

Thanks in advance.

muquit commented 3 years ago

It appears it is trying resolve smtp.gmail.com from DNS server running on localhost at port 53. As there is no DNS server running on loclahost, connection refused message is shown. There should be a way to configure DNS server to use in your system or specify the IP address of smtp.gmail.com.

pedroalbanese commented 3 years ago

Now it seems to work, but I think i'm putting the wrong IP, because it gives a timeout error

Any ideas on how to find out the IP of the smtp server? (I don't even know if it's static)

pedroalbanese commented 3 years ago

Ok, I can get the IP with wget, but I get an authentication error:

ERROR: 535 Authentication credentials invalid

2020/12/28 19:00:25 ERROR: 535 Authentication credentials invalid

muquit commented 3 years ago

If the authentication credential is correct, login to gmail and see if gmail intentionally blocked it. If it did, there will be instructions on what to do.

pedroalbanese commented 3 years ago

I think I should find another email service:

SMTP Error: 535 5.7.8 Authentication credentials invalid

"Since Google is starting to disable access to the Google Account for less secure apps, the application option is no longer available. We recommend disabling access to less secure apps now. Start using alternatives to less secure apps.

As you gradually disable access from less secure apps to Google Accounts, Google will send you email notifications about changes that affect you."

But this message appears only on Android, not when running from Windows7

pedroalbanese commented 3 years ago

Cool, now it worked. I needed another email service.

Thank you very much!