Are you sure that the mail server, serving the host you are deploying to does 
not require authentication?  I got this same error trying to go through the 
Google Mail Server without proper authentication.

when I invoke the component in the webapp I get
javax.mail.AuthenticationFailedException
debug output shows that my components configuration parameters are
IDENTICAL to those used in standalone mode.

You say in Eclipse you use -  (mail.smtp.auth = false) and sends the email.  
Try sending authentication.

    private class SMTPAuthenticator extends javax.mail.Authenticator {
        @ Override
        public PasswordAuthentication getPasswordAuthentication() {
            return new PasswordAuthentication(d_email, d_password);
        }
    }

Don


At 06:41 AM 11/25/2008, you wrote:
>Start by making sure there is only one copy of the javamail jar.   
>Remove either the one in tomcat's lib directory or your webapp's lib  
>directory.
>
>-- David
>
>
>On Nov 19, 2008, at 6:04 AM, Lyallex <[EMAIL PROTECTED]> wrote:
>
>>Hi
>>
>>Tomcat 6.0.16
>>jdk1.6.0_06
>>javamail 1.4.1
>>
>>I have a simple component that uses javamail 1.4.1 to send e-mail
>>It works perfectly 'standalone' (executed from Eclipse).
>>It connects to the server (mail.smtp.auth = false)
>>and sends the email
>>
>>I've read the available docs at
>>http://tomcat.apache.org/tomcat-6.0-doc/jndi-resources-howto.html
>>which talk about activation.jar among others
>>As I am using jdk 1.6 I understand that this is no longer required (it
>>is included in the distro).
>>
>>The javamail 1.4.1 jars are in CATALINA_HOME/lib
>>I have also tried them in WEB-INF/classes/lib
>>
>>when I invoke the component in the webapp I get
>>javax.mail.AuthenticationFailedException
>>debug output shows that my components configuration parameters are
>>IDENTICAL to those used in standalone mode.
>>
>>I am not using jndi resources or resources defined in context.xml, I
>>am not using tomcats JavaMail session management.
>>
>>I just need this to work as a simple component without lots of config
>>to start with.
>>
>>Can anyone let me in on the 'secret' to getting this to work. I've had
>>similar components working in earlier releases (and they are still
>>working)
>>Something must have changed, I'm rather hoping it's not a securuity
>>thing but I suspect it might be.
>>
>>I'm not asking anyone to debug my application I could just do with a
>>pointer or two.
>>
>>Any help much appreciated
>>
>>Cheers
>>lyallex
>>
>>---------------------------------------------------------------------
>>To start a new topic, e-mail: users@tomcat.apache.org
>>To unsubscribe, e-mail: [EMAIL PROTECTED]
>>For additional commands, e-mail: [EMAIL PROTECTED]
>
>---------------------------------------------------------------------
>To start a new topic, e-mail: users@tomcat.apache.org
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to