.NET     Console.WriteLine( "All Things .NET" );
.NET Nerd Blog Home
11.22.2004

 
Allow POST & GET for Web Services
(updated 6/28/05 to reflect latest 1.1 security info)

If desired, you can tweak a config file to tell IIS / ASP.NET 1.1 to allow POST and GET protocols for receiving web services calls.

Check out the <protocols> section of MACHINE.CONFIG. It shows the possible protocols that are allowed by the web service engine. By default, only SOAP is allowed. HttpPostLocalhost is added by default to allow you to test the web service with IE from the localhost.

Best way to change this is by overriding the settings in the web.config of your particular web service (so you won't affect all web services on the machine). You do this by adding or removing protocols from the list.

The default setup in MACHINE.CONFIG has HttpPost removed, and HttpPostLocalhost enabled. You can allow remote clients to use IE and do HTTP POST with the following:
<webServices>
<protocols>
<add name="HttpPost"/>
</protocols>
...
Obviously, POST or GET is non-standard for xml based web services, so use at your own risk outside of testing.

see article here

protocols config element reference is here.



Powered by Blogger