What's new

Transmission email notification not working

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

Goldeneyez

New Around Here
So I've on this for a while now and just can't get it to work. Finally throwing in the towel and asking for help. Been searching about it for a while and tried a lot to no result.

Using entware transmission and did the tutorial from this page
https://github.com/RMerl/asuswrt-merlin/wiki/Installing-Transmission-through-Entware

I'm 100% sure I've set up the basic stuff correctly.
Now the problem is that I'm getting AUTH FAILED every time the script activates. I'm using Gmail SMTP:
"
SMTP="smtp.gmail.com:587"
FROM="blabla@gmail.com"
TO="blabla@gmail.com"
USER="blabla@gmail.com"
PASS="correctpassword"
"
"Access for less secure apps" in gmail settings is on. Turned it off and on again, same result.

I just have no idea what I've been doing wrong and thought of maybe someone else using Gmail to enlight me with some knowledge or something I've maybe overlooked.
 
I have not. I'm kind of a newbie when it comes to this.
Would I need to do this:
Code:
wget -c -O /jffs/configs/Equifax_Secure_Certificate_Authority.pem http://www.geotrust.com/resources/root_certificates/certificates/Equifax_Secure_Certificate_Authority.pem --no-check-certificate

and I'm not entirely sure where I would need to include the code. Should it in the end look like this?

Code:
#!/bin/sh

SMTP="your-smtp-server:587"
FROM="your-email-address"
TO="your-email-address"
USER="email-user-name"
PASS="email-password"
FROMNAME="Asus Router"
torrent_name="$TR_TORRENT_NAME"

echo "Subject: Download notification!" >/tmp/tmail.txt
echo "From: \\"$FROMNAME\\"<$FROM>" >>/tmp/tmail.txt
echo "Date: `date -R`" >>/tmp/tmail.txt
echo "" >>/tmp/tmail.txt
echo Transmissionbt has finished downloading "$TR_TORRENT_NAME" on `date +\%d/\%m/\%Y` at `date +\%T` >>/tmp/tmail.txt
echo "" >>/tmp/tmail.txt
echo "Your friendly router." >>/tmp/tmail.txt
echo "" >>/tmp/tmail.txt

cat /tmp/tmail.txt | /usr/sbin/sendmail -S"$SMTP" -f"$FROM" $TO -au"$USER" -ap"$PASS"

-CAfile /jffs/configs/Equifax_Secure_Certificate_Authority.pem \
-connect smtp.gmail.com:587 -tls1 -starttls smtp" \
-f"$FROM" \
-au"$USER" -ap"$PASS" $TO

rm /tmp/tmail.txt

Thank you for taking the time to help
 
Run the wget once

Then in your script, replace the existing ‘cat /tmp/mail....’ line with this;

cat /tmp/mail.txt | sendmail -H"exec openssl s_client -quiet \
-CAfile /jffs/configs/Equifax_Secure_Certificate_Authority.pem \
-connect smtp.gmail.com:587 -tls1 -starttls smtp" \
-f"$FROM" \
-au"$AUTH" -ap"$PASS" $TO

rm /tmp/mail.txt


Sent from my iPhone using Tapatalk
 
So like this

Code:
#!/bin/sh

SMTP="your-smtp-server:587"
FROM="your-email-address"
TO="your-email-address"
USER="email-user-name"
PASS="email-password"
FROMNAME="Asus Router"
torrent_name="$TR_TORRENT_NAME"

echo "Subject: Download notification!" >/tmp/tmail.txt
echo "From: \\"$FROMNAME\\"<$FROM>" >>/tmp/tmail.txt
echo "Date: `date -R`" >>/tmp/tmail.txt
echo "" >>/tmp/tmail.txt
echo Transmissionbt has finished downloading "$TR_TORRENT_NAME" on `date +\%d/\%m/\%Y` at `date +\%T` >>/tmp/tmail.txt
echo "" >>/tmp/tmail.txt
echo "Your friendly router." >>/tmp/tmail.txt
echo "" >>/tmp/tmail.txt

cat /tmp/mail.txt | sendmail -H"exec openssl s_client -quiet \
-CAfile /jffs/configs/Equifax_Secure_Certificate_Authority.pem \
-connect smtp.gmail.com:587 -tls1 -starttls smtp" \
-f"$FROM" \
-au"$AUTH" -ap"$PASS" $TO 

rm /tmp/mail.txt




Sent from my iPhone using Tapatalk
 
I used the script from your link and replaced a few lines and it's working fine now.
When I run it manually, it gives me this error (assuming it's the same when it runs automatically):
depth=1 C = US, O = Google Trust Services, CN = Google Internet Authority G3
verify error:num=20:unable to get local issuer certificate
250 SMTPUTF8
sendmail: helper killed by signal 15

It still sends it fine, so it isn't a problem as long as it's working. Unless it's something I should worry about.
Thank you again for your help!
 
Yea just some certificate error you could spend your life trying to understand (I hate cert issues!). I wouldn’t worry if it works!
Glad to have been of service [emoji3]


Sent from my iPhone using Tapatalk
 

Similar threads

Latest threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top