Solved

Unable to post to Secure URL using CFHTTP (Urgent)

Posted on 2006-10-19
5
650 Views
Last Modified: 2013-12-20

 I have the following cfhttp call that PUTs an XML file to a secure URL.  

 It  works fine on an unsecure URL, but when we switch to test with a secure URL, it fails.

 This works...
<cfset variables.URL = "http://www.mydomain.com/services">

<cfhttp method = "PUT" url = "#variables.URL#" throwOnError = "No">
     <cfhttpparam type="xml" value="#variables.xmlContent#">
</cfhttp>

 Using this URL instead it fails  (note the https)
<cfset variables.URL = "https://www.mydomain.com/services">

 We are getting a "connection failure" error.

 The secure URL has been tested using another mechansim (other than coldfusion) and it is working.

 Thanks for your help!!

0
Comment
Question by:gdemaria
  • 3
  • 2
5 Comments
 
LVL 36

Accepted Solution

by:
SidFishes earned 500 total points
ID: 17766057
this help?

To use HTTPS with the cfhttp tag, you might need to manually import the certificate for each web server into the keystore for the JRE that ColdFusion uses. This procedure should not be necessary if the certificate is signed (issued) by an authority that the JSSE (Java Secure Sockets Extension) recognizes (for example, Verisign); that is, if the signing authority is in the cacerts already. However, you might need to use the procedure if you are issuing SSL (secure sockets layer) certificates yourself.
To manually import a certificate:

   1. Go to a page on the SSL server in question.
   2. Double-click the lock icon.
   3. Click the Details tab.
   4. Click Copy To File.
   5. Select the base64 option and save the file.
   6. Copy the CER file into C:\CFusionMX7\runtime\jre\lib\security (or whichever JRE ColdFusion is using).
   7. Run the following command in the same directory (keytool.exe is located in C:\CFusionMX7\runtime\jre\bin):

      keytool -import -keystore cacerts -alias giveUniqueName -file filename.cer

http://livedocs.macromedia.com/coldfusion/7/htmldocs/wwhelp/wwhimpl/common/html/wwhelp.htm?context=ColdFusion_Documentation&file=00000272.htm
0
 
LVL 39

Author Comment

by:gdemaria
ID: 17766499

 Thanks SidFishes, I am persuing that avenue but a couple stumbling blocks.

 - the certificate is signed but not by Verisign, so its unclear if its recognized or not by JSEE.  Presumably it would be.
 - we are using Linux, which the directions don't cover but..
 - we installed on Windows (following your directions above) and tested and it didn't work there

  thanks again - any more ideas greatly appreciated !
0
 
LVL 36

Expert Comment

by:SidFishes
ID: 17766558
What version of JRE are you using?

 cfhttp needs 1.4 to work

http://www.houseoffusion.com/groups/CF-Talk/thread.cfm/threadid:25206
0
 
LVL 39

Author Comment

by:gdemaria
ID: 17767998

 Thanks Sid, I will check that out!   The urgency has subsided with a work-around.. phew..
0
 
LVL 39

Author Comment

by:gdemaria
ID: 17938441

 Thanks very much!

  Sorry I didn't return sooner to close the question
0

Featured Post

Free camera licenses with purchase of My Cloud NAS

Milestone Arcus software is compatible with thousands of industry-leading cameras for added flexibility. Upon installation on your My Cloud NAS, you will receive two (2) camera licenses already enabled in the software. And for a limited time, get additional camera licenses FREE.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Forbidden errors 5 124
Unsearchable in Google,Yahoo and Bing. 6 58
How to find the first line of javascript code-behind of a web page button. 7 55
Gulp not seeing Changes 4 38
A web service (http://en.wikipedia.org/wiki/Web_service) is a software related technology that facilitates machine-to-machine interaction over a network. This article helps beginners in creating and consuming a web service using the ColdFusion Ma…
When setting up new project requests for our site, one of the most powerful tools our team has available to use is Axure (http://www.axure.com/). It’s a tool for creating software and web prototypes that can function and interact as if it were the a…
The purpose of this video is to demonstrate how to properly insert a Vimeo Video into a WordPress site or Blog. This will be demonstrated using a Windows 8 PC. Go to your WordPress login page. This will look like the following: mywebsite.com/wp…
The purpose of this video is to demonstrate how to set up the permalinks on a WordPress Website. This will be demonstrated using a Windows 8 PC. Go to your WordPress login page. This will look like the following: mywebsite.com/wp-login.php : Go t…

861 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now