Dear Jacques, Michael, Arun, Suraj,
I spent some time and tried to understand where went wrong. Here below is what
is in my mind:
1. All the main pre-defined parameters related to this topic like
“mail.smtp.relay.host” is stored in the file “general.properties”;
2. Once the release is installed, those parameters are read into the
database (in my case is MySQL) table “ofbiz.system_property”;
3. For my case, I have changed both the parameters in the file
“general.properties” and the database table “ofbiz.system_property”, along with
all other parameters like email address in my previous posted email;
4. However, what the error messages “Unable to email password” (after
googling it) might mean something wrong with the SSL. For my case, the SSL
certificate “framework/base/config/ofbizssl.jks” provided in the release
16.11.03 (my case) is not working here;
So the options left for me is either to install the proper SSL certificate or
change the settings (and hopefully it would work);
4.1 for option 1: I have successfully applied one SSL certificate from Symantec
(with suffix ****.jks) from my website service provider and the certificate is
valid for 1 year. I copied it to the folder “framework/base/config” and then in
the file “framework/catalina/ofbiz-component.xml” and then I modified the
following fields of the property “https-connector”:
From (originally)
<property name="keystoreFile" value="framework/base/config/ofbizssl.jks"/>
<property name="keystoreType" value="JKS"/>
<property name="keyAlias" value="ofbiz"/>
<property name="keyPass" value="changeit"/>
<property name="sslProtocol" value="TLS"/>
To
<property name="keystoreFile" value="framework/base/config/****.jks"/>
<property name="keystoreType" value="JKS"/>
<property name="keyAlias" value="ofbiz"/>(I leave it as ofbiz because I don’t
know what to fill in here)
<property name="keyPass" value="changeit"/> (I tried many options but all
failed by leaving it unchanged or changed it to the password that I set as 1234
when downloading the JKS file)
<property name="sslProtocol" value="TLS"/>
Unfortunately after changing it, I could even not get in the login webpage and
something is wrong with the certificate validation, I guess.
So my another question is: is there any guide book showing us how to install
the SSL.
BTW, I tried the link below and I simply could not get it done.
https://cwiki.apache.org/confluence/display/OFBIZ/Apache+OFBiz+Technical+Production+Setup+Guide
4.2 So I had to change the following setting both mentioned in Item Nr.1 and
Nr2.
From (originally)
#--Fallback [true|false] determines whether you will allow a non secure
connection if you are unable to get a secure one
mail.smtp.socketFactory.fallback=true
To
#--Fallback [true|false] determines whether you will allow a non secure
connection if you are unable to get a secure one
mail.smtp.socketFactory.fallback=false
After rebooting, strange thing happened. It prompted me with something like
“could not send email from
[email protected]<mailto:[email protected]> to
[email protected]<mailto:[email protected]>.
Obviously this is not the case because I had set the recipient’s email address
differently.
5. When I almost gave up, I changed last time with the following:
From (originally)
mail.smtp.auth.user=myfakeemailaddress
mail.smtp.socketFactory.fallback=false
To
[email protected]
mail.smtp.socketFactory.fallback=true
This is where and when magic happened. I finally received the GD message.
And I swear to GOD that I used the last working combination before and it
didn’t work.
Now to me it still is a mystery why and how it worked.
I write this out and hope it would help someone out there struggling like me
and would highly appreciate if anyone would guide me clearly (step-by-step) how
to make my SSL work for my website.
Have a nice day to all your guys!
Schumann
+86-1800-150-1800
发件人: Arun Patidar<mailto:[email protected]>
发送时间: 2018年3月16日 16:42
收件人: [email protected]<mailto:[email protected]>
抄送: [email protected]<mailto:[email protected]>
主题: Re: About OFBiz Email Passwords Sending
Hello Jacques,
There are still some occurrences in the code for systemPropertyValue="".
This empty field should be removed to prevent data overridden. Added an
example data in the ticket OFBIZ-10282
--
Thanks & Regards
---
Arun Patidar
Manager, Enterprise Software Development
www.hotwaxsystems.comwww.hotwax.co<http://www.hotwaxsystems.comwww.hotwax.co>
On Fri, Mar 16, 2018 at 12:49 AM, Jacques Le Roux <
[email protected]> wrote:
> Sorry missed to say that it's on the dev ML
>
> Jacques
>
>
>
> Le 15/03/2018 à 18:28, Jacques Le Roux a écrit :
>
>> Hi Suraj,
>>
>> Before diving in this action, could you please check the thread
>> "Deprecate properties in favour of SystemProperties"
>>
>> Notably https://markmail.org/message/opldepaevls3y3ob
>>
>> Thanks
>>
>> Jacques
>>
>>
>> Le 15/03/2018 à 12:53, Suraj Khurana a écrit :
>>
>>> Hi Michael, Schumann,
>>>
>>> As per some recent code changes, there are many empty fields in data
>>> files
>>> which removes the data when some reader is again loaded into the system.
>>> Lets say I configured some email settings and mistakenly if ext reader is
>>> loaded again, that data will be corrupted and user is unaware of that.
>>>
>>> This ticket is created for changes regarding the same:
>>> https://issues.apache.org/jira/browse/OFBIZ-10282
>>>
>>> HTH.
>>>
>>> --
>>> Thanks and Regards,
>>> *Suraj Khurana* | Sr. Enterprise Software Engineer
>>> HotWax Commerce by HotWax Systems
>>> Plot no. 80, Scheme no. 78, Vijay Nagar, Indore, M.P. India 452010
>>>
>>>
>>>
>>>
>>>
>>> On Thu, Mar 15, 2018 at 4:14 PM, Michael Brohl <[email protected]
>>> >
>>> wrote:
>>>
>>> Hi Schumann,
>>>>
>>>> please have a look at the SystemProperty table. Currently the demo data
>>>> loads some configuration for email so the changes in general.properties
>>>> are
>>>> partly overwritten in the configuration logic. Either change the
>>>> database
>>>> entries or remove them to use general.properties settings.
>>>>
>>>> Best regards,
>>>>
>>>> Michael Brohl
>>>> ecomify GmbH
>>>> www.ecomify.de<http://www.ecomify.de>
>>>>
>>>>
>>>> Am 15.03.18 um 10:20 schrieb Schumann Ye:
>>>>
>>>> Dear Gurus,
>>>>
>>>>> When I try to activate OFBiz Passwords Forget (Email Passwords
>>>>> function)
>>>>> in the Login webpage, I have got the following Error message:
>>>>>
>>>>> The Following Errors Occurred:
>>>>> Error occurred: unable to email password. Please try again later or
>>>>> contact customer service. (error was: [CON] Connection error when
>>>>> sending
>>>>> message to ***************@hotmail.com from ****************@
>>>>> outlook.com
>>>>> cc bcc subject New Password Sent (my own user login id)).
>>>>>
>>>>> What I have done in customizing the OFBiz Email Passwords is as
>>>>> follows:
>>>>>
>>>>> 1. Update the fields (which are not null) From_Address, CC_Address
>>>>> and BCC_Address from tables ofbiz.product_store_email_setting and
>>>>> ofbiz.email_template_setting to sending email address
>>>>> ******************@
>>>>> outlook.com
>>>>>
>>>>> 2. Modify the file general.properties as follows:
>>>>> # -- general default 'fromEmailAddress' can be overridden in:
>>>>> EmailTemplateSetting
>>>>> defaultFromEmailAddress=******************@outlook.com
>>>>>
>>>>> # -- mail notifications enabled (Y|N)
>>>>> mail.notifications.enabled=Y
>>>>>
>>>>> # -- redirect all mail notifications to this address for testing
>>>>> #mail.notifications.redirectTo=
>>>>>
>>>>> # -- the default mail server to use
>>>>> mail.smtp.relay.host=smtp.office365.com
>>>>>
>>>>> # -- SMTP Auth settings
>>>>> mail.smtp.auth.user=******************(my outlook mail name with
>>>>> the @outlook.com)
>>>>> mail.smtp.auth.password=*******************(my outlook mailbox
>>>>> passwords)
>>>>>
>>>>> # -- Additional Required Fields needed for Gmail and other non
>>>>> traditional smtp servers
>>>>> # -- These added fields also work for Yahoo business mail for
>>>>> instance
>>>>> # -- Gmail smtp port can be either 465 or 587
>>>>> mail.smtp.port=587
>>>>> # -- Gmail requires StartTLS
>>>>> mail.smtp.starttls.enable=true
>>>>>
>>>>> # -- Gmail requires a JSSE socket factory, the following
>>>>> socketFactory settings will override JavaMail's default socketFactory
>>>>> settings
>>>>> # -- Port needs to be the same as mail.smtp.port
>>>>> mail.smtp.socketFactory.port=587
>>>>> #mail.smtp.socketFactory.class=javax.net.ssl.SSLSocketFactory
>>>>> #--Fallback [true|false] determines whether you will allow a non
>>>>> secure connection if you are unable to get a secure one
>>>>> #mail.smtp.socketFactory.fallback=false
>>>>>
>>>>> 3. Update the predefined fields from table ofbiz.system_property
>>>>> in
>>>>> mysql database as above shown in point 2.
>>>>> 4. I also update the from_address from the preset mailbox to my
>>>>> outlook mailbox in the moduel Ecommerce (applications/securityext/data
>>>>> /UserDemoData.xml),
>>>>> although this is not necessary for now because I am using back-end
>>>>> only.
>>>>>
>>>>> After a successful reboot of OFBiz, I got the error message shown in
>>>>> the
>>>>> very beginning.
>>>>>
>>>>> Can anybody help?
>>>>> Thanks and have a nice day!
>>>>>
>>>>> Best Regards
>>>>> Schumann
>>>>> +86-1800-150-1800
>>>>>
>>>>>
>>>>>
>>>>
>>
>>
>