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

  • Home
  • SEARCH
  • 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 8328691
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T01:31:33+00:00 2026-06-09T01:31:33+00:00

I have a wsdl that defines a soap header that needs to be passed

  • 0

I have a wsdl that defines a soap header that needs to be passed when calling the web service.

The sample SOAP Header is:

<soapenv:Header>
   <AuthenticationInfo>
      <userName>User</userName>
      <password/>
   </AuthenticationInfo>
</soapenv:Header>

CXF’s wsdl2java generated an “AuthenticationInfo” java class that I can create and populate with a username and password, but I don’t know the proper way to pass that to the CXF Client when calling the web service.

  • 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-09T01:31:34+00:00Added an answer on June 9, 2026 at 1:31 am

    Well, the most simple way to do this would be create an ArrayList of Header objects and add all your parameters or a Map<String,Object> and add all your headers as map.put("param1",param1).

    Finally get your request context and add this arraylist of map as

    requestContext.put(MessageContext.HTTP_REQUEST_HEADERS,
    soapHeaders); 
    

    If you’re trying to pass custom soap headers, refer THIS LINK.

    The general pitfalls have been mentioned in THIS DISCUSSION. It might be helpful to you.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a web service that I am calling and their published WSDL doesn't
I have a WSDL file defining a service that I have to implement in
I have an ASP.NET WebService that supports standard WSDL based SOAP calls and a
I have a bunch of generated SOAP client stubs that differ between WSDL versions.
I have and android client, that uses ksoap to communicate with a wsdl web
I have an WSDL / Web Service and I need to generate an set
I have a WSDL 1.1 file which describes my Web Service. Now I need
I have this class to send a SOAP-request (the class also defines the header)
I have a service contract that defines a method with a parameter of type
I have a client that wants to send a large number of SOAP Header

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.