Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

msmtp configuration wrong in multiple ways #85

Open
kevinwheeler opened this issue Jul 20, 2022 · 2 comments
Open

msmtp configuration wrong in multiple ways #85

kevinwheeler opened this issue Jul 20, 2022 · 2 comments
Assignees

Comments

@kevinwheeler
Copy link

kevinwheeler commented Jul 20, 2022

USEREMAIL mispelled as USRMAIL

MAILPROV uses smtp.google.com instead of smtp.gmail.com and I'm not sure if the port is supposed to be here either

USERLOC is unused

cat <<EOF> .msmtprc assumes you are running the command inside /root I think.

MAILPORT variable is referenced but never defined

The table of contents link in the README.md file that goes to the MSMTP section doesn't work.

It may be good to note that there is a way to enter your password from command line interactive standard input without having to ever type it out in a command line command otherwise, because commands can get logged in .bash_history for example as noted here https://wiki.archlinux.org/title/msmtp

It also maybe should be noted to not store the MSMTP script in a file if you want to avoid having your password / the PWDEMAIL stored in a file in plain text.

If you aren't going to use OAuth, you need to set up an app password for your gmail account. You can't just use your main password. The process for doing so can be found here https://caupo.ee/blog/2020/07/05/how-to-install-msmtp-to-debian-10-for-sending-emails-with-gmail/

I had some trouble with the GPG stuff, but I forget what exactly.

There quite possibly could be more errors, because as of 5 hours ago, I didn't have any experience with any of this, and I don't know what many of the commands in the MSMTP setup script are doing.

It would be good to at least note that the script is broken and any caveats in the meantime if no one wants to spend the time to implement all of the changes right now. I spent a lot of extra time investigating why things weren't working before realizing that the config said smtp.google.com instead of smtp.gmail.com

I also think it would be good to mention that people can install either msmtp or Exim4. (I think this is the case, right?). With no context about any of this stuff, it took me a bit to realize this.

Thank you Nacho Man and everyone who has put this repo together 🙂

@imthenachoman
Copy link
Owner

USEREMAIL mispelled as USRMAIL

Fixed. Thanks!

@hellresistor Could you look through the other comments? You had added the section so I thought you might know best?

@hellresistor
Copy link
Contributor

hellresistor commented Dec 21, 2022

@kevinwheeler

cat <<EOF> .msmtprc assumes you are running the command inside /root I think.

yes.

It would be good to at least note that the script is broken and any caveats in the meantime if no one wants to spend the time to implement all of the changes right now. I spent a lot of extra time investigating why things weren't working before realizing that the config said smtp.google.com instead of smtp.gmail.com

When uploaded, was working .... some time ago ... (years...)

It may be good to note that there is a way to enter your password from command line interactive standard input without having to ever type it out in a command line command otherwise, because commands can get logged in .bash_history for example as noted here https://wiki.archlinux.org/title/msmtp

run history -ac

It also maybe should be noted to not store the MSMTP script in a file if you want to avoid having your password / the PWDEMAIL stored in a file in plain text.

If you aren't going to use OAuth, you need to set up an app password for your gmail account. You can't just use your main password. The process for doing so can be found here https://caupo.ee/blog/2020/07/05/how-to-install-msmtp-to-debian-10-for-sending-emails-with-gmail/

I had some trouble with the GPG stuff, but I forget what exactly.

There quite possibly could be more errors, because as of 5 hours ago, I didn't have any experience with any of this, and I don't know what many of the commands in the MSMTP setup script are doing.

Just delete de script file, after configuration ....
well, time pass, and maybe some configs have changed.. if you read the script.. you maybe understand the auth its done by gpg encrypted password file... the auth need run in memory. yes maybe no to much secure to locate a encrypted encrypted password walking on the RAM ...
That was my research ... 2/3 years ago.
What I see on that website, its loging with an app password generated by google. This is to encrypt the password in a file, with this resolve the situation on locate password inside a file in plain-text.
Maybe is possible do a "mix" and play with gpg, encrypto psw files, and that method pf auth by google.

I also think it would be good to mention that people can install either msmtp or Exim4. (I think this is the case, right?). With no context about any of this stuff, it took me a bit to realize this.

run : msmtp --help
you have no context... what exactly is your problem/error , or what you need? maybe this is not the solution for your needs :|

USEREMAIL mispelled as USRMAIL

MAILPROV uses smtp.google.com instead of smtp.gmail.com and I'm not sure if the port is supposed to be here either

USERLOC is unused

Purpose errors ;) force people read and understand what the code do.

@imthenachoman heya, sorry late delay, loose on time ;)
let this friend give us an output with your update and than i will take a look whats happen ^^

The table of contents link in the README.md file that goes to the MSMTP section doesn't work.

@imthenachoman maybe should you correct this, i not have exp on github editing tools/commands ^^

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants