I need to get my ColdFusion web apps to authenticate to a .NET server. The .NET people have given me a code snippet, but it's a .NET code snippet, so it doesn't help me much. I know I can use <cfinvoke> or CreateObject() to call the service, but I'm not exactly sure how.

Does anyone here have any experience with this?

cpradio
—
2012-10-03T11:56:49Z —
#2

I've never done it with ColdFusion, but I've seen it done in C++, and in short, if you are truly calling a .NET web service you need to build the SOAP request exactly as .NET wants it to be built.

The easiest way to do this is use Fiddler and record the process of being authenticated by a .NET login page, capture the SOAP request sent to the server and make your code produce the same request.

Yeah, I was looking at that page. I have a meeting with our .NET people tomorrow. I'm thinking that they'll need to create this .wsdl file for us, and I can throw a <cfinvoke> at it. They gave us some code, but I'm starting to think that it's old asp code from around 10 years ago that they keep reusing, and I'm not sure if I can do anything with it from CF.

We'll see what tomorrow's meeting brings.

cpradio
—
2012-10-03T13:50:12Z —
#5

Usually if you know the Service URL, you can load it in your web browser (depending if the WSDL output is enabled), and then add ?wsdl to the URL and it should produce it (again, if it is enabled)

Yeah, what I need for them is the URL. I think I can figure out the rest from there.

cydewaze
—
2012-10-04T19:33:44Z —
#7

Well this is interesting. I have to point users to another server where they log in, then carry them back to mine with a session ID. :goof:

cpradio
—
2012-10-04T21:02:17Z —
#8

sigh no one builds services very well anymore... so sorry you have to go through that.

cydewaze
—
2012-10-05T12:41:06Z —
#9

It's because all of our web apps need to use an access card (gov't) so we have to log in on the server that's set up to read the cards. I'm hoping that the session cookie from that server populates GetAuthUser(), in which case I'll be all set. Then I just have to figure out a way to tell the remote server that the session is still alive so it doesn't time out.

wwb_99
—
2012-10-05T13:42:20Z —
#10

It's probably not a cookie but rather a token that has little to do with a http session. You'll probably need to pass that token back in some form for each request.

cydewaze
—
2012-10-05T14:00:03Z —
#11

Yep, I can probably do a cfinvoke to a web service they have for just this purpose. Any time a page is submitted, it triggers the cfinvoke.

system
—
2012-10-18T11:46:37Z —
#12

i have not done this but my experience a bit says that it can b done by making a web methord and on every app request it should come to .net server and like this they can b connected.. same way as snippet.. but i don't think other then this will be easy work ..it might make this a large projectregardsAndy<snip>