Solved

CFHTTP I/O Exception: peer not authenticated

Posted on 2012-04-06
7
1,894 Views
Last Modified: 2012-08-13
I am doing a standard cfhttp post and get this when I try and post.
      <cfhttp
        url="https://services.someurl.com/Data/page.aspx"
                method="post"  result="queryX" >
             <cfhttpparam type="formfield"  name="affiliate_id" value="123">
             <cfhttpparam type="formfield"  name="password" value="456">
             <cfhttpparam type="formfield"  name="service" value="Lookup">
        </cfhttp>
            
      <cfdump var=#queryX#>

Result:
struct
Charset       [empty string]
ErrorDetail       I/O Exception: peer not authenticated
Filecontent       Connection Failure
Header       [empty string]
Mimetype       Unable to determine MIME type of file.
Responseheader       
struct [empty]
Statuscode       Connection Failure. Status code unavailable.
Text       YES

Any help appreciated.
0
Comment
Question by:LeadCo
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
7 Comments
 
LVL 3

Expert Comment

by:tobyweston
ID: 37817228
How do you authenticate with the service? Via the details posted or do they provide a certificate?

Are you hard coding the cfhttpparam values? Do they have any non alpha characters in them?
0
 

Author Comment

by:LeadCo
ID: 37817296
When I use this :  and place in a web browser i can see info i need:
https://services.someurl.com/Data/page.aspx?affiliate_id=123&password=456&service=LOOKUP

I get the page and the xml data I am looking for.
I am attempting to use cfhttp to grab the filecontent and return as xml

the page returns:

<TheData>
<Year>1981</Year>
<Year>1982</Year>
<Year>1983</Year>
<Year>1984</Year>
</TheData>
0
 
LVL 3

Accepted Solution

by:
tobyweston earned 500 total points
ID: 37817316
You can use the keytool to try importing the URLs certificate:

http://helpx.adobe.com/coldfusion/kb/import-certificates-certificate-stores-coldfusion.html

Using URLDecode or URLEncodeFormat around the the values to make sure they are being sent exactly how you need them to be. Usually a problem if there are non alpha chars in the values.
0
How Do You Stack Up Against Your Peers?

With today’s modern enterprise so dependent on digital infrastructures, the impact of major incidents has increased dramatically. Grab the report now to gain insight into how your organization ranks against your peers and learn best-in-class strategies to resolve incidents.

 

Author Comment

by:LeadCo
ID: 37817367
When you click on the lock to view a certicicate where do you find the path to it or how to download it?
0
 

Assisted Solution

by:LeadCo
LeadCo earned 0 total points
ID: 37817483
Ok here is process :

Add to keystore coldfusion:

Navigate to url click on lock click details tab
click copy or download.

save to C:\ColdFusion9\runtime\jre\lib\security

open cmd prompt: put in :
cd C:\ColdFusion9\runtime\jre\bin

This puts you in that directory then run:

C:\JRun4\jre\bin>
keytool -importcert -v -alias wa-cert -file C:\ColdFusion9\runtime\jre\lib
\security\CERTFILENAME.cer -keystore C:\JRun4\jre\lib\security\cacerts -storepass
changeit
0
 
LVL 3

Expert Comment

by:tobyweston
ID: 37817821
Did following the process resolve the issue?
0
 

Author Closing Comment

by:LeadCo
ID: 37836656
Had to make one change: Because of where root directory is on my cf box. <br /><br />Check your location of the  C:\ColdFusion9\runtime\jre<wbr />\lib directory to make it work for your server.<br /><br /><br />Ok here is process :<br /><br />Add to keystore coldfusion:<br /><br />Navigate to url click on lock click details tab<br />click copy or download.<br /><br />save to C:\ColdFusion9\runtime\jre<wbr />\lib\secur<wbr />ity<br /><br />open cmd prompt: put in :<br />cd C:\ColdFusion9\runtime\jre<wbr />\bin<br /><br />This puts you in that directory then run:<br /><br />C:\JRun4\jre\bin><br />keytool -importcert -v -alias wa-cert -file C:\ColdFusion9\runtime\jre<wbr />\lib<br />\security\CERTFILENAME.cer<wbr /> -keystore  C:\ColdFusion9\runtime\jre<wbr />\lib\secur<wbr />ity\cacert<wbr />s -storepass<br />changeit
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

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

Today, I was working on some optimization and spam-stopping techniques when I encountered Ben Nadel's post to reduce spam feature using Math (http://www.bennadel.com/blog/197-How-I-Stop-Spammers-On-My-ColdFusion-Blog.htm). While this method is not o…
Hi, Even though I have created this Tutorial on My personal Blog, Some people might not able to find my website, So here i am posting it again Today, from the topic it is very clear that i will be showing you here the very basic usage of how we …
Come and listen to Percona CEO Peter Zaitsev discuss what’s new in Percona open source software, including Percona Server for MySQL (https://www.percona.com/software/mysql-database/percona-server) and MongoDB (https://www.percona.com/software/mongo-…
In this brief tutorial Pawel from AdRem Software explains how you can quickly find out which services are running on your network, or what are the IP addresses of servers responsible for each service. Software used is freeware NetCrunch Tools (https…

688 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