<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>HTTP 401 Archives : Binary Bits</title>
	<atom:link href="https://blog.binarybits.net/tag/http-401/feed/" rel="self" type="application/rss+xml" />
	<link>https://blog.binarybits.net/tag/http-401/</link>
	<description>Bits &#38; Pieces - A blog by Kannan Balasubramanian</description>
	<lastBuildDate>Sat, 04 Aug 2012 12:41:44 +0000</lastBuildDate>
	<language>en-GB</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>
	<item>
		<title>The HTTP request is unauthorized with client authentication scheme &#8216;Ntlm&#8217;. The authentication header received from the server was &#8216;NTLM&#8217;</title>
		<link>https://blog.binarybits.net/the-http-request-is-unauthorized-with-client-authentication-scheme-ntlm-the-authentication-header-received-from-the-server-was-ntlm/</link>
					<comments>https://blog.binarybits.net/the-http-request-is-unauthorized-with-client-authentication-scheme-ntlm-the-authentication-header-received-from-the-server-was-ntlm/#respond</comments>
		
		<dc:creator><![CDATA[Kannan]]></dc:creator>
		<pubDate>Sat, 04 Aug 2012 07:31:01 +0000</pubDate>
				<category><![CDATA[Web]]></category>
		<category><![CDATA[HTTP 401]]></category>
		<category><![CDATA[SharePoint 2010]]></category>
		<category><![CDATA[Unauthorized]]></category>
		<category><![CDATA[Webservice]]></category>
		<guid isPermaLink="false">https://blog.binarybits.net/?p=243</guid>

					<description><![CDATA[<p>For one of the SharePoint implementation I was suppose to call the SharePoint 2010 ASMX service within a Custom WCF services hosted in a different server than the SharePoint 2010 host. So as usual I added the service reference (PS: The add web reference is not available in WCF solution). Then I was getting the [&#8230;]</p>
<p>The post <a href="https://blog.binarybits.net/the-http-request-is-unauthorized-with-client-authentication-scheme-ntlm-the-authentication-header-received-from-the-server-was-ntlm/">The HTTP request is unauthorized with client authentication scheme &#8216;Ntlm&#8217;. The authentication header received from the server was &#8216;NTLM&#8217;</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>For one of the SharePoint implementation I was suppose to call the SharePoint 2010 ASMX service within a Custom WCF services hosted in a different server than the SharePoint 2010 host.</p>
<p>So as usual I added the service reference (PS: The add web reference is not available in WCF solution). Then I was getting the following error whenever the ASMX method was hit in the WCF.</p>
<blockquote>
<p>&quot;The HTTP request is unauthorized with client authentication scheme &#8216;Ntlm&#8217;. The authentication header received from the server was &#8216;NTLM&#8217;&quot;</p>
</blockquote>
<p>After breaking my head for few minutes, decided to hit the Google and got the solution in the source mentioned at the end.</p>
<p>So finally the code which worked is listed below.</p>
<pre lang="csharp" line="1"> 
  EndpointAddress endpoint = new EndpointAddress(new Uri(&quot;http://SharePointserver/_vti_bin/InvoiceServices.svc&quot;));

  BasicHttpBinding httpBinding = new BasicHttpBinding();

  httpBinding.Security.Mode = BasicHttpSecurityMode.TransportCredentialOnly;

  httpBinding.Security.Transport.ClientCredentialType = HttpClientCredentialType.Ntlm;

  InvoiceServicesClient myClient = new InvoiceServicesClient(httpBinding, endpoint);

  myClient.ClientCredentials.Windows.AllowedImpersonationLevel = System.Security.Principal.TokenImpersonationLevel.Impersonation;

  //Invoke the service method here…</pre>
<p>Source: <a title="http://stackoverflow.com/questions/2608887/sharepoint-web-services-the-http-request-is-unauthorized-with-client-authenti" href="http://stackoverflow.com/questions/2608887/sharepoint-web-services-the-http-request-is-unauthorized-with-client-authenti">http://stackoverflow.com/questions/2608887/sharepoint-web-services-the-http-request-is-unauthorized-with-client-authenti</a></p>
<p>Note, in the above it might look like half of the link is missing and actually it works.</p>
<p>The post <a href="https://blog.binarybits.net/the-http-request-is-unauthorized-with-client-authentication-scheme-ntlm-the-authentication-header-received-from-the-server-was-ntlm/">The HTTP request is unauthorized with client authentication scheme &#8216;Ntlm&#8217;. The authentication header received from the server was &#8216;NTLM&#8217;</a> appeared first on <a href="https://blog.binarybits.net">Binary Bits</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.binarybits.net/the-http-request-is-unauthorized-with-client-authentication-scheme-ntlm-the-authentication-header-received-from-the-server-was-ntlm/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>

<!--
Performance optimized by W3 Total Cache. Learn more: https://www.boldgrid.com/w3-total-cache/?utm_source=w3tc&utm_medium=footer_comment&utm_campaign=free_plugin

Page Caching using Disk: Enhanced 
Minified using Disk

Served from: blog.binarybits.net @ 2026-04-18 15:50:14 by W3 Total Cache
-->