bashssmtp

ssmtp cuts the email i'm sending


so here's the whole text i'm sending:

enter image description here

and here's the email i'm receiving:

enter image description here

basically i just cat the file and echo then pipe it to ssmtp like this:

result=`cat file.out` 
echo "$result" | ssmtp $emailaddr

Solution

  • ssmtp protocol defines the lines in format something: something to be the header lines, like From: some@email.com defines where from the email is. So if you want to specify the body only, add a leading empty line as the separator between the header and body of the message and hopefully ssmtp should pick it up.