ColdFusion Scheduled Tasks and SSL

Dev

ColdFusion Scheduled Tasks and SSL

by Christopher Kaukis

There appears to be much trouble and confusion using ColdFusion and scheduled tasks over SSL. If you Google search or check out the official Adobe forums there are numbers of threads mentioning this issue, with no process to fix or resolve this issue.

The number one suggestion and most popular solution seemed to be setting up a virtual host for localhost (basically only accepting connections from 127.0.0.1). I guess that works and you can go that route, but there is an easy solution to the SSL issue also. 

In a nutshell, CFHTTP has some issues with SSL. All one has to do is add the certificates for your SSL sites that you are running your scheduled tasks against. It’s a simple 2 step process after you get the certificate.

  1. Copy the certificate file to the Java Runtime security folder ColdFusion is using (e.g.,/opt/coldfusion9/runtime/jre/lib/security).
  2. Run the key tool (in your jre bin folder) to import the certificate into the list available to ColdFusion. Here is an example, assuming you are in your jre/lib/security folder: ../../bin/keytool -import -v -alias some-name-alias-cert -file the-cert-you-copied.crt -storepass changeit -keystore cacerts

Some notes in the above keytool command:

  1. For the -storepass option, “changeit” is the default ColdFusion passphrase used.
  2. The -keystore option is referring to the file holding the list of certificates that have been imported. cacerts is a file already located in the jre/lib/security folder. If you don’t specify it will default install the certificate into your home directory, which is not accessible by ColdFusion.
The best explanation and source for this that I found is a few years old, but still holds up today: http://www.talkingtree.com/blog/index.cfm/2004/7/1/keytool

I recommend you read it in full for more details. 

More About the Author

Christopher Kaukis

Software Engineer
Running a Jekyll Blog Using Github Pages on Mac OS X 10.8 Mountain Lion In my last post I described installing Ruby on Mac OS X with RVM. The main reason I wanted to do this was to run a Jekyll Blog using ...
Installing Ruby 2.0.0 with RVM and Homebrew on Mac OS X 10.8 Mountain Lion This is a tutorial on how to install Ruby 2.0.0 on Mac OS X 10.8 Mountain Lion.  1. Install Xcode and the Command Line Tools If you ...

See more from this author →

Subscribe to our newsletter

  • I understand that InterWorks will use the data provided for the purpose of communication and the administration my request. InterWorks will never disclose or sell any personal data except where required to do so by law. Finally, I understand that future communications related topics and events may be sent from InterWorks, but I can opt-out at any time.
  • This field is for validation purposes and should be left unchanged.

InterWorks uses cookies to allow us to better understand how the site is used. By continuing to use this site, you consent to this policy. Review Policy OK

×

Interworks GmbH
Ratinger Straße 9
40213 Düsseldorf
Germany
Geschäftsführer: Mel Stephenson

Kontaktaufnahme: markus@interworks.eu
Telefon: +49 (0)211 5408 5301

Amtsgericht Düsseldorf HRB 79752
UstldNr: DE 313 353 072