<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>WCF - Supporting raw requests for individual operations</title><link>http://blogs.msdn.com/b/carlosfigueira/archive/2012/03/01/supporting-raw-requests-for-individual-operations.aspx</link><description>In the post about the raw mode for the WCF Web programming model , I showed how to use a content-type mapper to tell WCF to treat all incoming requests as “raw” requests, so we could map any content, including those supported by the formatter, to a Stream</description><dc:language>en-US</dc:language><generator>Telligent Evolution Platform Developer Build (Build: 5.6.50428.7875)</generator><item><title>re: WCF - Supporting raw requests for individual operations</title><link>http://blogs.msdn.com/b/carlosfigueira/archive/2012/03/01/supporting-raw-requests-for-individual-operations.aspx#10392298</link><pubDate>Fri, 08 Feb 2013 22:11:40 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:10392298</guid><dc:creator>WCFRESTUser</dc:creator><description>&lt;p&gt;Hi Carlos,&lt;/p&gt;
&lt;p&gt;I have a REST based service returning JSON data using VS 2010. I am using WebHttpbinding, security mode of &amp;quot;TransportCredentialOnly&amp;quot; with clientCredentialType as Basic. In the Servicebehavior, I am using usernameAuth with customUserNamePasswordValidatorType set to use a customer username n pwd validator and &amp;nbsp;userNamePasswordValidationMode=&amp;quot;Custom&amp;quot;. This is hosted on console app and when i try to navigate to the url, I get a credential pop up asking for a username and password which ties back to the routine I have written in the &amp;quot;customUserNamePasswordValidatorType &amp;quot; above. All this is good.&lt;/p&gt;
&lt;p&gt;The problem occurs when I host this on my local web server (IIS 7.5) instead of the console app.Using the same config, I get this error below. Note that for hosting on IIS and using REST , I am using System.web.routing to add a serviceroute using the webservicehostfactory (NOT using the .svc approach). Am I missing something here? I tried setting the IIS Authentication for the website to Anonymous which gives the error below. IF I set it to &amp;quot;Basic&amp;quot; I get the pop up for credentials but it does not tie back toe the routine I wrote above. Please let me know.&lt;/p&gt;
&lt;p&gt;The authentication schemes configured on the host (&amp;#39;Ntlm, Anonymous&amp;#39;) do not allow those configured on the binding &amp;#39;WebHttpBinding&amp;#39; (&amp;#39;Basic&amp;#39;). &amp;nbsp;Please ensure that the SecurityMode is set to Transport or TransportCredentialOnly. &amp;nbsp;Additionally, this may be resolved by changing the authentication schemes for this application through the IIS management tool, through the ServiceHost.Authentication.AuthenticationSchemes property, in the application configuration file at the &amp;lt;serviceAuthenticationManager&amp;gt; element, by updating the ClientCredentialType property on the binding, or by adjusting the AuthenticationScheme property on the HttpTransportBindingElement.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10392298" width="1" height="1"&gt;</description></item></channel></rss>