Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / Web Services / November 2005

Tip: Looking for answers? Try searching our database.

proxy class - xml

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
param@community.nospam - 03 Nov 2005 16:36 GMT
Hi all, I have generated a Proxy Class for a remote asp.net WS. The WS
method accepts a custom object and returns a custom object as well. There
seems to be an error somewhere and we cannot pinpoint it. Is there a way for
me to retrieve the underlying XML that is generated by the proxy class when
making the SOAP call? Also is there a way to retrieve the returned XML after
call the method?

TIA!
Emil Kvarnhammar - 03 Nov 2005 16:49 GMT
If you have access to the machine that is running the webservice, you
can access the local test page on that machine
(http://localhost/YourWebService.asmx).

Here, your'e able to see the xml output.

If you have no access to the server, you can always use a proxy application
such as Paros or the one included in Soap toolkit, to view the xml in/out
data.

regards
Emil Kvarnhammar
http://www.ynax.com

> Hi all, I have generated a Proxy Class for a remote asp.net WS. The WS
> method accepts a custom object and returns a custom object as well. There
[quoted text clipped - 4 lines]
>
> TIA!
Steven Cheng[MSFT] - 04 Nov 2005 02:42 GMT
Hi Param,

As for capturing the underlying SOAP XML message of our webservice calls,
we can use some TCP or HTTP trace utility tools. We can get them from the
following location:

#SOAP Toolkit 3.0
http://www.microsoft.com/downloads/details.aspx?familyid=c943c0dd-ceec-4088-
9753-86f052ec8450&displaylang=en

#TcpTrace
http://www.pocketsoap.com/tcptrace/

We can run them on both clientside and serverside to catpure the incoming
or outgoing SOAP message.

Hope helps. Thanks,

Steven Cheng
Microsoft Online Support

Signature

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

--------------------
| From: "Emil Kvarnhammar" <info at ynax.com>
| References: <uU5ffxI4FHA.3000@TK2MSFTNGP12.phx.gbl>
[quoted text clipped - 11 lines]
| Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP10.phx.gbl
| Xref: TK2MSFTNGXA01.phx.gbl
microsoft.public.dotnet.framework.aspnet.webservices:8255
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webservices
|
[quoted text clipped - 20 lines]
| >
| > TIA!
param@community.nospam - 06 Nov 2005 17:52 GMT
I downloaded the SOAP Toolkit, but have no idea how to use the Trace tool.
It keeps pointing to localhost. When I change the URL to the remote server
and make a webservice call, I still cannot see anything. Any ideas? Keep in
mind, I dont have access Server-Side. I only have access Client-Side.

TIA!

> Hi Param,
>
[quoted text clipped - 67 lines]
> | >
> | > TIA!
Steven Cheng[MSFT] - 07 Nov 2005 02:26 GMT
Thanks for your response Param,

The Trace Utility (in soap toolkit 3) can be used to trace SOAP message at
both clientside and serverside.  For clientside, we can use it through the
following steps:

1. Start the Trace Utility, and create a new Formatted Trace, there will
popup a dialog which contains the following fields:

##local port: ________
##destination host:________
##destination port:________

2. Since we we're tracing the message on clientside. We can put a certain
unused port for local port (like 8888). And the
"destination host" and "destination port" should be identical to the Target
server (where the webservice is hosted), for example:

##local port: __8888______
##destination host:____remoteServiceServer____
##destination port:____80____

After that, we also need to modify our webservice client proxy. We need to
make our webservcie client proxy send request to that configured  "local
port" above, so that the Trace Utility can capture the message ( and trace
utilty we help us forward it to the destination host and port after log the
message....)

For example, in your client application code, we call the service like:

WSProxy proxy = new WSProxy();

proxy.Url = "http://localhost:8888/VirtualDir/service.asmx";

proxy.CallMethod();

thus, the message call request will be send to "localhost:8888" first, then
be logged by TraceUtility and finally be forward to

"remoteServiceServer:80"  .....

If there're still anything unclear, please feel free to post here. Thanks,

Steven Cheng
Microsoft Online Support

Signature

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)


--------------------
| From: <param@community.nospam>
| References: <uU5ffxI4FHA.3000@TK2MSFTNGP12.phx.gbl>
<OmzMG5I4FHA.632@TK2MSFTNGP10.phx.gbl>
<R7hmdEO4FHA.1172@TK2MSFTNGXA01.phx.gbl>
| Subject: Re: proxy class - xml
| Date: Sun, 6 Nov 2005 11:52:44 -0600
[quoted text clipped - 9 lines]
| Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGP08.phx.gbl!tk2msftngp13.phx.gbl
| Xref: TK2MSFTNGXA01.phx.gbl
microsoft.public.dotnet.framework.aspnet.webservices:8287
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webservices
|
[quoted text clipped - 12 lines]
| >
| > #SOAP Toolkit 3.0

http://www.microsoft.com/downloads/details.aspx?familyid=c943c0dd-ceec-4088-
| > 9753-86f052ec8450&displaylang=en
| >
[quoted text clipped - 59 lines]
| > | >
| > | > TIA!
Steven Cheng[MSFT] - 09 Nov 2005 11:45 GMT
Hi Param,

How are you doing on this issue? Have you got the Trace Utility working
through the suggestions in my last reply? If there're any further things I
can help ,please feel free to post here.

Thank you!

Steven Cheng
Microsoft Online Support

Signature

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

--------------------
| X-Tomcat-ID: 58988189
| References: <uU5ffxI4FHA.3000@TK2MSFTNGP12.phx.gbl>
<OmzMG5I4FHA.632@TK2MSFTNGP10.phx.gbl>
<R7hmdEO4FHA.1172@TK2MSFTNGXA01.phx.gbl>
<eMgslrv4FHA.1140@tk2msftngp13.phx.gbl>
| MIME-Version: 1.0
| Content-Type: text/plain
[quoted text clipped - 9 lines]
| Path: TK2MSFTNGXA01.phx.gbl
| Xref: TK2MSFTNGXA01.phx.gbl
microsoft.public.dotnet.framework.aspnet.webservices:8290
| NNTP-Posting-Host: tomcatimport2.phx.gbl 10.201.218.182
|
[quoted text clipped - 88 lines]
| | >
| | > #SOAP Toolkit 3.0

http://www.microsoft.com/downloads/details.aspx?familyid=c943c0dd-ceec-4088-
| | > 9753-86f052ec8450&displaylang=en
| | >
[quoted text clipped - 61 lines]
| | > | >
| | > | > TIA!
param@community.nospam - 09 Nov 2005 14:50 GMT
Nopes, I cannot get it to work. The remote WS URL is
https://bizt.somedomain.com/cbtloanapps/loanapplication.asmx

I installed the Trace utility on my local web server & ran it. I started a
new formatted trace as follows:-

Local Port: 8888
Remote Host: bizt.somedomain.com
Remote Port: 443

I then in my code changed the URL for the proxy client to
http://localhost:8888/cbtloanapps/loanapplication.asmx

The trace finds a message, but the contents are blank. & the WS call returns
"an underlying connection was closed by the server"....

Any ideas?

> Hi Param,
>
[quoted text clipped - 207 lines]
> | | > | >
> | | > | > TIA!
Steven Cheng[MSFT] - 10 Nov 2005 09:10 GMT
Hello param,

Thanks for the response. As you mentioned the following configuration:

===============
Local Port: 8888
Remote Host: bizt.somedomain.com
Remote Port: 443
===================

Based on my experience, 443 is the default port of  SSL/TLS protocol. So is
that webservice endpoint protected through SSL/TLS? If so, I'm afraid we
can not use any intermediate monitors tools to intercept the message, even
if, since the message content are encrypted, that won't be human readable
to us.

So would you please confirm whether you're consuming the webservice through
the SSL/TLS connection?

Thanks,

Steven Cheng
Microsoft Online Support

Signature

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)


--------------------
| From: <param@community.nospam>
| References: <uU5ffxI4FHA.3000@TK2MSFTNGP12.phx.gbl>
<OmzMG5I4FHA.632@TK2MSFTNGP10.phx.gbl>
<R7hmdEO4FHA.1172@TK2MSFTNGXA01.phx.gbl>
<eMgslrv4FHA.1140@tk2msftngp13.phx.gbl>
<sfJX$K04FHA.2124@TK2MSFTNGXA01.phx.gbl>
<PdMWnMS5FHA.1240@TK2MSFTNGXA02.phx.gbl>
| Subject: Re: proxy class - xml
| Date: Wed, 9 Nov 2005 08:50:09 -0600
[quoted text clipped - 9 lines]
| Path: TK2MSFTNGXA02.phx.gbl!TK2MSFTNGP08.phx.gbl!tk2msftngp13.phx.gbl
| Xref: TK2MSFTNGXA02.phx.gbl
microsoft.public.dotnet.framework.aspnet.webservices:30824
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webservices
|
[quoted text clipped - 153 lines]
| > | | >
| > | | > #SOAP Toolkit 3.0

http://www.microsoft.com/downloads/details.aspx?familyid=c943c0dd-ceec-4088-
| > | | > 9753-86f052ec8450&displaylang=en
| > | | >
[quoted text clipped - 68 lines]
| > | | > | >
| > | | > | > TIA!
param@community.nospam - 10 Nov 2005 15:05 GMT
Steve, yes. The remote web service runs over SSL under IIS...

So I guess I cannot do anything then right?

Thanks

> Hello param,
>
[quoted text clipped - 312 lines]
> | > | | > | >
> | > | | > | > TIA!
Steven Cheng[MSFT] - 11 Nov 2005 06:34 GMT
Hi Param,

I'm afraid for HTTPS connection it's hard to do transport layer monitoring.
I know that there exists some 3rd party tools which can intercept the https
message on clientside, but we do not support any tools.  One thing we can
still consider is that the .NET /asp.net webservice provide an interface
named "SoapExtension" which can help intercept message between our code and
Transport layer.  We can create a custom SoapExtension to log message, here
are some reference on creating SoapExtension:

#Using SOAP Extensions in ASP.NET
http://msdn.microsoft.com/msdnmag/issues/04/03/ASPColumn/default.aspx

#Altering the SOAP Message Using SOAP Extensions
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/htm
l/cpconAlteringSOAPMessageUsingSOAPExtensions.asp

Thanks,

Steven Cheng
Microsoft Online Support

Signature

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)


--------------------
| From: <param@community.nospam>
| References: <uU5ffxI4FHA.3000@TK2MSFTNGP12.phx.gbl>
<OmzMG5I4FHA.632@TK2MSFTNGP10.phx.gbl>
<R7hmdEO4FHA.1172@TK2MSFTNGXA01.phx.gbl>
<eMgslrv4FHA.1140@tk2msftngp13.phx.gbl>
<sfJX$K04FHA.2124@TK2MSFTNGXA01.phx.gbl>
<PdMWnMS5FHA.1240@TK2MSFTNGXA02.phx.gbl>
<OMX2izT5FHA.1140@tk2msftngp13.phx.gbl>
<QVxYead5FHA.1120@TK2MSFTNGXA02.phx.gbl>
| Subject: Re: proxy class - xml
| Date: Thu, 10 Nov 2005 09:05:22 -0600
[quoted text clipped - 9 lines]
| Path: TK2MSFTNGXA02.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP10.phx.gbl
| Xref: TK2MSFTNGXA02.phx.gbl
microsoft.public.dotnet.framework.aspnet.webservices:30844
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webservices
|
[quoted text clipped - 235 lines]
| > | > | | >
| > | > | | > #SOAP Toolkit 3.0

http://www.microsoft.com/downloads/details.aspx?familyid=c943c0dd-ceec-4088-
| > | > | | > 9753-86f052ec8450&displaylang=en
| > | > | | >
[quoted text clipped - 79 lines]
| > | > | | > | >
| > | > | | > | > TIA!

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.