Can't send email - "530 Client was not authenticated"

I'm using JIRA 4.1.2 and have a JNDI smtp setup very similar to what the JIRA documentation describes:

<Resource name="mail/JiraMailServer"

auth="Container"
type="javax.mail.Session"
mail.smtp.host="mail.yourcompany.com"
mail.smtp.port="25"
mail.transport.protocol="smtp"
mail.smtp.auth="true"
mail.smtp.user="jirauser"
password="mypassword"
/>
</Context>
However, email refuses to work. I always get "530 5.7.1 Client was not authenticated".
We've tried these settings both in JNDI and through the UI. Now, we have a 4.4 JIRA app that works perfectly. We used the same email settings (in the UI) but the 4.1.2 app will not connect. Is there a known issue with 4.1.2 and mail?
Here is some of my mail debug output:
DEBUG SMTP: connected to host "<hostname>", port: 25
EHLO <servername>
250-SIZE
250-X-ANONYMOUSTLS
250-AUTH NTLM
250-X-EXPS GSSAPI NTLM
Can anyone think of any reason I can't connect? I'm also using java mail 1.4.1, which wasn't supposed to play well with NTLM. But why would my other JIRA instance work??
Thanks for any input! I'll give you ALL my karma if you can help me!! :-)

2 answers

1 accepted

This widget could not be displayed.

My solution to the was to upgrade my javamail jar from 1.4.1 to 1.4.6. I was able to connect fine after that!

This widget could not be displayed.

Hi there,

I've found some other cases that indicate that this issue can be related to setting the SMTP server in JIRA not using an encrypted protocol. Aparently some SMTP servers require encrypted connection.

I know, it doesn't explain why it would work in the new version of JIRA using the same settings, but I think it'd worth a shot.

For this test, you may want to see this documentation. Alternatively, you can add some extra start up parameters to your JVM for encrypted communication during the authentication phase - mail.smtp.starttls.enable.

This parameter is set up during the start up phase. More info about that can be found in Setting properties and options on startup.

I hope this helps.

Cheers

Thanks for your response! However, since I know for sure our SMTP port is 25, doesn't that mean we can't be using an encrypted connection?? And I already tried the starttls parameter... :-(

Suggest an answer

Log in or Sign up to answer
Atlassian Summit 2018

Meet the community IRL

Atlassian Summit is an excellent opportunity for in-person support, training, and networking.

Learn more
Community showcase
Posted Wednesday in New to Jira

Are you planning to trial, or are currently trialling Jira Software? - We want to talk to you!

Hello! I'm Rayen, a product manager at Atlassian. My team and I are working hard to improve the trial experience for Jira Software Cloud. We are interested in   talking to 20 people planning t...

128 views 2 0
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you