<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<body link="#355491" alink="#4262a1" vlink="#355491" style="background: #e2e2e2; margin: 0; padding: 20px;">

<div>
        <table cellpadding="0" bgcolor="#FFFFFF" border="0" cellspacing="0" style="border: 1px solid #dadada; margin-bottom: 30px; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                <tbody>
                        <tr>

                                <td>

                                        <table border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" style="border: solid 2px #ccc; background: #dadada; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                                                <tbody>
                                                        <tr>
                                                                <td bgcolor="#000000" valign="middle" height="58px" style="border-bottom: 1px solid #ccc; padding: 20px; -moz-border-radius-topleft: 3px; -moz-border-radius-topright: 3px; -webkit-border-top-right-radius: 5px; -webkit-border-top-left-radius: 5px;">
                                                                        <h1 style="color: #333333; font: bold 22px Arial, Helvetica, sans-serif; margin: 0; display: block !important;">
                                                                        <!-- To have a header image/logo replace the name below with your img tag -->
                                                                        <!-- Email clients will render the images when the message is read so any image -->
                                                                        <!-- must be made available on a public server, so that all recipients can load the image. -->
                                                                        <a href="http://community.jboss.org/index.jspa" style="text-decoration: none; color: #E1E1E1">JBoss Community</a></h1>
                                                                </td>

                                                        </tr>
                                                        <tr>
                                                                <td bgcolor="#FFFFFF" style="font: normal 12px Arial, Helvetica, sans-serif; color:#333333; padding: 20px;  -moz-border-radius-bottomleft: 4px; -moz-border-radius-bottomright: 4px; -webkit-border-bottom-right-radius: 5px; -webkit-border-bottom-left-radius: 5px;"><h3 style="margin: 10px 0 5px; font-size: 17px; font-weight: normal;">
    jbpm4.4 failed to send email
</h3>
<span style="margin-bottom: 10px;">
    created by <a href="http://community.jboss.org/people/wiwengweng">wiwengweng wen</a> in <i>jBPM</i> - <a href="http://community.jboss.org/message/634225#634225">View the full discussion</a>
</span>
<hr style="margin: 20px 0; border: none; background-color: #dadada; height: 1px;">

<div class="jive-rendered-content"><p>when I config the jbpm4.4 to send email. I wonder if there is a tuitor that can help me out first, then I don't have to bother all you guys. I config the jbpm.mail.cfg.xml file and the default.cfg.xml as follows:</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>*******************************************************</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>mail.cfg.xml</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>mail.smtp.host=smtp.163.com</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>mail.smtp.port=25</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><a class="jive-link-email-small" href="mailto:mail.from=ylyy-1985@163.com" target="_blank">mail.from=ylyy-1985@163.com</a></p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>mail.smtp.auth=true</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>********************************************************</p><p>default.cfg.xml:::</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&lt;?xml version="1.0" encoding="UTF-8"?&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&lt;jbpm-configuration&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160; &lt;import resource="jbpm.default.scriptmanager.xml" /&gt;</p><p>&#160; &lt;import resource="jbpm.mail.templates.xml" /&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160; &lt;process-engine-context&gt;</p><p>&#160; </p><p>&#160;&#160;&#160; &lt;repository-service /&gt;</p><p>&#160;&#160;&#160; &lt;repository-cache /&gt;</p><p>&#160;&#160;&#160; &lt;execution-service /&gt;</p><p>&#160;&#160;&#160; &lt;history-service /&gt;</p><p>&#160;&#160;&#160; &lt;management-service /&gt;</p><p>&#160;&#160;&#160; &lt;identity-service /&gt;</p><p>&#160;&#160;&#160; &lt;task-service /&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160; &lt;object class="org.jbpm.pvm.internal.id.DatabaseDbidGenerator"&gt;</p><p>&#160;&#160;&#160;&#160;&#160; &lt;field name="commandService"&gt;&lt;ref object="newTxRequiredCommandService" /&gt;&lt;/field&gt;</p><p>&#160;&#160;&#160; &lt;/object&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160; &lt;object class="org.jbpm.pvm.internal.id.DatabaseIdComposer" init="eager" /&gt;</p><p>&#160;&#160;&#160; </p><p>&#160;&#160;&#160; &lt;object class="org.jbpm.pvm.internal.el.JbpmElFactoryImpl" /&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160; &lt;types resource="jbpm.variable.types.xml" /&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160; &lt;address-resolver /&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160; &lt;/process-engine-context&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160; &lt;transaction-context&gt;</p><p>&#160;&#160;&#160; &lt;repository-session /&gt;</p><p>&#160;&#160;&#160; &lt;db-session /&gt;</p><p>&#160;&#160;&#160; </p><p>&#160;&#160;&#160; &lt;message-session /&gt;</p><p>&#160;&#160;&#160; &lt;timer-session /&gt;</p><p>&#160;&#160;&#160; </p><p>&#160;&#160;&#160; &lt;history-sessions&gt;</p><p>&#160;&#160;&#160;&#160;&#160; &lt;object class="org.jbpm.pvm.internal.history.HistorySessionImpl" /&gt;</p><p>&#160;&#160;&#160; &lt;/history-sessions&gt;</p><p>&#160;&#160;&#160; </p><p>&lt;mail-session&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160;&#160;&#160;&#160; &lt;mail-server&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;session-properties resource= "jbpm.mail.properties"&#160; /&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;authenticator class= "org.jbpm.test.wyl.MyAuthen" &gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;field name= "userName" &gt;&lt;string value= "ylyy" /&gt;&lt;/field&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;field name= "passWord" &gt;&lt;string value= (my password of the mailbox )/&gt;&lt;/field&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;/authenticator&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160;&#160;&#160;&#160; &lt;/mail-server&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160;&#160; &lt;/mail-session&gt; </p><p>&#160; &lt;/transaction-context&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&lt;/jbpm-configuration&gt;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>******************************************************</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>then I meet this problem.in fact, I don't know what is the authentication, and how to do that . but just follow a example to do this.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>### EXCEPTION ###########################################</p><p>18:13:50,093 INF | [DefaultCommandService] exception while executing command org.jbpm.pvm.internal.cmd.StartProcessInstanceInLatestCmd@6cef4</p><p>org.jbpm.api.JbpmException: could not send email: javax.mail.internet.MimeMessage@11b86c7</p><p>&#160;&#160;&#160; at org.jbpm.pvm.internal.email.impl.MailSessionImpl.send(MailSessionImpl.java:60)</p><p>&#160;&#160;&#160; at org.jbpm.test.wyl.TestMail2.main(TestMail2.java:32)</p><p>Caused by: com.sun.mail.smtp.SMTPSendFailedException: 553 You are not authorized to send mail, authentication is required</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160; at com.sun.mail.smtp.SMTPTransport.issueSendCommand(SMTPTransport.java:1515)</p><p>&#160;&#160;&#160; at com.sun.mail.smtp.SMTPTransport.mailFrom(SMTPTransport.java:1054)</p><p>&#160;&#160;&#160; at com.sun.mail.smtp.SMTPTransport.sendMessage(SMTPTransport.java:634)</p><p>&#160;&#160;&#160; at org.jbpm.pvm.internal.email.impl.MailSessionImpl.send(MailSessionImpl.java:51)</p><p>&#160;&#160;&#160; ... 16 more</p><p>### EXCEPTION ###########################################</p><p>18:13:50,093 FIN | [HibernateSessionResource] ----- rolling back hibernate tx 16586768 -----------------------------------------------------</p><p>Exception in thread "main" org.jbpm.api.JbpmException: could not send email: javax.mail.internet.MimeMessage@11b86c7</p><p>&#160;&#160;&#160; at org.jbpm.pvm.internal.email.impl.MailSessionImpl.send(MailSessionImpl.java:60)</p><p>&#160;&#160; </p><p>Caused by: com.sun.mail.smtp.SMTPSendFailedException: 553 You are not authorized to send mail, authentication is required</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160; at com.sun.mail.smtp.SMTPTransport.issueSendCommand(SMTPTransport.java:1515)</p><p>&#160;&#160;&#160; at com.sun.mail.smtp.SMTPTransport.mailFrom(SMTPTransport.java:1054)</p><p>&#160;&#160;&#160; at com.sun.mail.smtp.SMTPTransport.sendMessage(SMTPTransport.java:634)</p><p>&#160;&#160;&#160; at org.jbpm.pvm.internal.email.impl.MailSessionImpl.send(MailSessionImpl.java:51)</p><p>&#160;&#160;&#160; ... 16 more</p></div>

<div style="background-color: #f4f4f4; padding: 10px; margin-top: 20px;">
    <p style="margin: 0;">Reply to this message by <a href="http://community.jboss.org/message/634225#634225">going to Community</a></p>
        <p style="margin: 0;">Start a new discussion in jBPM at <a href="http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034">Community</a></p>
</div></td>
                        </tr>
                    </tbody>
                </table>


                </td>
            </tr>
        </tbody>
    </table>

</div>

</body>
</html>