You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Johan Borchers <jo...@solcon.nl> on 2008/01/02 13:08:33 UTC
Re: (successful) Configuring gmail sending mail from Tomcat
I managed to send emails from a webapp in Tomcat using gmail.
The configuration is:
<Resource name="mail/MyMailServerName"
auth="Container"
type="javax.mail.Session"
mail.transport.protocol="smtp"
mail.smtp.host="smtp.gmail.com"
mail.smtp.port="465"
mail.smtp.auth="true"
mail.smtp.user="myusername@gmail.com"
password="mypassword"
mail.smtp.starttls.enable="true"
mail.smtp.socketFactory.class="javax.net.ssl.SSLSocketFactory"
/>
I didn't do anything with a keystore!
Johan
Deeþan Chakravarthy wrote:
> Johan Borchers wrote:
>> Hello,
>>
>> I'm using Tomcat 6.0.14 on windows 2003 server with JDK 1.5.0_12.
>> I'm using now my 'normal' email account for sending email.
>>
>> <Resource name="mail/MyMailServerName"
>> auth="Container"
>> type="javax.mail.Session"
>> mail.store.protocol="pop3"
>> mail.pop3.host="pop.myprovider.xxx"
>> mail.transport.protocol="smtp"
>> mail.smtp.host="mail.myprovider.xxx"
>> mail.smtp.port="25"
>> mail.smtp.auth="true"
>> mail.smtp.user="myusername"
>> password="mypassword"
>> />
>>
>> I want to use a gmail account for sending email from Tomcat.
>>
>> Has anyone succesfully configured a gmail account for sending email
>> from Tomcat.
>> I can't find the exact parameters to use.
>>
>> My first try was this:
>>
>> <Resource name="mail/MyMailServerName"
>> auth="Container"
>> type="javax.mail.Session"
>> mail.store.protocol="pop3"
>> mail.pop3.host="pop.gmail.com"
>> mail.transport.protocol="smtps"
>> mail.smtp.starttls.enable="true"
>> mail.smtps.host="smtp.gmail.com"
>> mail.smtps.port="465"
>> mail.smtps.auth="true"
>> mail.smtps.user="myusername@gmail.com"
>> password="mypassword"
>> />
>>
>> I'm not sure if this is allright?
>> And I think I'll have to configure some keystore for a certificate.
>>
>
> Looks fine.. Did you try it out ? Does it work ?
>
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org