<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<body link="#355491" alink="#4262a1" vlink="#355491" style="background: #e2e2e2; margin: 0; padding: 20px;">

<div>
        <table cellpadding="0" bgcolor="#FFFFFF" border="0" cellspacing="0" style="border: 1px solid #dadada; margin-bottom: 30px; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                <tbody>
                        <tr>

                                <td>

                                        <table border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" style="border: solid 2px #ccc; background: #dadada; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                                                <tbody>
                                                        <tr>
                                                                <td bgcolor="#000000" valign="middle" height="58px" style="border-bottom: 1px solid #ccc; padding: 20px; -moz-border-radius-topleft: 3px; -moz-border-radius-topright: 3px; -webkit-border-top-right-radius: 5px; -webkit-border-top-left-radius: 5px;">
                                                                        <h1 style="color: #333333; font: bold 22px Arial, Helvetica, sans-serif; margin: 0; display: block !important;">
                                                                        <!-- To have a header image/logo replace the name below with your img tag -->
                                                                        <!-- Email clients will render the images when the message is read so any image -->
                                                                        <!-- must be made available on a public server, so that all recipients can load the image. -->
                                                                        <a href="https://community.jboss.org/index.jspa" style="text-decoration: none; color: #E1E1E1">JBoss Community</a></h1>
                                                                </td>

                                                        </tr>
                                                        <tr>
                                                                <td bgcolor="#FFFFFF" style="font: normal 12px Arial, Helvetica, sans-serif; color:#333333; padding: 20px;  -moz-border-radius-bottomleft: 4px; -moz-border-radius-bottomright: 4px; -webkit-border-bottom-right-radius: 5px; -webkit-border-bottom-left-radius: 5px;"><h3 style="margin: 10px 0 5px; font-size: 17px; font-weight: normal;">
    MSSQL Server datasource cause exception whenever one start up the server
</h3>
<span style="margin-bottom: 10px;">
    created by <a href="https://community.jboss.org/people/gmlopezdev">Guillermo López</a> in <i>JBoss Tools</i> - <a href="https://community.jboss.org/message/798971#798971">View the full discussion</a>
</span>
<hr style="margin: 20px 0; border: none; background-color: #dadada; height: 1px;">

<div class="jive-rendered-content"><p>I have an issue whenever I try to startup the AS7 runtime from eclipse servers view. I've setup an mssql server datasource and it throws an ssl exception. The server is not configured to require ssl. This does not happen when I start it up from command line by issueing a standalone.bat.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>Any ideas??? </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>The exception I get is as the following:</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>java.ext.dirs: C:\Program Files\Java\jdk1.7.0_13\jre\lib\ext;C:\Windows\Sun\Java\lib\ext</p><p>20:01:57,191 WARN&#160; [org.hibernate.engine.jdbc.internal.JdbcServicesImpl] (MSC service thread 1-7) HHH000342: Could not obtain connection to query metadata : javax.resource.ResourceException: IJ000453: Unable to get managed connection for java:jboss/datasources/gisDS</p><p>20:01:57,204 INFO&#160; [org.hibernate.dialect.Dialect] (MSC service thread 1-7) HHH000400: Using dialect: org.hibernate.dialect.SQLServerDialect</p><p>20:01:57,199 WARN&#160; [org.jboss.jca.core.connectionmanager.pool.strategy.OnePool] (MSC service thread 1-3) IJ000604: Throwable while attempting to get a new connection: null: javax.resource.ResourceException: Could not create connection</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.jca.adapters.jdbc.local.LocalManagedConnectionFactory.getLocalManagedConnection(LocalManagedConnectionFactory.java:277)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.jca.adapters.jdbc.local.LocalManagedConnectionFactory.createManagedConnection(LocalManagedConnectionFactory.java:235)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.jca.core.connectionmanager.pool.mcp.SemaphoreArrayListManagedConnectionPool.createConnectionEventListener(SemaphoreArrayListManagedConnectionPool.java:761)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.jca.core.connectionmanager.pool.mcp.SemaphoreArrayListManagedConnectionPool.getConnection(SemaphoreArrayListManagedConnectionPool.java:343)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.jca.core.connectionmanager.pool.AbstractPool.getSimpleConnection(AbstractPool.java:397)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.jca.core.connectionmanager.pool.AbstractPool.getConnection(AbstractPool.java:365)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.jca.core.connectionmanager.AbstractConnectionManager.getManagedConnection(AbstractConnectionManager.java:329)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.jca.core.connectionmanager.tx.TxConnectionManagerImpl.getManagedConnection(TxConnectionManagerImpl.java:368)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.jca.core.connectionmanager.AbstractConnectionManager.allocateConnection(AbstractConnectionManager.java:464)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.jca.adapters.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:129)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.hibernate.ejb.connection.InjectedDataSourceConnectionProvider.getConnection(InjectedDataSourceConnectionProvider.java:67) [hibernate-entitymanager-4.0.1.Final.jar:4.0.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.hibernate.engine.jdbc.internal.JdbcServicesImpl$ConnectionProviderJdbcConnectionAccess.obtainConnection(JdbcServicesImpl.java:253) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.hibernate.engine.jdbc.internal.JdbcServicesImpl.configure(JdbcServicesImpl.java:119) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.hibernate.service.internal.StandardServiceRegistryImpl.configureService(StandardServiceRegistryImpl.java:75) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService(AbstractServiceRegistryImpl.java:159) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService(AbstractServiceRegistryImpl.java:131) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.hibernate.cfg.SettingsFactory.buildSettings(SettingsFactory.java:71) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.hibernate.cfg.Configuration.buildSettingsInternal(Configuration.java:2270) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.hibernate.cfg.Configuration.buildSettings(Configuration.java:2266) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1735) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.hibernate.ejb.EntityManagerFactoryImpl.&lt;init&gt;(EntityManagerFactoryImpl.java:84) [hibernate-entitymanager-4.0.1.Final.jar:4.0.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:904) [hibernate-entitymanager-4.0.1.Final.jar:4.0.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:889) [hibernate-entitymanager-4.0.1.Final.jar:4.0.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.hibernate.ejb.HibernatePersistence.createContainerEntityManagerFactory(HibernatePersistence.java:73) [hibernate-entitymanager-4.0.1.Final.jar:4.0.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.as.jpa.service.PersistenceUnitServiceImpl.createContainerEntityManagerFactory(PersistenceUnitServiceImpl.java:162) [jboss-as-jpa-7.1.1.Final.jar:7.1.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.as.jpa.service.PersistenceUnitServiceImpl.start(PersistenceUnitServiceImpl.java:85) [jboss-as-jpa-7.1.1.Final.jar:7.1.1.Final]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) [rt.jar:1.7.0_13]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [rt.jar:1.7.0_13]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at java.lang.Thread.run(Unknown Source) [rt.jar:1.7.0_13]</p><p>Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: The driver could not establish a secure connection to SQL Server by using Secure Sockets Layer (SSL) encryption. Error: "RSA premaster secret error". ClientConnectionId:98e0dfa4-42e8-42a1-8d37-c0f8ec7098e1</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at com.microsoft.sqlserver.jdbc.SQLServerConnection.terminate(SQLServerConnection.java:1667)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at com.microsoft.sqlserver.jdbc.TDSChannel.enableSSL(IOBuffer.java:1668)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at com.microsoft.sqlserver.jdbc.SQLServerConnection.connectHelper(SQLServerConnection.java:1323)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at com.microsoft.sqlserver.jdbc.SQLServerConnection.login(SQLServerConnection.java:991)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at com.microsoft.sqlserver.jdbc.SQLServerConnection.connect(SQLServerConnection.java:827)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at com.microsoft.sqlserver.jdbc.SQLServerDriver.connect(SQLServerDriver.java:1012)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at org.jboss.jca.adapters.jdbc.local.LocalManagedConnectionFactory.getLocalManagedConnection(LocalManagedConnectionFactory.java:249)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;... 30 more</p><p>Caused by: javax.net.ssl.SSLKeyException: RSA premaster secret error</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at sun.security.ssl.RSAClientKeyExchange.&lt;init&gt;(Unknown Source) [jsse.jar:1.7.0_13]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at sun.security.ssl.ClientHandshaker.serverHelloDone(Unknown Source) [jsse.jar:1.7.0_13]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at sun.security.ssl.ClientHandshaker.processMessage(Unknown Source) [jsse.jar:1.7.0_13]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at sun.security.ssl.Handshaker.processLoop(Unknown Source) [jsse.jar:1.7.0_13]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at sun.security.ssl.Handshaker.process_record(Unknown Source) [jsse.jar:1.7.0_13]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at sun.security.ssl.SSLSocketImpl.readRecord(Unknown Source) [jsse.jar:1.7.0_13]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at sun.security.ssl.SSLSocketImpl.performInitialHandshake(Unknown Source) [jsse.jar:1.7.0_13]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source) [jsse.jar:1.7.0_13]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source) [jsse.jar:1.7.0_13]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at com.microsoft.sqlserver.jdbc.TDSChannel.enableSSL(IOBuffer.java:1618)</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;... 35 more</p><p>Caused by: java.security.NoSuchAlgorithmException: SunTlsRsaPremasterSecret KeyGenerator not available</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at javax.crypto.KeyGenerator.&lt;init&gt;(KeyGenerator.java:158) [jce.jar:1.7.0_10]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at javax.crypto.KeyGenerator.getInstance(KeyGenerator.java:207) [jce.jar:1.7.0_10]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;at sun.security.ssl.JsseJce.getKeyGenerator(Unknown Source) [jsse.jar:1.7.0_13]</p><p>&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;... 45 more</p></div>

<div style="background-color: #f4f4f4; padding: 10px; margin-top: 20px;">
    <p style="margin: 0;">Reply to this message by <a href="https://community.jboss.org/message/798971#798971">going to Community</a></p>
        <p style="margin: 0;">Start a new discussion in JBoss Tools at <a href="https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2128">Community</a></p>
</div></td>
                        </tr>
                    </tbody>
                </table>


                </td>
            </tr>
        </tbody>
    </table>

</div>

</body>
</html>