javax.xml.ws.WebServiceException: org.apache.cxf.service.factory.ServiceConstructionException: Failed to create service.

sourceforge.net | 5 months ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    OSCARMcMaster / Bugs / #3556 MyOSCAR Auto-login fails

    sourceforge.net | 1 year ago
    javax.xml.ws.WebServiceException: org.apache.cxf.service.factory.ServiceConstructionException: Failed to create service.
  2. 0

    OSCARMcMaster / Bugs / #3556 MyOSCAR Auto-login fails

    sourceforge.net | 5 months ago
    javax.xml.ws.WebServiceException: org.apache.cxf.service.factory.ServiceConstructionException: Failed to create service.
  3. 0

    Polling with Javamail and POP3 SSL causes error while DH keypair generation after a few hours

    Stack Overflow | 3 years ago
    javax.net.ssl.SSLException: java.lang.RuntimeException: Could not generate DH keypair
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    [NMS-7959] Bouncycastle JARs break large-key crypto operations - The OpenNMS Issue Tracker

    opennms.org | 1 year ago
    javax.net.ssl.SSLException: java.lang.RuntimeException: Could not generate DH keypair
  6. 0

    When trying to use the {{org.opennms.core.web.HttpClientWrapper}} class to make an HTTPS client connection to a server supporting high-strength cipher suites, I get the following exception stack trace: {noformat} javax.net.ssl.SSLException: java.lang.RuntimeException: Could not generate DH keypair at sun.security.ssl.Alerts.getSSLException(Alerts.java:208) ~[?:1.8.0_65] at sun.security.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1949) ~[?:1.8.0_65] at sun.security.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1906) ~[?:1.8.0_65] at sun.security.ssl.SSLSocketImpl.handleException(SSLSocketImpl.java:1889) ~[?:1.8.0_65] at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1410) ~[?:1.8.0_65] at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1387) ~[?:1.8.0_65] at org.apache.http.conn.ssl.SSLConnectionSocketFactory.createLayeredSocket(SSLConnectionSocketFactory.java:290) ~[httpclient-4.3.6.jar:4.3.6] at org.apache.http.conn.ssl.SSLConnectionSocketFactory.connectSocket(SSLConnectionSocketFactory.java:259) ~[httpclient-4.3.6.jar:4.3.6] at org.apache.http.impl.conn.HttpClientConnectionOperator.connect(HttpClientConnectionOperator.java:125) ~[httpclient-4.3.6.jar:4.3.6] at org.apache.http.impl.conn.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:319) ~[httpclient-4.3.6.jar:4.3.6] at org.apache.http.impl.execchain.MainClientExec.establishRoute(MainClientExec.java:363) ~[httpclient-4.3.6.jar:4.3.6] at org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:219) ~[httpclient-4.3.6.jar:4.3.6] at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:195) ~[httpclient-4.3.6.jar:4.3.6] at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:86) ~[httpclient-4.3.6.jar:4.3.6] at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:108) ~[httpclient-4.3.6.jar:4.3.6] at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:184) ~[httpclient-4.3.6.jar:4.3.6] at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82) ~[httpclient-4.3.6.jar:4.3.6] at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:106) ~[httpclient-4.3.6.jar:4.3.6] at org.opennms.netmgt.notifd.MattermostNotificationStrategy.send(MattermostNotificationStrategy.java:111) [opennms-services-18.0.0-SNAPSHOT.jar:?] at org.opennms.netmgt.notifd.ClassExecutor.execute(ClassExecutor.java:69) [opennms-services-18.0.0-SNAPSHOT.jar:?] at org.opennms.netmgt.notifd.NotificationTask.run(NotificationTask.java:269) [opennms-services-18.0.0-SNAPSHOT.jar:?] Caused by: java.lang.RuntimeException: Could not generate DH keypair at sun.security.ssl.ECDHCrypt.<init>(ECDHCrypt.java:81) ~[?:1.8.0_65] at sun.security.ssl.ClientHandshaker.serverKeyExchange(ClientHandshaker.java:721) ~[?:1.8.0_65] at sun.security.ssl.ClientHandshaker.processMessage(ClientHandshaker.java:281) ~[?:1.8.0_65] at sun.security.ssl.Handshaker.processLoop(Handshaker.java:979) ~[?:1.8.0_65] at sun.security.ssl.Handshaker.process_record(Handshaker.java:914) ~[?:1.8.0_65] at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1062) ~[?:1.8.0_65] at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1375) ~[?:1.8.0_65] at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1403) ~[?:1.8.0_65] ... 16 more Caused by: java.security.InvalidAlgorithmParameterException: parameter object not a ECParameterSpec at org.bouncycastle.jce.provider.JDKKeyPairGenerator$EC.initialize(Unknown Source) ~[bcprov-jdk14-1.38.jar:1.38.0] at sun.security.ssl.ECDHCrypt.<init>(ECDHCrypt.java:76) ~[?:1.8.0_65] at sun.security.ssl.ClientHandshaker.serverKeyExchange(ClientHandshaker.java:721) ~[?:1.8.0_65] at sun.security.ssl.ClientHandshaker.processMessage(ClientHandshaker.java:281) ~[?:1.8.0_65] at sun.security.ssl.Handshaker.processLoop(Handshaker.java:979) ~[?:1.8.0_65] at sun.security.ssl.Handshaker.process_record(Handshaker.java:914) ~[?:1.8.0_65] at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1062) ~[?:1.8.0_65] at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1375) ~[?:1.8.0_65] at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1403) ~[?:1.8.0_65] ... 16 more {noformat} The bouncycastle JCE provider appears to be taking precedence over the JDK-provided one, resulting in this problem. Removing the {{bcprov}} JAR from OPENNMS_HOME/lib enables the connections to succeed. We appear to have picked up an undeclared dependency on the following artifacts from group {{bouncycastle}} * {{bcmail-jdk14}} * {{bcprov-jdk14}} * {{bctsp-jdk14}} We have existing exclusions in the {{dependencies/jasper}} POM for {{bcmail}} and {{bcprov}}. Somebody thought iText could be the culprit.

    The OpenNMS Issue Tracker | 1 year ago | Jeff Gehlbach
    javax.net.ssl.SSLException: java.lang.RuntimeException: Could not generate DH keypair

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.security.InvalidAlgorithmParameterException

      parameter object not a ECParameterSpec

      at org.bouncycastle.jce.provider.JDKKeyPairGenerator$EC.initialize()
    2. BouncyCastle
      JDKKeyPairGenerator$EC.initialize
      1. org.bouncycastle.jce.provider.JDKKeyPairGenerator$EC.initialize(Unknown Source)
      1 frame
    3. Java JSSE
      SSLSocketImpl.startHandshake
      1. sun.security.ssl.ECDHCrypt.<init>(ECDHCrypt.java:75)
      2. sun.security.ssl.ClientHandshaker.serverKeyExchange(ClientHandshaker.java:632)
      3. sun.security.ssl.ClientHandshaker.processMessage(ClientHandshaker.java:218)
      4. sun.security.ssl.Handshaker.processLoop(Handshaker.java:868)
      5. sun.security.ssl.Handshaker.process_record(Handshaker.java:804)
      6. sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1016)
      7. sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1312)
      8. sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1339)
      9. sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1323)
      9 frames
    4. Java RT
      HttpsURLConnectionImpl.getInputStream
      1. sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:563)
      2. sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:185)
      3. sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1300)
      4. sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:254)
      4 frames
    5. Xerces2-j
      DocumentBuilderImpl.parse
      1. org.apache.xerces.impl.XMLEntityManager.setupCurrentEntity(Unknown Source)
      2. org.apache.xerces.impl.XMLVersionDetector.determineDocVersion(Unknown Source)
      3. org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
      4. org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
      5. org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
      6. org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
      7. org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
      7 frames
    6. WSDL4J
      WSDLReaderImpl.readWSDL
      1. com.ibm.wsdl.xml.WSDLReaderImpl.getDocument(Unknown Source)
      2. com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)
      3. com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)
      3 frames
    7. Apache CXF Runtime Core for WSDL
      WSDLServiceFactory.<init>
      1. org.apache.cxf.wsdl11.WSDLManagerImpl.loadDefinition(WSDLManagerImpl.java:262)
      2. org.apache.cxf.wsdl11.WSDLManagerImpl.getDefinition(WSDLManagerImpl.java:205)
      3. org.apache.cxf.wsdl11.WSDLServiceFactory.<init>(WSDLServiceFactory.java:98)
      3 frames
    8. Apache CXF Runtime JAX-WS Frontend
      ProviderImpl.createServiceDelegate
      1. org.apache.cxf.jaxws.ServiceImpl.initializePorts(ServiceImpl.java:199)
      2. org.apache.cxf.jaxws.ServiceImpl.<init>(ServiceImpl.java:147)
      3. org.apache.cxf.jaxws.spi.ProviderImpl.createServiceDelegate(ProviderImpl.java:98)
      3 frames
    9. Java RT
      Service.<init>
      1. javax.xml.ws.Service.<init>(Service.java:77)
      1 frame
    10. org.oscarehr.myoscar_server
      LoginWsService.<init>
      1. org.oscarehr.myoscar_server.ws.LoginWsService.<init>(Unknown Source)
      1 frame
    11. org.oscarehr.myoscar
      AccountManager.login
      1. org.oscarehr.myoscar.client.ws_manager.MyOscarServerWebServicesManager.getLoginWs(MyOscarServerWebServicesManager.java:125)
      2. org.oscarehr.myoscar.client.ws_manager.AccountManager.login(AccountManager.java:163)
      2 frames
    12. org.oscarehr.phr
      MyOscarUtils$1.run
      1. org.oscarehr.phr.util.MyOscarUtils.attemptMyOscarAutoLoginIfNotAlreadyLoggedIn(MyOscarUtils.java:173)
      2. org.oscarehr.phr.util.MyOscarUtils$1.run(MyOscarUtils.java:121)
      2 frames
    13. Java RT
      Thread.run
      1. java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
      2. java.util.concurrent.FutureTask.run(FutureTask.java:262)
      3. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      4. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      5. java.lang.Thread.run(Thread.java:745)
      5 frames