Author: shawkins
Date: 2011-11-10 13:16:54 -0500 (Thu, 10 Nov 2011)
New Revision: 3632
Added:
trunk/client/src/main/java/org/teiid/net/socket/AuthenticationType.java
Modified:
trunk/client/src/main/java/org/teiid/jdbc/JDBCURL.java
trunk/client/src/main/java/org/teiid/jdbc/TeiidDataSource.java
trunk/client/src/main/java/org/teiid/net/TeiidURL.java
trunk/client/src/main/java/org/teiid/net/socket/Handshake.java
trunk/client/src/main/java/org/teiid/net/socket/SocketServerConnection.java
trunk/client/src/main/java/org/teiid/net/socket/SocketServerInstance.java
trunk/client/src/main/java/org/teiid/net/socket/SocketServerInstanceImpl.java
trunk/client/src/test/java/org/teiid/jdbc/TestTeiidDriver.java
trunk/client/src/test/java/org/teiid/net/socket/TestSocketServerConnection.java
trunk/documentation/client-developers-guide/src/main/docbook/en-US/content/jdbc-connection.xml
trunk/engine/src/main/java/org/teiid/dqp/service/SessionService.java
trunk/jboss-integration/src/main/java/org/teiid/jboss/deployers/RuntimeEngineDeployer.java
trunk/runtime/src/main/java/org/teiid/odbc/ODBCServerRemoteImpl.java
trunk/runtime/src/main/java/org/teiid/services/SessionServiceImpl.java
trunk/runtime/src/main/java/org/teiid/transport/ClientServiceRegistry.java
trunk/runtime/src/main/java/org/teiid/transport/ClientServiceRegistryImpl.java
trunk/runtime/src/main/java/org/teiid/transport/LogonImpl.java
trunk/runtime/src/main/java/org/teiid/transport/ODBCClientInstance.java
trunk/runtime/src/main/java/org/teiid/transport/ODBCSocketListener.java
trunk/runtime/src/main/java/org/teiid/transport/SocketClientInstance.java
trunk/runtime/src/test/java/org/teiid/transport/TestLogonImpl.java
Log:
TEIID-1610 removing the need for the client to set the auth type property
Modified: trunk/client/src/main/java/org/teiid/jdbc/JDBCURL.java
===================================================================
--- trunk/client/src/main/java/org/teiid/jdbc/JDBCURL.java 2011-11-10 17:48:21 UTC (rev
3631)
+++ trunk/client/src/main/java/org/teiid/jdbc/JDBCURL.java 2011-11-10 18:16:54 UTC (rev
3632)
@@ -74,7 +74,6 @@
TeiidURL.CONNECTION.AUTO_FAILOVER,
TeiidURL.CONNECTION.DISCOVERY_STRATEGY,
TeiidURL.CONNECTION.PASSTHROUGH_AUTHENTICATION,
- TeiidURL.CONNECTION.AUTHENTICATION_TYPE,
TeiidURL.CONNECTION.JAAS_NAME,
TeiidURL.CONNECTION.KERBEROS_SERVICE_PRINCIPLE_NAME));
props.addAll(EXECUTION_PROPERTIES);
Modified: trunk/client/src/main/java/org/teiid/jdbc/TeiidDataSource.java
===================================================================
--- trunk/client/src/main/java/org/teiid/jdbc/TeiidDataSource.java 2011-11-10 17:48:21 UTC
(rev 3631)
+++ trunk/client/src/main/java/org/teiid/jdbc/TeiidDataSource.java 2011-11-10 18:16:54 UTC
(rev 3632)
@@ -99,11 +99,6 @@
private boolean passthroughAuthentication = false;
/**
- * Authentication type to used from client. choices are simple - which is plain
user/password; krb5 - kerberos
- */
- private String authenticationType;
-
- /**
* Name of the jass configuration to use from the
-Djava.security.auth.login.config=login.conf property
*/
private String jaasName;
@@ -258,9 +253,6 @@
Properties props = buildProperties(userName, password);
props.setProperty(TeiidURL.CONNECTION.PASSTHROUGH_AUTHENTICATION,
Boolean.toString(this.passthroughAuthentication));
- if (getAuthenticationType() != null) {
- props.setProperty(TeiidURL.CONNECTION.AUTHENTICATION_TYPE, getAuthenticationType());
- }
if (getJaasName() != null) {
props.setProperty(TeiidURL.CONNECTION.JAAS_NAME, getJaasName());
}
@@ -492,24 +484,7 @@
this.passthroughAuthentication = passthroughAuthentication;
}
- /**
- * Authentication Type {simple, krb5} default:simple
- * @return
- */
- public String getAuthenticationType() {
- return authenticationType;
- }
-
/**
- * Authentication Type.
- * @since 7.6
- * @return
- */
- public void setAuthenticationType(final String authType) {
- this.authenticationType = authType;
- }
-
- /**
* Application name from JAAS Login Config file
* @since 7.6
* @return
Modified: trunk/client/src/main/java/org/teiid/net/TeiidURL.java
===================================================================
--- trunk/client/src/main/java/org/teiid/net/TeiidURL.java 2011-11-10 17:48:21 UTC (rev
3631)
+++ trunk/client/src/main/java/org/teiid/net/TeiidURL.java 2011-11-10 18:16:54 UTC (rev
3632)
@@ -83,15 +83,9 @@
public static final String PASSTHROUGH_AUTHENTICATION =
"PassthroughAuthentication"; //$NON-NLS-1$
- public static final String AUTHENTICATION_TYPE = "authenticationType";
//$NON-NLS-1$
-
public static final String JAAS_NAME = "jaasName"; //$NON-NLS-1$
- public static final String KERBEROS_SERVICE_PRINCIPLE_NAME =
"kerberosServicePrincipleName"; //$NON-NLS-1$
-
- public enum AuthenticationType {
- CLEARTEXT,GSS
- };
+ public static final String KERBEROS_SERVICE_PRINCIPLE_NAME =
"kerberosServicePrincipleName"; //$NON-NLS-1$;
}
public static final String DOT_DELIMITER = "."; //$NON-NLS-1$
Added: trunk/client/src/main/java/org/teiid/net/socket/AuthenticationType.java
===================================================================
--- trunk/client/src/main/java/org/teiid/net/socket/AuthenticationType.java
(rev 0)
+++ trunk/client/src/main/java/org/teiid/net/socket/AuthenticationType.java 2011-11-10
18:16:54 UTC (rev 3632)
@@ -0,0 +1,27 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * See the COPYRIGHT.txt file distributed with this work for information
+ * regarding copyright ownership. Some portions may be licensed
+ * to Red Hat, Inc. under one or more contributor license agreements.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA.
+ */
+
+package org.teiid.net.socket;
+
+public enum AuthenticationType {
+ CLEARTEXT,GSS
+}
\ No newline at end of file
Property changes on:
trunk/client/src/main/java/org/teiid/net/socket/AuthenticationType.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified: trunk/client/src/main/java/org/teiid/net/socket/Handshake.java
===================================================================
--- trunk/client/src/main/java/org/teiid/net/socket/Handshake.java 2011-11-10 17:48:21 UTC
(rev 3631)
+++ trunk/client/src/main/java/org/teiid/net/socket/Handshake.java 2011-11-10 18:16:54 UTC
(rev 3632)
@@ -26,6 +26,7 @@
import java.io.IOException;
import java.io.ObjectInput;
import java.io.ObjectOutput;
+import java.io.OptionalDataException;
import org.teiid.core.util.ApplicationInfo;
@@ -39,6 +40,7 @@
private String version = ApplicationInfo.getInstance().getReleaseNumber();
private byte[] publicKey;
+ private AuthenticationType authType = AuthenticationType.CLEARTEXT;
/**
* @return Returns the version.
@@ -68,17 +70,31 @@
this.publicKey = key;
}
+ public AuthenticationType getAuthType() {
+ return authType;
+ }
+
+ public void setAuthType(AuthenticationType authType) {
+ this.authType = authType;
+ }
+
@Override
public void readExternal(ObjectInput in) throws IOException,
ClassNotFoundException {
version = (String)in.readObject();
publicKey = (byte[])in.readObject();
+ try {
+ authType = AuthenticationType.values()[in.readByte()];
+ } catch (OptionalDataException e) {
+
+ }
}
@Override
public void writeExternal(ObjectOutput out) throws IOException {
out.writeObject(version);
out.writeObject(publicKey);
+ out.writeByte(authType.ordinal());
}
}
Modified: trunk/client/src/main/java/org/teiid/net/socket/SocketServerConnection.java
===================================================================
--- trunk/client/src/main/java/org/teiid/net/socket/SocketServerConnection.java 2011-11-10
17:48:21 UTC (rev 3631)
+++ trunk/client/src/main/java/org/teiid/net/socket/SocketServerConnection.java 2011-11-10
18:16:54 UTC (rev 3632)
@@ -56,7 +56,6 @@
import org.teiid.net.HostInfo;
import org.teiid.net.ServerConnection;
import org.teiid.net.TeiidURL;
-import org.teiid.net.TeiidURL.CONNECTION.AuthenticationType;
/**
@@ -172,7 +171,7 @@
SocketServerInstance instance = this.serverInstance;
LogonResult newResult = null;
- AuthenticationType authType = getAuthenticationType();
+ AuthenticationType authType = instance.getAuthenticationType();
if (AuthenticationType.CLEARTEXT.equals(authType)) {
newResult = newLogon.logon(connProps);
}
@@ -194,14 +193,6 @@
this.connectionFactory.connected(instance, this.logonResult.getSessionToken());
}
- private AuthenticationType getAuthenticationType() {
- String authStr = this.connProps.getProperty(TeiidURL.CONNECTION.AUTHENTICATION_TYPE);
- if (authStr == null) {
- return AuthenticationType.CLEARTEXT;
- }
- return AuthenticationType.valueOf(authStr);
- }
-
private ILogon connect(HostInfo hostInfo) throws CommunicationException,
IOException {
hostInfo.setSsl(secure);
Modified: trunk/client/src/main/java/org/teiid/net/socket/SocketServerInstance.java
===================================================================
--- trunk/client/src/main/java/org/teiid/net/socket/SocketServerInstance.java 2011-11-10
17:48:21 UTC (rev 3631)
+++ trunk/client/src/main/java/org/teiid/net/socket/SocketServerInstance.java 2011-11-10
18:16:54 UTC (rev 3632)
@@ -53,4 +53,6 @@
String getServerVersion();
+ AuthenticationType getAuthenticationType();
+
}
\ No newline at end of file
Modified: trunk/client/src/main/java/org/teiid/net/socket/SocketServerInstanceImpl.java
===================================================================
---
trunk/client/src/main/java/org/teiid/net/socket/SocketServerInstanceImpl.java 2011-11-10
17:48:21 UTC (rev 3631)
+++
trunk/client/src/main/java/org/teiid/net/socket/SocketServerInstanceImpl.java 2011-11-10
18:16:54 UTC (rev 3632)
@@ -76,6 +76,7 @@
private ObjectChannel socketChannel;
private Cryptor cryptor;
private String serverVersion;
+ private AuthenticationType authType = AuthenticationType.CLEARTEXT;
private boolean hasReader;
@@ -130,6 +131,7 @@
throw new
CommunicationException(NetPlugin.Util.getString("SocketServerInstanceImpl.version_mismatch",
getVersionInfo(), handshake.getVersion())); //$NON-NLS-1$
}*/
serverVersion = handshake.getVersion();
+ authType = handshake.getAuthType();
handshake.setVersion();
byte[] serverPublicKey = handshake.getPublicKey();
@@ -369,4 +371,9 @@
}
+ @Override
+ public AuthenticationType getAuthenticationType() {
+ return authType;
+ }
+
}
\ No newline at end of file
Modified: trunk/client/src/test/java/org/teiid/jdbc/TestTeiidDriver.java
===================================================================
--- trunk/client/src/test/java/org/teiid/jdbc/TestTeiidDriver.java 2011-11-10 17:48:21 UTC
(rev 3631)
+++ trunk/client/src/test/java/org/teiid/jdbc/TestTeiidDriver.java 2011-11-10 18:16:54 UTC
(rev 3632)
@@ -138,7 +138,7 @@
@Test public void testGetPropertyInfo1() throws Exception {
DriverPropertyInfo info[] =
drv.getPropertyInfo("jdbc:teiid:vdb@mm://localhost:12345;applicationName=x",
null); //$NON-NLS-1$
- assertEquals(24, info.length);
+ assertEquals(23, info.length);
assertEquals(false, info[0].required);
assertEquals("ApplicationName", info[0].name); //$NON-NLS-1$
assertEquals("x", info[0].value); //$NON-NLS-1$
Modified: trunk/client/src/test/java/org/teiid/net/socket/TestSocketServerConnection.java
===================================================================
---
trunk/client/src/test/java/org/teiid/net/socket/TestSocketServerConnection.java 2011-11-10
17:48:21 UTC (rev 3631)
+++
trunk/client/src/test/java/org/teiid/net/socket/TestSocketServerConnection.java 2011-11-10
18:16:54 UTC (rev 3632)
@@ -213,6 +213,7 @@
Mockito.stub(instance.getHostInfo()).toReturn(hostInfo);
Mockito.stub(instance.getService(ILogon.class)).toReturn(logon);
Mockito.stub(instance.getServerVersion()).toReturn("7.3");
+ Mockito.stub(instance.getAuthenticationType()).toReturn(AuthenticationType.CLEARTEXT);
if (t != null) {
try {
Mockito.doAnswer(new Answer<Void>() {
Modified:
trunk/documentation/client-developers-guide/src/main/docbook/en-US/content/jdbc-connection.xml
===================================================================
---
trunk/documentation/client-developers-guide/src/main/docbook/en-US/content/jdbc-connection.xml 2011-11-10
17:48:21 UTC (rev 3631)
+++
trunk/documentation/client-developers-guide/src/main/docbook/en-US/content/jdbc-connection.xml 2011-11-10
18:16:54 UTC (rev 3632)
@@ -258,27 +258,14 @@
</row>
<row>
<entry>
- <code>authenticationType</code>
- </entry>
- <entry>
- <code>String</code>
- </entry>
- <entry>
- <para>Type of authentication to use. Valid values are
CLEARTEXT (default) and KRB5 (kerberos). See
- Admin Guide for configuration required for kerberos
- </para>
- </entry>
- </row>
- <row>
- <entry>
<code>jaasName</code>
</entry>
<entry>
<code>String</code>
</entry>
<entry>
- <para>JAAS configuration name. Only applies when
configuring a kerberos authentication.
- See Admin Guide for configuration required for
kerberos</para>
+ <para>JAAS configuration name. Only applies when
configuring a GSS authentication.
+ See the Admin Guide for configuration required for
GSS.</para>
</entry>
</row>
<row>
@@ -289,8 +276,8 @@
<code>String</code>
</entry>
<entry>
- <para>Kerberos authenticated principle name. Only
applies when configuring a kerberos authentication.
- See Admin Guide for configuration required for
kerberos</para>
+ <para>Kerberos authenticated principle name. Only
applies when configuring a GSS authentication.
+ See the Admin Guide for configuration required for
GSS</para>
</entry>
</row>
Modified: trunk/engine/src/main/java/org/teiid/dqp/service/SessionService.java
===================================================================
--- trunk/engine/src/main/java/org/teiid/dqp/service/SessionService.java 2011-11-10
17:48:21 UTC (rev 3631)
+++ trunk/engine/src/main/java/org/teiid/dqp/service/SessionService.java 2011-11-10
18:16:54 UTC (rev 3632)
@@ -32,7 +32,7 @@
import org.teiid.adminapi.impl.SessionMetadata;
import org.teiid.client.security.InvalidSessionException;
import org.teiid.dqp.internal.process.DQPCore;
-import org.teiid.net.TeiidURL.CONNECTION.AuthenticationType;
+import org.teiid.net.socket.AuthenticationType;
import org.teiid.security.Credentials;
Modified:
trunk/jboss-integration/src/main/java/org/teiid/jboss/deployers/RuntimeEngineDeployer.java
===================================================================
---
trunk/jboss-integration/src/main/java/org/teiid/jboss/deployers/RuntimeEngineDeployer.java 2011-11-10
17:48:21 UTC (rev 3631)
+++
trunk/jboss-integration/src/main/java/org/teiid/jboss/deployers/RuntimeEngineDeployer.java 2011-11-10
18:16:54 UTC (rev 3632)
@@ -113,6 +113,7 @@
import org.teiid.metadata.TableStats;
import org.teiid.metadata.Table.TriggerEvent;
import org.teiid.net.TeiidURL;
+import org.teiid.net.socket.AuthenticationType;
import org.teiid.query.ObjectReplicator;
import org.teiid.query.metadata.TransformationMetadata;
import org.teiid.query.optimizer.relational.RelationalPlanner;
@@ -230,6 +231,7 @@
this.csr.registerClientService(Admin.class, adminProxy,
LogConstants.CTX_ADMIN_API);
ClientServiceRegistryImpl jdbcCsr = new ClientServiceRegistryImpl();
+ jdbcCsr.setAuthenticationType(this.sessionService.getAuthType());
jdbcCsr.registerClientService(ILogon.class, logon, LogConstants.CTX_SECURITY);
jdbcCsr.registerClientService(DQP.class, dqpProxy, LogConstants.CTX_DQP);
@@ -241,6 +243,7 @@
}
ClientServiceRegistryImpl adminCsr = new ClientServiceRegistryImpl(Type.Admin);
+ adminCsr.setAuthenticationType(this.sessionService.getAuthType());
adminCsr.registerClientService(ILogon.class, logon, LogConstants.CTX_SECURITY);
adminCsr.registerClientService(Admin.class, adminProxy,
LogConstants.CTX_ADMIN_API);
@@ -857,4 +860,9 @@
*/
public void setContainerLifeCycleListener(ContainerLifeCycleListener listener) {
}
+
+ @Override
+ public AuthenticationType getAuthenticationType() {
+ return this.sessionService.getAuthType();
+ }
}
Modified: trunk/runtime/src/main/java/org/teiid/odbc/ODBCServerRemoteImpl.java
===================================================================
--- trunk/runtime/src/main/java/org/teiid/odbc/ODBCServerRemoteImpl.java 2011-11-10
17:48:21 UTC (rev 3631)
+++ trunk/runtime/src/main/java/org/teiid/odbc/ODBCServerRemoteImpl.java 2011-11-10
18:16:54 UTC (rev 3632)
@@ -54,7 +54,7 @@
import org.teiid.jdbc.TeiidDriver;
import org.teiid.logging.LogConstants;
import org.teiid.logging.LogManager;
-import org.teiid.net.TeiidURL.CONNECTION.AuthenticationType;
+import org.teiid.net.socket.AuthenticationType;
import org.teiid.odbc.PGUtil.PgColInfo;
import org.teiid.query.parser.SQLParserUtil;
import org.teiid.runtime.RuntimePlugin;
Modified: trunk/runtime/src/main/java/org/teiid/services/SessionServiceImpl.java
===================================================================
--- trunk/runtime/src/main/java/org/teiid/services/SessionServiceImpl.java 2011-11-10
17:48:21 UTC (rev 3631)
+++ trunk/runtime/src/main/java/org/teiid/services/SessionServiceImpl.java 2011-11-10
18:16:54 UTC (rev 3632)
@@ -63,7 +63,7 @@
import org.teiid.logging.LogManager;
import org.teiid.net.ServerConnection;
import org.teiid.net.TeiidURL;
-import org.teiid.net.TeiidURL.CONNECTION.AuthenticationType;
+import org.teiid.net.socket.AuthenticationType;
import org.teiid.runtime.RuntimePlugin;
import org.teiid.security.Credentials;
import org.teiid.security.SecurityHelper;
Modified: trunk/runtime/src/main/java/org/teiid/transport/ClientServiceRegistry.java
===================================================================
--- trunk/runtime/src/main/java/org/teiid/transport/ClientServiceRegistry.java 2011-11-10
17:48:21 UTC (rev 3631)
+++ trunk/runtime/src/main/java/org/teiid/transport/ClientServiceRegistry.java 2011-11-10
18:16:54 UTC (rev 3632)
@@ -23,6 +23,7 @@
package org.teiid.transport;
import org.teiid.core.ComponentNotFoundException;
+import org.teiid.net.socket.AuthenticationType;
import org.teiid.security.SecurityHelper;
@@ -35,5 +36,7 @@
<T> T getClientService(Class<T> iface) throws ComponentNotFoundException;
SecurityHelper getSecurityHelper();
+
+ AuthenticationType getAuthenticationType();
}
Modified: trunk/runtime/src/main/java/org/teiid/transport/ClientServiceRegistryImpl.java
===================================================================
---
trunk/runtime/src/main/java/org/teiid/transport/ClientServiceRegistryImpl.java 2011-11-10
17:48:21 UTC (rev 3631)
+++
trunk/runtime/src/main/java/org/teiid/transport/ClientServiceRegistryImpl.java 2011-11-10
18:16:54 UTC (rev 3632)
@@ -26,6 +26,7 @@
import org.teiid.core.ComponentNotFoundException;
import org.teiid.core.util.ReflectionHelper;
+import org.teiid.net.socket.AuthenticationType;
import org.teiid.runtime.RuntimePlugin;
import org.teiid.security.SecurityHelper;
@@ -58,6 +59,7 @@
private HashMap<String, ClientService> clientServices = new HashMap<String,
ClientService>();
private SecurityHelper securityHelper;
private Type type = Type.JDBC;
+ private AuthenticationType authenticationType = AuthenticationType.CLEARTEXT;
public ClientServiceRegistryImpl() {
@@ -66,6 +68,10 @@
public ClientServiceRegistryImpl(Type type) {
this.type = type;
}
+
+ public void setAuthenticationType(AuthenticationType authenticationType) {
+ this.authenticationType = authenticationType;
+ }
public <T> T getClientService(Class<T> iface) throws
ComponentNotFoundException {
ClientService cs = getClientService(iface.getName());
@@ -92,5 +98,10 @@
public void setSecurityHelper(SecurityHelper securityHelper) {
this.securityHelper = securityHelper;
}
+
+ @Override
+ public AuthenticationType getAuthenticationType() {
+ return authenticationType;
+ }
}
Modified: trunk/runtime/src/main/java/org/teiid/transport/LogonImpl.java
===================================================================
--- trunk/runtime/src/main/java/org/teiid/transport/LogonImpl.java 2011-11-10 17:48:21 UTC
(rev 3631)
+++ trunk/runtime/src/main/java/org/teiid/transport/LogonImpl.java 2011-11-10 18:16:54 UTC
(rev 3632)
@@ -50,7 +50,7 @@
import org.teiid.logging.LogManager;
import org.teiid.net.CommunicationException;
import org.teiid.net.TeiidURL;
-import org.teiid.net.TeiidURL.CONNECTION.AuthenticationType;
+import org.teiid.net.socket.AuthenticationType;
import org.teiid.runtime.RuntimePlugin;
import org.teiid.security.Credentials;
Modified: trunk/runtime/src/main/java/org/teiid/transport/ODBCClientInstance.java
===================================================================
--- trunk/runtime/src/main/java/org/teiid/transport/ODBCClientInstance.java 2011-11-10
17:48:21 UTC (rev 3631)
+++ trunk/runtime/src/main/java/org/teiid/transport/ODBCClientInstance.java 2011-11-10
18:16:54 UTC (rev 3632)
@@ -36,7 +36,7 @@
import org.teiid.logging.LogManager;
import org.teiid.logging.MessageLevel;
import org.teiid.net.CommunicationException;
-import org.teiid.net.TeiidURL.CONNECTION.AuthenticationType;
+import org.teiid.net.socket.AuthenticationType;
import org.teiid.net.socket.ObjectChannel;
import org.teiid.net.socket.ServiceInvocationStruct;
import org.teiid.odbc.ODBCClientRemote;
Modified: trunk/runtime/src/main/java/org/teiid/transport/ODBCSocketListener.java
===================================================================
--- trunk/runtime/src/main/java/org/teiid/transport/ODBCSocketListener.java 2011-11-10
17:48:21 UTC (rev 3631)
+++ trunk/runtime/src/main/java/org/teiid/transport/ODBCSocketListener.java 2011-11-10
18:16:54 UTC (rev 3632)
@@ -26,7 +26,7 @@
import org.teiid.client.security.ILogon;
import org.teiid.common.buffer.StorageManager;
import org.teiid.jdbc.TeiidDriver;
-import org.teiid.net.TeiidURL.CONNECTION.AuthenticationType;
+import org.teiid.net.socket.AuthenticationType;
import org.teiid.net.socket.ObjectChannel;
public class ODBCSocketListener extends SocketListener {
Modified: trunk/runtime/src/main/java/org/teiid/transport/SocketClientInstance.java
===================================================================
--- trunk/runtime/src/main/java/org/teiid/transport/SocketClientInstance.java 2011-11-10
17:48:21 UTC (rev 3631)
+++ trunk/runtime/src/main/java/org/teiid/transport/SocketClientInstance.java 2011-11-10
18:16:54 UTC (rev 3632)
@@ -95,7 +95,7 @@
public void onConnection() throws CommunicationException {
Handshake handshake = new Handshake();
-
+ handshake.setAuthType(csr.getAuthenticationType());
if (usingEncryption) {
keyGen = new DhKeyGenerator();
byte[] publicKey;
Modified: trunk/runtime/src/test/java/org/teiid/transport/TestLogonImpl.java
===================================================================
--- trunk/runtime/src/test/java/org/teiid/transport/TestLogonImpl.java 2011-11-10 17:48:21
UTC (rev 3631)
+++ trunk/runtime/src/test/java/org/teiid/transport/TestLogonImpl.java 2011-11-10 18:16:54
UTC (rev 3632)
@@ -34,7 +34,7 @@
import org.teiid.dqp.internal.process.DQPWorkContext;
import org.teiid.dqp.service.SessionService;
import org.teiid.net.TeiidURL;
-import org.teiid.net.TeiidURL.CONNECTION.AuthenticationType;
+import org.teiid.net.socket.AuthenticationType;
public class TestLogonImpl extends TestCase {