473,396 Members | 1,810 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Webservices through firewall

Anyone knows how to add web reference in C#, when the internet need
authentication.

The credentials for proxy is asked and I pass the information. But after
all, I got this message:

"The underlying connection was closed: Unable to connect to the remote
server."
Tks!
Nov 17 '05 #1
6 4532
Daniel,

There should be a property on your web service proxy which takes an
implementation of IWebProxy (which you can get from the static
GetDefaultProxy method through the WebProxy class). Set that, and it should
work.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Daniel Santana" <Da***********@discussions.microsoft.com> wrote in message
news:7C**********************************@microsof t.com...
Anyone knows how to add web reference in C#, when the internet need
authentication.

The credentials for proxy is asked and I pass the information. But after
all, I got this message:

"The underlying connection was closed: Unable to connect to the remote
server."
Tks!

Nov 17 '05 #2
Yes... But how I make that proxy, if I can't access the webservice?

Tks again.

"Nicholas Paldino [.NET/C# MVP]" wrote:
Daniel,

There should be a property on your web service proxy which takes an
implementation of IWebProxy (which you can get from the static
GetDefaultProxy method through the WebProxy class). Set that, and it should
work.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Daniel Santana" <Da***********@discussions.microsoft.com> wrote in message
news:7C**********************************@microsof t.com...
Anyone knows how to add web reference in C#, when the internet need
authentication.

The credentials for proxy is asked and I pass the information. But after
all, I got this message:

"The underlying connection was closed: Unable to connect to the remote
server."
Tks!


Nov 17 '05 #3
Daniel,

There are two proxies here. There is the proxy between your machine and
the internet, and there is the proxy (in code) that you are using to make
calls on the remote web service. You need to set the proxy on your code
(which calls the web service) with the details of the proxy between your
machine and the internet so that it can reach the webservice.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Daniel Santana" <Da***********@discussions.microsoft.com> wrote in message
news:BF**********************************@microsof t.com...
Yes... But how I make that proxy, if I can't access the webservice?

Tks again.

"Nicholas Paldino [.NET/C# MVP]" wrote:
Daniel,

There should be a property on your web service proxy which takes an
implementation of IWebProxy (which you can get from the static
GetDefaultProxy method through the WebProxy class). Set that, and it
should
work.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Daniel Santana" <Da***********@discussions.microsoft.com> wrote in
message
news:7C**********************************@microsof t.com...
> Anyone knows how to add web reference in C#, when the internet need
> authentication.
>
> The credentials for proxy is asked and I pass the information. But
> after
> all, I got this message:
>
> "The underlying connection was closed: Unable to connect to the remote
> server."
>
>
> Tks!


Nov 17 '05 #4
OK...

Still talking about WS proxy (code). I know 2 ways to get that proxy:

1) Using the wsdl tool (in .Net command prompt);
2) Adding a web reference in my project.

And there's where lives my doubt. I don't know how do get that proxy
(neither wsdl, neither add web reference) just because the proxy (internet
proxy) blocks the connection. Even typing proxy info (just like IE) I steel
receive the "underlying" message....

Any idea of how to pass the proxy info in command prompt (in order to use
the wsdl.exe) or how to set the proxy info in add reference wizard?

Tks

"Nicholas Paldino [.NET/C# MVP]" wrote:
Daniel,

There are two proxies here. There is the proxy between your machine and
the internet, and there is the proxy (in code) that you are using to make
calls on the remote web service. You need to set the proxy on your code
(which calls the web service) with the details of the proxy between your
machine and the internet so that it can reach the webservice.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Daniel Santana" <Da***********@discussions.microsoft.com> wrote in message
news:BF**********************************@microsof t.com...
Yes... But how I make that proxy, if I can't access the webservice?

Tks again.

"Nicholas Paldino [.NET/C# MVP]" wrote:
Daniel,

There should be a property on your web service proxy which takes an
implementation of IWebProxy (which you can get from the static
GetDefaultProxy method through the WebProxy class). Set that, and it
should
work.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Daniel Santana" <Da***********@discussions.microsoft.com> wrote in
message
news:7C**********************************@microsof t.com...
> Anyone knows how to add web reference in C#, when the internet need
> authentication.
>
> The credentials for proxy is asked and I pass the information. But
> after
> all, I got this message:
>
> "The underlying connection was closed: Unable to connect to the remote
> server."
>
>
> Tks!


Nov 17 '05 #5
Daniel,

There are a number of slash commands to use for setting the proxy using
WSDL (/proxy, /proxydomain).

However, the easiest solution would be to get the WSDL file through IE
or a browser, and then just save it locally, and run WSDL.exe against that.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Daniel Santana" <Da***********@discussions.microsoft.com> wrote in message
news:D0**********************************@microsof t.com...
OK...

Still talking about WS proxy (code). I know 2 ways to get that proxy:

1) Using the wsdl tool (in .Net command prompt);
2) Adding a web reference in my project.

And there's where lives my doubt. I don't know how do get that proxy
(neither wsdl, neither add web reference) just because the proxy (internet
proxy) blocks the connection. Even typing proxy info (just like IE) I
steel
receive the "underlying" message....

Any idea of how to pass the proxy info in command prompt (in order to use
the wsdl.exe) or how to set the proxy info in add reference wizard?

Tks

"Nicholas Paldino [.NET/C# MVP]" wrote:
Daniel,

There are two proxies here. There is the proxy between your machine
and
the internet, and there is the proxy (in code) that you are using to make
calls on the remote web service. You need to set the proxy on your code
(which calls the web service) with the details of the proxy between your
machine and the internet so that it can reach the webservice.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Daniel Santana" <Da***********@discussions.microsoft.com> wrote in
message
news:BF**********************************@microsof t.com...
> Yes... But how I make that proxy, if I can't access the webservice?
>
> Tks again.
>
> "Nicholas Paldino [.NET/C# MVP]" wrote:
>
>> Daniel,
>>
>> There should be a property on your web service proxy which takes
>> an
>> implementation of IWebProxy (which you can get from the static
>> GetDefaultProxy method through the WebProxy class). Set that, and it
>> should
>> work.
>>
>> Hope this helps.
>>
>>
>> --
>> - Nicholas Paldino [.NET/C# MVP]
>> - mv*@spam.guard.caspershouse.com
>>
>> "Daniel Santana" <Da***********@discussions.microsoft.com> wrote in
>> message
>> news:7C**********************************@microsof t.com...
>> > Anyone knows how to add web reference in C#, when the internet need
>> > authentication.
>> >
>> > The credentials for proxy is asked and I pass the information. But
>> > after
>> > all, I got this message:
>> >
>> > "The underlying connection was closed: Unable to connect to the
>> > remote
>> > server."
>> >
>> >
>> > Tks!
>>
>>
>>


Nov 17 '05 #6
Thank you so pretty much!!

"Nicholas Paldino [.NET/C# MVP]" wrote:
Daniel,

There are a number of slash commands to use for setting the proxy using
WSDL (/proxy, /proxydomain).

However, the easiest solution would be to get the WSDL file through IE
or a browser, and then just save it locally, and run WSDL.exe against that.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Daniel Santana" <Da***********@discussions.microsoft.com> wrote in message
news:D0**********************************@microsof t.com...
OK...

Still talking about WS proxy (code). I know 2 ways to get that proxy:

1) Using the wsdl tool (in .Net command prompt);
2) Adding a web reference in my project.

And there's where lives my doubt. I don't know how do get that proxy
(neither wsdl, neither add web reference) just because the proxy (internet
proxy) blocks the connection. Even typing proxy info (just like IE) I
steel
receive the "underlying" message....

Any idea of how to pass the proxy info in command prompt (in order to use
the wsdl.exe) or how to set the proxy info in add reference wizard?

Tks

"Nicholas Paldino [.NET/C# MVP]" wrote:
Daniel,

There are two proxies here. There is the proxy between your machine
and
the internet, and there is the proxy (in code) that you are using to make
calls on the remote web service. You need to set the proxy on your code
(which calls the web service) with the details of the proxy between your
machine and the internet so that it can reach the webservice.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Daniel Santana" <Da***********@discussions.microsoft.com> wrote in
message
news:BF**********************************@microsof t.com...
> Yes... But how I make that proxy, if I can't access the webservice?
>
> Tks again.
>
> "Nicholas Paldino [.NET/C# MVP]" wrote:
>
>> Daniel,
>>
>> There should be a property on your web service proxy which takes
>> an
>> implementation of IWebProxy (which you can get from the static
>> GetDefaultProxy method through the WebProxy class). Set that, and it
>> should
>> work.
>>
>> Hope this helps.
>>
>>
>> --
>> - Nicholas Paldino [.NET/C# MVP]
>> - mv*@spam.guard.caspershouse.com
>>
>> "Daniel Santana" <Da***********@discussions.microsoft.com> wrote in
>> message
>> news:7C**********************************@microsof t.com...
>> > Anyone knows how to add web reference in C#, when the internet need
>> > authentication.
>> >
>> > The credentials for proxy is asked and I pass the information. But
>> > after
>> > all, I got this message:
>> >
>> > "The underlying connection was closed: Unable to connect to the
>> > remote
>> > server."
>> >
>> >
>> > Tks!
>>
>>
>>


Nov 17 '05 #7

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

Similar topics

6
by: Joseph Geretz | last post by:
I recently upgraded my server to Windows 2003. The first thing I noticed is that my sample WebService pages no longer worked. The Invoke test button is missing. This is addresed by the following KB...
5
by: JD | last post by:
Hello Everyone, I am doing some research on Webservices for a possible project and I was wondering if anyone knew if a specific port needed to be opened on a firewall for them to work, from what...
4
by: nixon | last post by:
Hi there! Im trying to build a 3 tier application that uses a smartclient in the "view" layer. The communication between the smartclient and the server should be webservices because of potentiel...
2
by: sameer | last post by:
hi all, Description of my .net application: Desktop application using webservices over the internet to communicate with the sql server2000 database which is sitting behind the webserver. Done...
0
by: sameer | last post by:
hi all, Description of my .net application: Desktop application using webservices over the internet to communicate with the sql server2000 database which is sitting behind the webserver. Done...
0
by: sahil | last post by:
hi , how can i access webservices sitting outside the firewall in my VS express C# application.because when i try to "ADD WEBREFERENCE" to my application and click go.....it authenticates me for my...
5
by: ChrisM | last post by:
Hi, I have written a stand alone WinForms application with an MS Access back-end for the (small)company I work for. They are now talking about moving a part of their operations into a second...
7
by: pthomet | last post by:
Another formulation of the message tittle could be : is it really "safe" (in the business sense) to embed a SSL webservice consumer into any given software, given that any time a proxy server will...
6
by: =?Utf-8?B?Q3JhaWc=?= | last post by:
If I have an application that I send out to users, and the application interacts with the database (behind the scenes, no direct sql creation by the users)....do webservices make the app more...
1
by: rada.lambretha | last post by:
Configuring Linux as a Firewall * Making installation choices * Introducing iptables * Using iptables commands * Simplifying things with firewall GUIs * Adding proxy functionality As...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.