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 8974791
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T18:44:49+00:00 2026-06-15T18:44:49+00:00

Requirement is to call a Java Web Service. There is a WSDL provided. Call

  • 0

Requirement is to call a Java Web Service. There is a WSDL provided. Call is successful in unsecured fashion. Now the service call needs to be authenticated. Service call will be successful only via a paricular windows userid/password. Since everything in our application is config based, we don’t want to hard-code anything in code. Appreciate if someone can show how to do so ?

I have this config by the way….

  <basicHttpBinding>

        <binding name="MyBinding" closeTimeout="00:01:00"
                    openTimeout="00:01:00" receiveTimeout="00:30:00" sendTimeout="00:10:00"
                    allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard"
                     maxBufferSize="2147483647" maxBufferPoolSize="2147483647" maxReceivedMessageSize="2147483647"
                    messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered"
                    useDefaultWebProxy="true">
          <readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384"
              maxBytesPerRead="4096" maxNameTableCharCount="16384" />
          <security mode="None">
            <transport clientCredentialType="None" proxyCredentialType="None" 
                realm="" />
            <message clientCredentialType="UserName" algorithmSuite="Default" />
          </security>
        </binding>


  </basicHttpBinding>
  • 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-06-15T18:44:50+00:00Added an answer on June 15, 2026 at 6:44 pm

    You can’t set the username/password anywhere in the WCF-specific configuration. You can, however, set the username/password pair as application settings, retrieve them from the code, and set them in the WCF client.

    <configuration>
      <appSettings>
        <add key="UserName" value="My user name" />
        <add key="Password" value="Your secret password" />
      </appSettings>
    </configuration>
    

    and in the code:

    var username = ConfigurationManager.AppSettings["UserName"];
    var password = ConfigurationManager.AppSettings["Password"];
    client.ClientCredentials.UserName.UserName = username;
    client.ClientCredentials.UserName.Password = password;
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

My requirement is very simple to understand. I want to call a web service
I implemented 4 views in AppDelegate depends on requirement it will call the view.I
There is a web service running on tomcat on a server. It is built
I have an requirement as per which I have to call an existing java
I have a Java web application I’m developing for a school project. There’s a
I am going to write a restful API, my requirement is to call methods
I have a requirement: I want to call method every day at any particular
Requirement is this ... We have our 3 web-applications deployed in RHEL-5 server, we
The below is my requirement. There is a screen in which an user enters
I have a requirement to update the properties file based upon the input provided

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.