Could not initialize class org.apache.http.conn.ssl.SSLConnectionSocketFactory

3,421 views
Skip to first unread message

Cameron Childress

unread,
May 20, 2016, 10:54:25 AM5/20/16
to lu...@googlegroups.com
I've started getting this error on any cfhttp call from Lucee: "Could not initialize class org.apache.http.conn.ssl.SSLConnectionSocketFactory"

Oddly, I am getting this error for CFHTTP calls that are not SSL based. For example, this code will throw that error.

<cfhttp url="http://www.cnn.com/" method="get" />

I replaced the JARs mentioned in the "Optional Step" here and restarted Lucee:

I'm not sure when exactly the problem started so it's hard to determine what change may have happened around that time.

Any ideas?

Lucee 4.5.2.018 (express)
MacOS

-Cameron

--
Cameron Childress
--
p:   678.637.5072
im: cameroncf

Cameron Childress

unread,
May 20, 2016, 10:57:46 AM5/20/16
to lu...@googlegroups.com
On Fri, May 20, 2016 at 10:54 AM, Cameron Childress wrote:
Lucee 4.5.2.018 (express)
MacOS

Also, Java: 1.7.0_25

-Cameron

Julian Halliwell

unread,
May 20, 2016, 11:02:34 AM5/20/16
to lu...@googlegroups.com
Java may be the issue as I'm on Java 8 and that call is working fine
with same version of Lucee.

On 20 May 2016 at 15:57, Cameron Childress <came...@gmail.com> wrote:
> Also, Java: 1.7.0_25

Cameron Childress

unread,
May 20, 2016, 11:05:35 AM5/20/16
to lu...@googlegroups.com
On Fri, May 20, 2016 at 11:01 AM, Julian Halliwell <julianh...@gmail.com> wrote:
Java may be the issue as I'm on Java 8 and that call is working fine
with same version of Lucee.

I had the same thought but:

1) Wouldn't that mean Java 1.7 is officially unsupported for Lucee 4x?
2) Another team member running 1.8 (on Mac) just tried it and he is also seeing the same error

-Cameron

Julian Halliwell

unread,
May 20, 2016, 11:09:31 AM5/20/16
to lu...@googlegroups.com
Local network issue perhaps?

Cameron Childress

unread,
May 20, 2016, 11:10:48 AM5/20/16
to lu...@googlegroups.com
On Fri, May 20, 2016 at 11:09 AM, Julian Halliwell <julianh...@gmail.com> wrote:
Local network issue perhaps?

He's in another country on another network. So no.

-Cameron
 

Mark Drew

unread,
May 20, 2016, 11:11:00 AM5/20/16
to lucee
I am running into the exact same issue on Java 1.8 and using the same codebase + version as Cameron (with whom I might or might not be working) .

we are on separate networks. So it’s a very odd issue.

MD
> --
> Love Lucee? Become a supporter and be part of the Lucee project today! - http://lucee.org/supporters/become-a-supporter.html
> ---
> You received this message because you are subscribed to the Google Groups "Lucee" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to lucee+un...@googlegroups.com.
> To post to this group, send email to lu...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/CAC_5VooPjr%2BkEq-T2wHGxPi5mos7t1JhRn%2BPukwhr27qK651YA%40mail.gmail.com.
> For more options, visit https://groups.google.com/d/optout.

Julian Halliwell

unread,
May 20, 2016, 11:14:35 AM5/20/16
to lu...@googlegroups.com
Understood.

Seems unlikely, but could it be OS specific given you're both on Mac?
I'm on Windows.

Cameron Childress

unread,
May 21, 2016, 8:40:12 AM5/21/16
to lu...@googlegroups.com
Okay - though much trial and error I have found a potential solution to this problem. I don't know if it's just going to swap one problem for another or if this represents a bug in Lucee 4.x or what.

In all of the Lucee 4.x downloads that I can find (and on my machine) both of these files exist:

/express/lib/ext/apache-commons-httpclient.jar
/express/lib/ext/apache-jakarta-commons-httpclient.jar

On a hunch that they were in conflict, I removed "apache-commons-httpclient.jar" from the folder and my problem vanished. Suddenly my CFHTTP calls started working again.

Perhaps these have always been present in the directory but something recently changed on MacOS to trigger the condition?

Is anyone else running 4.x who can confirm this or maybe someone with more knowledge about what these libraries do can help fill in the blanks with more information?

Removing that file definitely makes my test case work. I haven't spend a lot of time to look for other side effects yet.

-Cameron

--
Love Lucee? Become a supporter and be part of the Lucee project today! - http://lucee.org/supporters/become-a-supporter.html
---
You received this message because you are subscribed to the Google Groups "Lucee" group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+un...@googlegroups.com.
To post to this group, send email to lu...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

Robert Munn

unread,
May 21, 2016, 3:32:40 PM5/21/16
to lu...@googlegroups.com
Cameron,

On the latest patch of OS X El Capitan and Lucee 4.5.2.018, the cfhttp cnn.com example works fine on my machine. Note that I am not running express, I am running Lucee from a WAR install against Tomcat 7 witth Java 8 and Nginx. The files you referenced are in /WEB-INF/lib in my install.




Cameron Childress

unread,
May 22, 2016, 8:50:19 AM5/22/16
to lu...@googlegroups.com
On Sat, May 21, 2016 at 3:32 PM, Robert Munn wrote:
On the latest patch of OS X El Capitan and Lucee 4.5.2.018, the cfhttp cnn.com example works fine on my machine. Note that I am not running express, I am running Lucee from a WAR install against Tomcat 7 witth Java 8 and Nginx. The files you referenced are in /WEB-INF/lib in my install.

Thanks for testing this our Rob.

I just discovered the problem. After doing a diff between a plain Lucee Express instal and the one for this project I found a library that had been added to the lib folder that didn't belong there. After removing that, my problem went away. I suspect that library has "apache-commons-httpclient.jar" included in it.

-Cameron

Reply all
Reply to author
Forward
0 new messages