Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 530243
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T09:10:35+00:00 2026-05-13T09:10:35+00:00

I am attempting to consume an intranet web service with WCF. I added reference

  • 0

I am attempting to consume an intranet web service with WCF. I added reference to the service via the Add Service Reference feature in VS2008. In doing so I was prompted for network credentials to access the service which I provided and the service reference was added.

I then wrote some code that I would expect to fail as it doesn’t pass credentials along with the call of the service:

FooServiceClient proxy = new FooServiceClient();
bool isValid = proxy.ValidateBar(baz);

When I use this code I receieve the exception:
The HTTP request is unauthorized with client authentication scheme ‘Negotiate’.
The authentication header received from the server was ‘Basic realm=”Kerberos”‘.

Which is the same error I receieve when using either of the two code examples below.

FooServiceClient proxy = new FooServiceClient();
proxy.ClientCredentials.UserName.UserName = "USERNAME";
proxy.ClientCredentials.UserName.Password = "PASSWORD";
bool isValid = proxy.ValidateBar(baz);

or

FooServiceClient proxy = new FooServiceClient();

NetworkCredential creds = new NetworkCredential("USERNAME", "PASSWORD");

proxy.ClientCredentials.Windows.AllowedImpersonationLevel =
  TokenImpersonationLevel.Identification;
proxy.ClientCredentials.Windows.AllowNtlm = false;
proxy.ClientCredentials.Windows.ClientCredential = creds;

bool isValid = proxy.ValidateBar(baz);

My gut tells me that I have the security mode configured incorrectly. According to the server manager the end point that I am attempting to bind to is looking for a Basic Http Credential via SSL. Which after reading about WCF-BasicHttp Transport Properties lead me to believe that I should use this configuration:

<security mode="Transport">
  <transport clientCredentialType="Windows" />
  <message clientCredentialType="UserName" algorithmSuite="Default" />
</security>

Unfortunately, I continued to receive the same error.

Again, I am sure my troubles have to do with a configuration issue on my part as I’ve previously consumed this service in other projects with the outdated Add Web Reference.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T09:10:35+00:00Added an answer on May 13, 2026 at 9:10 am

    The below WCF binding configuration ended up being the solution.

    <security mode="Transport">
      <transport clientCredentialType="Basic" proxyCredentialType="None"
         realm="" />
      <message clientCredentialType="UserName" algorithmSuite="Default" />
    </security>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am attempting to consume a WCF web service from a Java client using
I'm receiving an error when I'm attempting to consume a web service: Cannot read
A colleague of mine is attempting to consume a web service that has been
I have a JAX-RPC web service that I am attempting to consume using Spring.
I am attempting to consume a web service through its corresponding wsdl. This service
I am attempting to Consume the Voxbone service publicly located here: http://sandbox.voxbone.com/VoxAPI/services/VoxAPI?wsdl So what
I'm running Windows 7 64-bit. I'm attempting to host a WCF service which will
I'm attempting to gzip a JSON response from an ASMX web service to be
I created WCF web service, deployed it, and debugged it. I wrote a console
I'm attempting to consume a SOAP service in a Silverlight 5 application and I'm

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.