wrong host on example invoke pages

R

Rick Boardman

Sorry for the multiple posts. Seems I didn't have my nospam email setup so
MSDN didn't recognize me as a subscriber. Hopefully this will be the last
time I have to repost this.

WebServices on my machine have recently begun experiencing problems when
testing the service through the description pages.

For example:
http://www.testsite.com/services/details.asmx?op=Insert
The various methods begin with the following header information:

POST /services/details.asmx HTTP/1.1
Host: machinename.domain.com
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://tempuri.org/services/details/Insert"

The Host here is wrong and should be the testsite, not the local machine.

Clicking Invoke tries to redirect to this:
http://machinename.domain.com/services/details.asmx/Insert

when it should be redirecting to this:
http://www.testsite.com/services/details.asmx/Insert

Also in the service description for the service the following is wrong:

- <wsdl:service name="details">
- <wsdl:port name="siteSoap" binding="tns:siteSoap">
<soap:address
location="http://machinename.domain.com/services/details.asmx" />
</wsdl:port>
- <wsdl:port name="siteHttpGet" binding="tns:siteHttpGet">
<http:address
location="http://machinename.domain.com/services/details.asmx" />
</wsdl:port>
- <wsdl:port name="siteHttpPost" binding="tns:siteHttpPost">
<http:address
location="http://machinename.domain.com/services/details.asmx" />
</wsdl:port>
</wsdl:service>

These problems started when I installed SP1 on Windows 2003 Server. There
were some problems during the install and I eventually got the server back up
so it may have been related to other surronding issues.

If anyone can shed some light on this for me that would be great! I'm sure
it's something simple and likely just a setting somewhere.
 
C

Chad Z. Hower aka Kudzu

"=?Utf-8?B?UmljayBCb2FyZG1hbg==?="
POST /services/details.asmx HTTP/1.1
Host: machinename.domain.com

Is this also name of the machine it is on? Where/When did you initially enter
this anywhere?
 
R

Rick Boardman

Chad Z. Hower aka Kudzu said:
"=?Utf-8?B?UmljayBCb2FyZG1hbg==?="


Is this also name of the machine it is on? Where/When did you initially enter
this anywhere?

Yes, machine name is the name of the machine this is on (entered during
windows installation) and domain.com is the domain entered during windows
creation
 
C

Chad Z. Hower aka Kudzu

=?Utf-8?B?UmljayBCb2FyZG1hbg==?= said:
Yes, machine name is the name of the machine this is on (entered during
windows installation) and domain.com is the domain entered during
windows creation

The page you are showing, is only meant for debugging not real use. When
ASP.NET generates them, it appears to just take the machine name, not the
host parameter in your scenario. In fact it should be taking the website name
as in IIS, and likely is but without seeing your machine I cant see what your
names are and why you want it different.
 
R

Rick Boardman

The page you are showing, is only meant for debugging not real use. When
ASP.NET generates them, it appears to just take the machine name, not the
host parameter in your scenario. In fact it should be taking the website name
as in IIS, and likely is but without seeing your machine I cant see what your
names are and why you want it different.

I understand this is only for debugging, not real use. Being that we are a
development shop, we do a lot of debugging and testing at this level.

Please note:
testsite.com is virtually hosted on machinename.domain.com

Before Windows 2003 Server SP1 update:
http://www.testsite.com/services/details.asmx/Insert

After Windows 2003 Server SP1 update:
http://machinename.domain.com/services/details.asmx/Insert
Which causes the invoke to get page not found errors.

I want webservice example invoke pages to work like they did before Windows
2003 Server SP1 update where the service was picking up the virtualy hosted
domain not the local machine name and domain.
 
C

Chad Z. Hower aka Kudzu

=?Utf-8?B?UmljayBCb2FyZG1hbg==?= said:
I want webservice example invoke pages to work like they did before
Windows 2003 Server SP1 update where the service was picking up the
virtualy hosted domain not the local machine name and domain.

Windows SP's have a bad habit of breaking things in IIS through lockdown
procedures. I would suggest checking the application settings, or more
importantly the settings for this virtual host and see if anything has
changed. .NET hasn't, but something is causing IIS to feed information to
..NET differently.
 
R

Rick Boardman

I've looked through the settings for anything I thought might be an issue
(even before I posted here last month) but haven't found anything I can point
at as the problem.

I reviewed the site link posted. From what I gather it doesn't get into
anything specific nor fixes and basically indicates Windows 2003 Server SP1
breaks things.

Is there maybe an MVP or MS Employee who might know what .net does to
generate the hostname and the verb settings in the wsdl? If so I imagine
this problem can be isolated to a specific setting in the registry, metabase,
etc. This would be extremely helpful.
 
R

Rick Boardman

R

Rick Boardman

Still no response from MVP or Microsoft.

This is still an issue.

wsdl are being generated with incorrect URLs
request.url.host is responding with incorrect URLs

This is after install of windows 2003 server sp 1

There are others experiencing similar issues:

"In some forums and blogs many people had simmilar isuses. It seems that
with W2003 SP1 request.url.host doesn't return the public web domain any
more. Now it return the real server domain name. In your case
palhost.palhost.net. If this is by design or a bug in SP1, i don't know yet."
found on
http://forums.asp.net/1005195/ShowPost.aspx

"Recently my hosting service patched their Windows 2003 servers to SP1. In
doing so i noticed that all of a sudden this site (ie my .text blog) was
broken. I was getting the dreaded "A blog matching the location you requested
was not found" error. Apparently calls to Request["Server_Name"] previously
returned the HTTP_HOST variable instead. This has been fixed and now returns
the actual machine name as is the original purpose. Unfortunaltey it seems
that Request.Url.Host also seems to now take on this behaviour (at least it
did for this server?). .TEXT makes a call to this method to get the current
host."

found on http://thewebfarm.com/blog/archive/2005/04/03/189.aspx
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Staff online

Members online

Forum statistics

Threads
473,766
Messages
2,569,569
Members
45,045
Latest member
DRCM

Latest Threads

Top