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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T17:28:50+00:00 2026-06-14T17:28:50+00:00

I want to access ssl webservice. I have generated the client bindings in Netbeans

  • 0

I want to access ssl webservice.

  1. I have generated the client bindings in Netbeans
  2. Generated JKS and imported client pfx file to the client.jks
    with ckeystorepwd and calias
  3. Webservice Producer has shared server.jks with srvalias and srvkeystorepwd
  4. I have configured the Keystore and TrustStore in NetBeans IDE and I am
    running Main.java and

I am able to consume the webservice. I want to consume the webservice without NetBeansIDE. I need to configure the Keystroe and Truststore (client.jks,server.jks) to the
environment pragmatically.

I have included the below code in my Main.java but it is giving below error , Please guide me how can I configure the keystroe ,truststore.

Main.java Code

System.setProperty("-Djavax.net.ssl.keyStore",JKSFILE);
System.setProperty("-Djavax.net.ssl.keyStorePassword",JKSPWD);
System.setProperty("javax.net.ssl.keyStoreType", "JKS");

System.setProperty("-Djavax.net.ssl.trustStore",JKSFILET);
System.setProperty("-Djavax.net.ssl.trustStorePassword",JKSPWDT);
System.setProperty("javax.net.ssl.requireClientAuth", "true");  
System.setProperty("com.sun.xml.ws.transport.http.client.
    HttpTransportPipe.dump","true");

URL u;  
u = new URL(MAIN_URL);  
IWebService service = new 
WebService(u).getWS2007HttpBindingIWebService();

Error

SEVERE: WSS1906: Invalid key provided for encryption/decryption.
java.security.InvalidKeyException: Illegal key size or default parameters
    at javax.crypto.Cipher.a(DashoA13*..)
    at javax.crypto.Cipher.a(DashoA13*..)
    at javax.crypto.Cipher.a(DashoA13*..)
    at javax.crypto.Cipher.init(DashoA13*..)
    at javax.crypto.Cipher.init(DashoA13*..)
    at com.sun.xml.ws.security.opt.impl.enc.CryptoProcessor.initCipher(CryptoProcessor.java:125)
    at com.sun.xml.ws.security.opt.impl.enc.CryptoProcessor.encryptData(CryptoProcessor.java:269)
    at com.sun.xml.ws.security.opt.impl.enc.CryptoProcessor.encrypt(CryptoProcessor.java:153)
    at com.sun.xml.ws.security.opt.impl.util.CVDataHandler.writeTo(CVDataHandler.java:69)
    at javax.activation.ObjectDataContentHandler.writeTo(Unknown Source)
    at javax.activation.DataHandler$1.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
Exception in thread "DataHandler.getInputStream" com.sun.xml.wss.impl.XWSSecurityRuntimeException: Unable to calculate cipher value as invalid key was provided
  • 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-14T17:28:51+00:00Added an answer on June 14, 2026 at 5:28 pm

    Resolved the issue,

    I was not using the same JVM where I have copied the policy jar as
    part of JCE-6 configuration in Eclipse environment.

    Now I have changed the JRE for the project and able to run the program without any issue.

    C:\Program Files (x86)\Java\jdk1.6.0_33\bin\java -jar “WSClient.jar”

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

Sidebar

Related Questions

I want to access camera to record video to upload, but have come across
I don't have a good knowledge of SSL principles, but just want the encryption
I want my users access a specific asp.net virtual directory only via SSL. Is
I want to force ssl access on an entire site, except for the following
UPDATED I have a Metro 2.1.1 WebService secured with the mechanism Transport Security (SSL)
I want to access a web service over HTTPS. I have been given a
I want to access the following path on Ubuntu in my python code: ~/.mozilla/firefox/dh4ytbdj.default/bookmarkbackups
I want to Access Information of Builds of Team Projects to use them in
I want to access java script's return value , which in is in a
I want to access text-shadow property just like we access padding property. Means ,

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.