473,657 Members | 2,395 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Accessing Web Service through a Proxy.

Hello,

I have an unmanaged VC7 app (ActiveX control implemented using MFC)
calling a C# dotnet service. I'm using the VS2003 generated proxy
class derived from CSoapSocketClie ntT. The activeX control works fine
but when used through a proxy that requires authentication I end up
getting 407 error. I tried using authentication schemes as suggested in
most of the threads.

CAtlHttpClient& httpClient = webserviceInst. m_socket;
CSampleBasicAut h basicAuth;
httpClient.AddA uthObj(_T("BASI C"), &basicAuth, &basicAuth);
CNTLMAuthObject ntlmAuth;
httpClient.AddA uthObj(_T("NTLM "),&ntlmAut h);
httpClient.Nego tiateAuth(true) ;

webserviceInst is the CSoapSocketClie ntT derived proxy class. Am I on
the right track with this?

Also if I use only basic authentication and have the user enter his
credentials it works fine. But with this combination of authentication
schemes NTLM and BASIC the NTLM authentication fails and somehow basic
authentication is not carried out after that..

Is there any way in which I could read the Internet Explorer
credentials and use them while accessing the webservice maybe using (
CSoapWininetCli ent ) . As the the idea of basic authentication and the
activex plug-in asking users for credentials would not be correct?

Please suggest me an appropriate way in which this isue can be
resolved.

Thanks in Advance,
Punit.

Feb 24 '06 #1
0 1212

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
2331
by: Bruce Farmer | last post by:
I am having problems accessing a managed object from unmanaged code. Specifically, I have a .NET forms application with a web service proxy. The forms application links to an unmanaged DLL which uses callbacks to receive data via TCP. The data received in the callback must be passed to a web service via a web method provided by the proxy. So the callback (which is unmanaged code) needs to access the proxy (managed object) to send the...
0
2631
by: George | last post by:
Hello, I'm running an ASPX application "WebApplication1" which consumes a web service (service1.asmx) hosted on a machine with IP (128.1.7.x) . The web service is located in the intranet. The web methods can be invoked successfully if "WebApplication1" is located in machines with the same subnet (128.1.7.x). However, it fails if "WebApplication1" is hosted on
0
3588
by: John Bown | last post by:
This query is similar to some others on this discussion group, but none of them were resolved! Can anybody help: The issue is related to integrated authentication. First I'll describe a simple scenario not involving ISA server, which works as expected: The web service is hosted on a server in the same domain as my workstation with anonymous access denied, and integrated authentication enabled. If I access the web service using the...
0
1601
by: brian | last post by:
I have built a client which can successfully talk to a 3rd party web service over HTTPS. All of this works great on my laptop when I am working from home (and thus not connected to the internet through my corporate network). However, when I go into the office, with this same laptop, everyone must use a firewall proxy to access anything on the WAN. I've tried all kinds of programmatic tricks to supply valid firewall credentials for my web...
1
2001
by: Nestor | last post by:
Hello all, I'm begining in the web services world and I've reading about how to invoke them using javascript from Mozilla browser (version 2.0 in my case). I found a very interesting example here: http://www.mozilla.org/projects/webservices/examples/babelfish-wsdl/index.html The problem I have is this: When I try to adapt the invokation on the
1
1202
by: =?Utf-8?B?Tmljaw==?= | last post by:
Hello, I hope I'm hoping posting this in the correct place. I've got an asmx web service and another guy created a client app that we distribute to customers. We seem to be having some trouble with customers accessing the service who are behind firewalls or are using proxy servers. Is there a way to detect their settings so we can avoid this problem? I don't have a great deal of experience accessing web services, so any help is...
4
4462
by: Jon | last post by:
I wrote a VS 2005 C# express programme that accesses a web service. It works fine when there's a direct connection to the internet, but on two different PCs with internet access via a proxy, I get this exception: System.Net.WebException: The request failed with HTTP status 407: Proxy Authentication Required. at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream...
10
9759
by: Anton | last post by:
Hi, when accessing a secured 3rd party webservice i'm getting a 401 HTTP Statuscode (unauthorized). When entering the url in a browser and entering the username and password manually, the wsdl is returned. So the username and password should be ok. I'm using this code: Merchant myMerch = new Merchant(); myMerch.merchantIdentifier=merchantId;
0
1214
by: martin.tittensor | last post by:
Hi, I've written a web service which needs to be accessed from mutiple customer sites and by non-technical users. The problem is that most end user's companies employ a firewall/proxy server to block web service traffic and they get back an error when attempting to access the web service. Is there a general way to authenticate to any firewall/proxy server? I also notice that there is a GetDefaultProxy method which returns the proxy...
0
8306
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8825
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
6164
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5632
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4152
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4304
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2726
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1955
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1615
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.