paulie wrote:
> 
> I tried a few attempts with the same result.  Here is the summary:
> 
> Modified src\main\respirces\mail.properties:
> 
> [EMAIL PROTECTED]
> mail.debug=false
> mail.transport.protocol=smtp
> mail.host=smtp.sbcglobal.yahoo.com
> [EMAIL PROTECTED]
> mail.password=mypassword
> mail.port=25
> 
> Added src\site\webapp\WEB-INF\ApplicationContext.xml
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <beans xmlns="http://www.springframework.org/schema/beans";
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
>        xsi:schemaLocation="http://www.springframework.org/schema/beans
> http://www.springframework.org/schema/beans/spring-beans-2.0.xsd";>
> 
>     <bean id="mailSender"
> class="org.springframework.mail.javamail.JavaMailSenderImpl"> 
>         <property name="host" value="${mail.host}"/> 
>         <!-- Uncomment if you need to authenticate with your SMTP Server
> --> 
>         <property name="username" value="${mail.username}"/> 
>         <property name="password" value="${mail.password}"/> 
>         <property name="javaMailProperties"> 
>             <value> 
>                 mail.smtp.auth=true 
>             </value> 
>         </property> 
>     </bean>
> </beans>
> 
> I wanted to be sure that I had included the changes that you recommended
> and see if you had any additional ideas on diagnosing the problem.
> 
> 
>> Matt Raible-3 wrote:
>>The problem is likely that applicationContext-resources.xml is the
>>first Spring context file loaded, so applicationContext-service.xml
>>(from the JAR) is overwriting your class.  Try adding your bean>
>>definition to a src/main/webapp/WEB-INF/applicationContext.xml file.
>>
>>Matt
> 
> On 2/8/07, paulie <[EMAIL PROTECTED]> wrote:
>>
>> I am using AppFuse 2.  Added the mailSender bean id to the
>> applicationContext-resources.xml and uncommented the authentication
>> piece.
>>
>> Ran a mvn clean, then reran the mvn integration-test and got the same
>> 'authentication required' message.
>>
>> Any ideas?
>>
>>
>> Matt Raible-3 wrote:
>> >
>> > If you're using AppFuse 2, you'll likely need to override the
>> > mailEngine bean in your local applicationContext.xml.  Here's the
>> > default one:
>> >
>> >     <bean id="mailSender"
>> > class="org.springframework.mail.javamail.JavaMailSenderImpl">
>> >         <property name="host" value="${mail.host}"/>
>> >         <!-- Uncomment if you need to authenticate with your SMTP
>> Server
>> > -->
>> >         <!--property name="username" value="${mail.username}"/>
>> >         <property name="password" value="${mail.password}"/>
>> >         <property name="javaMailProperties">
>> >             <value>
>> >                 mail.smtp.auth=true
>> >             </value>
>> >         </property-->
>> >     </bean>
>> >
>> > If you comment out the bottom part in your local bean definition, it
>> > should work.
>> >
>> > Matt
>> >
>> >
>> >
>> > On 2/7/07, paulie <[EMAIL PROTECTED]> wrote:
>> >>
>> >> I have been able to send an email with a simple Java app using
>> javax.mail
>> >> by
>> >> setting SMTP authentication:
>> >>
>> >> Properties props = System.getProperties();
>> >> props.put("mail.smtp.auth", "true");
>> >>
>> >> I have been trying to do the same thing through mail.properties:
>> >>
>> >> mail.smtp.auth=true
>> >> or
>> >> mail.auth = true
>> >>
>> >> I keep getting a 'SMTPSendFailedException: 530 Authentication
>> Required'
>> >> when
>> >> running mvn integration-test.  I was able to recreate this scenario in
>> my
>> >> Java app iwthout setting the SMTP authentication.
>> >>
>> >> Is there another way that I can set SMTP authentication for a Struts 2
>> >> App?
>> >> --
>> >> View this message in context:
>> >>
>> http://www.nabble.com/SMTP-Authentication-with-Struts-2-App-tf3191569s2369.html#a8860036
>> >> Sent from the AppFuse - User mailing list archive at Nabble.com.
>> >>
>> >> ---------------------------------------------------------------------
>> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> >> For additional commands, e-mail: [EMAIL PROTECTED]
>> >>
>> >>
>> >
>> >
>> > --
>> > http://raibledesigns.com
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: [EMAIL PROTECTED]
>> > For additional commands, e-mail: [EMAIL PROTECTED]
>> >
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/SMTP-Authentication-with-Struts-2-App-tf3191569s2369.html#a8865613
>> Sent from the AppFuse - User mailing list archive at Nabble.com.
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
> 
> 
> -- 
> http://raibledesigns.com
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 



-- 
View this message in context: 
http://www.nabble.com/SMTP-Authentication-with-Struts-2-App-tf3191569s2369.html#a8904692
Sent from the AppFuse - User mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to