SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Member
    Join Date
    Jun 2011
    Posts
    1
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Using WSS4CF with <cfhttp>

    Hi there,

    We are attempting to access a remote webservice using cfhttp, requiring WS Security with username/password. I was in the middle of implementing a method here and ran into classpath issues etc, when my colleague suggested I take at WSS4CF. It seemed just what I needed to avoid needing to deal with those additional jar files etc.

    There is no example provided and I noticed that the cfc seems to be configured to work with something like a dotNet SOAP service where you simply call a method with arguments. I need an example that works with cfhttp where we pass an xml envelope in a cfhttpparam, e.g. as follows:

    <cfhttp
    url="https://ws.staging.training.gov.au/Deewr.Tga.WebServices/OrganisationService.svc/Organisation12"
    method="post">

    <cfhttpparam type="header" name="content-type" value="application/soap+xml" /><!---text/xml--->
    <cfhttpparam type="header" name="SOAPAction" value="http://training.gov.au/services/IOrganisationService/Search"/>
    <cfhttpparam type="header" name="accept-encoding" value="no-compression" />
    <cfhttpparam type="xml" value="#trim(sXML)#"/>

    </cfhttp>

  2. #2
    SitePoint Member
    Join Date
    Aug 2012
    Posts
    1
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by pbaylis View Post
    Hi there,

    We are attempting to access a remote webservice using cfhttp, requiring WS Security with username/password. I was in the middle of implementing a method here and ran into classpath issues etc, when my colleague suggested I take at WSS4CF. It seemed just what I needed to avoid needing to deal with those additional jar files etc.

    There is no example provided and I noticed that the cfc seems to be configured to work with something like a dotNet SOAP service where you simply call a method with arguments.
    As discussed here:

    http://www.bifrost.com.au/blog/index...ith-ColdFusion

    the example in the wiki is the standard usage:

    http://wss4cf.riaforge.org/wiki/

    Adding the info you need to the underlying axis WS object is going to work best. If you have to do it with raw http calls, you might be able to get the headers etc from the methods in the CFC.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •