db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kmars...@apache.org
Subject svn commit: r1336268 - in /db/derby/code/trunk/java: drda/org/apache/derby/impl/drda/ drda/org/apache/derby/loc/drda/ engine/org/apache/derby/iapi/reference/ testing/org/apache/derbyTesting/functionTests/tests/derbynet/
Date Wed, 09 May 2012 16:11:08 GMT
Author: kmarsden
Date: Wed May  9 16:11:08 2012
New Revision: 1336268

URL: http://svn.apache.org/viewvc?rev=1336268&view=rev
Log:
DERBY-5565 Network Server should reject client connections that are not Derby  Network Client.

We now reject all PRDID's that do not start with DNC.
The protocol tests have been changed to use the DNC10090 PRDID instead of TST01000. This actually
alters the code path where there is slightly different behavior in later derby client versions,
so that we have to skip an additional dss on connect for the diagnostic information.


Modified:
    db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/AppRequester.java
    db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/DRDAConnThread.java
    db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/DRDAProtocolException.java
    db/derby/code/trunk/java/drda/org/apache/derby/loc/drda/messages_en.properties
    db/derby/code/trunk/java/engine/org/apache/derby/iapi/reference/Limits.java
    db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/ProtocolTest.policy
    db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/connect.inc
    db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/protocol.tests

Modified: db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/AppRequester.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/AppRequester.java?rev=1336268&r1=1336267&r2=1336268&view=diff
==============================================================================
--- db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/AppRequester.java (original)
+++ db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/AppRequester.java Wed May  9
16:11:08 2012
@@ -35,8 +35,7 @@ class AppRequester
 	protected static final int MGR_LEVEL_UNKNOWN = -1;
 
 	protected static final int UNKNOWN_CLIENT = 0;
-	protected static final int JCC_CLIENT = 1;
-	protected static final int CCC_CLIENT = 2;		// not yet supported.
+
 	protected static final int DNC_CLIENT = 3;		// derby net client 
 
 	private static final int [] MIN_MGR_LEVELS = {
@@ -108,17 +107,11 @@ class AppRequester
 		versionLevel = Integer.parseInt(prdid.substring (3, 5));
 		releaseLevel = Integer.parseInt(prdid.substring (5, 7));
 		modifyLevel = Integer.parseInt(prdid.substring (7, 8));
-		if (srvrlslv == null)
-		{ clientType = UNKNOWN_CLIENT; }
-		else if (srvrlslv.indexOf("JCC") != -1)
-		{ clientType = JCC_CLIENT; }
-		else if
-			(
-			    (srvrlslv.indexOf(DRDAConstants.DERBY_DRDA_CLIENT_ID) != -1)
-			)
-		{ clientType = DNC_CLIENT; }
-		else
-		{ clientType = UNKNOWN_CLIENT; }
+        if ((prdid.indexOf(DRDAConstants.DERBY_DRDA_CLIENT_ID) != -1)) {
+            clientType = DNC_CLIENT;
+        } else {
+            clientType = UNKNOWN_CLIENT;
+        }
 	}
 
 	/**
@@ -258,20 +251,7 @@ class AppRequester
 	 */
 
 	protected int supportedMessageParamLength() {
-
-		switch (clientType) {
-
-			case JCC_CLIENT:
-			case DNC_CLIENT:
-				return Limits.DB2_JCC_MAX_EXCEPTION_PARAM_LENGTH;
-			default:
-			// Default is the max for C clients, since that is more
-			// restricted than for JCC clients.  Note, though, that
-			// JCC clients are the only ones supported right now.
-				return Limits.DB2_CCC_MAX_EXCEPTION_PARAM_LENGTH;
-
-		}
-
+        return Limits.DB2_JCC_MAX_EXCEPTION_PARAM_LENGTH;
 	}
 
 	/**

Modified: db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/DRDAConnThread.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/DRDAConnThread.java?rev=1336268&r1=1336267&r2=1336268&view=diff
==============================================================================
--- db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/DRDAConnThread.java (original)
+++ db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/DRDAConnThread.java Wed May 
9 16:11:08 2012
@@ -3424,16 +3424,12 @@ class DRDAConnThread extends Thread {
 						trace("prdId " + appRequester.prdid);
 					if (appRequester.prdid.length() > CodePoint.PRDID_MAX)
 						tooBig(CodePoint.PRDID);
-
-					/* If JCC version is 1.5 or later, send SQLWarning on CNTQRY */
-					if (((appRequester.getClientType() == appRequester.JCC_CLIENT) &&
-						(appRequester.greaterThanOrEqualTo(1, 5, 0))) ||
-					   (appRequester.getClientType() == appRequester.DNC_CLIENT))
-					{
-						sendWarningsOnCNTQRY = true;
-					}
-					else sendWarningsOnCNTQRY = false;
-
+                    if (appRequester.getClientType() != appRequester.DNC_CLIENT) {
+                        invalidClient(appRequester.prdid);
+                    }
+                    // All versions of DNC,the only client supported, handle
+                    // warnings on CNTQRY
+                    sendWarningsOnCNTQRY = true;
 					// The client can not request DIAGLVL because when run with
 					// an older server it will cause an exception. Older version
 					// of the server do not recognize requests for DIAGLVL.
@@ -5511,11 +5507,9 @@ class DRDAConnThread extends Thread {
             // if multiple connections to different databases
             // are created
                         
-            // This check was added because of DERBY-1434
-                        
+            // This check was added because of DERBY-1434  
             // check the client version first
-            if ( appRequester.getClientType() != AppRequester.DNC_CLIENT
-                 || appRequester.greaterThanOrEqualTo(10,3,0) ) {
+            if (appRequester.greaterThanOrEqualTo(10,3,0) ) {
                 // check the database name
                 if (!rdbnam.toString().equals(database.getDatabaseName()))
                     rdbnamMismatch(CodePoint.PKGNAMCSN);
@@ -8249,6 +8243,34 @@ class DRDAConnThread extends Thread {
 	{
 		throwSyntaxrm(CodePoint.SYNERRCD_TOO_BIG, codePoint);
 	}
+     
+	
+    /**
+     * Invalid non-derby client tried to connect.
+     * thrown a required Value not found error and log a message to derby.log
+     * 
+     * @param prdid product id that does not match DNC 
+     * @throws DRDAProtocolException
+     */
+    private void invalidClient(String prdid) throws DRDAProtocolException {
+        Monitor.logMessage(new Date()
+                + " : "
+                + server.localizeMessage("DRDA_InvalidClient.S",
+                        new String[] { prdid }));
+        requiredValueNotFound(CodePoint.PRDID);
+
+    }
+    
+    /*** Required value not found.
+     * 
+     * @param codePoint code point with invalid value
+     * 
+     */
+    private void requiredValueNotFound(int codePoint) throws DRDAProtocolException {
+        throwSyntaxrm(CodePoint.SYNERRCD_REQ_VAL_NOT_FOUND, codePoint);
+    }
+    
+	
 	/**
 	 * Object length not allowed
 	 *

Modified: db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/DRDAProtocolException.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/DRDAProtocolException.java?rev=1336268&r1=1336267&r2=1336268&view=diff
==============================================================================
--- db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/DRDAProtocolException.java (original)
+++ db/derby/code/trunk/java/drda/org/apache/derby/impl/drda/DRDAProtocolException.java Wed
May  9 16:11:08 2012
@@ -101,6 +101,7 @@ class DRDAProtocolException extends Exce
 	protected static String DRDA_Disconnect=	   "DRDA_Disconnect";
 	protected static String DRDA_AgentError=	   "DRDA_AgentError";
     protected static String DRDA_Timeout=          "DRDA_Timeout";
+    protected static String DRDA_InvalidClient =   "DRDA_InvalidClient";
 
 	static {
 	/* Create the errorInfoTable

Modified: db/derby/code/trunk/java/drda/org/apache/derby/loc/drda/messages_en.properties
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/drda/org/apache/derby/loc/drda/messages_en.properties?rev=1336268&r1=1336267&r2=1336268&view=diff
==============================================================================
--- db/derby/code/trunk/java/drda/org/apache/derby/loc/drda/messages_en.properties (original)
+++ db/derby/code/trunk/java/drda/org/apache/derby/loc/drda/messages_en.properties Wed May
 9 16:11:08 2012
@@ -69,6 +69,8 @@ DRDA_RuntimeInfoError.S=Error getting Ru
 DRDA_PropInfoError.S=Error getting properties information.
 DRDA_PropInfoWriteError.S=Error in writing properties information:\n {0}
 DRDA_ProductVersionReadError.S=Error reading product version information from Derby installation.
{0}.
+
+DRDA_InvalidClient.S=ERROR UNSUPPORTED CLIENT: Invalid client product id {0}, Derby Network
Client (DNC) is the only supported client Product
 DRDA_ConnectionTested.I=Connection obtained for host: {0}, port number {1}.
 DRDA_ConnectionTested2.I=Connection obtained for host: {0}, port {1}, database {2}.
 DRDA_ConnectionTested3.I=Connection obtained for host: {0}, port {1}, database {2}, user
{3}.

Modified: db/derby/code/trunk/java/engine/org/apache/derby/iapi/reference/Limits.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/iapi/reference/Limits.java?rev=1336268&r1=1336267&r2=1336268&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/iapi/reference/Limits.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/iapi/reference/Limits.java Wed May  9
16:11:08 2012
@@ -47,8 +47,7 @@ public interface Limits
 	/* Maximum number of columns in an order by list */
 	public static final int DB2_MAX_ELEMENTS_IN_ORDER_BY = 1012;
 
-	// Max length for an exception parameter string over CCC server.
-	public static final int DB2_CCC_MAX_EXCEPTION_PARAM_LENGTH = 70;
+
 
 	// Warning. Changing this value will affect upgrade and the creation of the
 	// SQLCAMESSAGE procedure. See org.apache.derby.impl.sql.catalog.

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/ProtocolTest.policy
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/ProtocolTest.policy?rev=1336268&r1=1336267&r2=1336268&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/ProtocolTest.policy
(original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/ProtocolTest.policy
Wed May  9 16:11:08 2012
@@ -29,3 +29,9 @@ grant codeBase "${derbyTesting.testjar}d
   permission java.net.SocketPermission "localhost", "connect,resolve";
   permission java.net.SocketPermission "${derbyTesting.serverhost}", "connect,resolve";
 };
+
+// Give write permission for trace files if debugging with 
+// derby.drda.traceAll=true
+grant codeBase "${derbyTesting.codejar}derbynet.jar" {
+  permission java.io.FilePermission "${user.dir}${/}system${/}-", "read,write";
+};

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/connect.inc
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/connect.inc?rev=1336268&r1=1336267&r2=1336268&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/connect.inc
(original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/connect.inc
Wed May  9 16:11:08 2012
@@ -30,7 +30,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC10090"
 writeScalarString TYPDEFNAM "QTDSQLASC"
 startDdm TYPDEFOVR
 writeScalar2Bytes CCSIDSBC	1208
@@ -41,3 +41,4 @@ endDss
 flush
 skipDss // don't care about SECCHKRM so just skip
 skipDss // don't care about ACCRDBRM so just skip
+skipDss // Don't care about SQLDIAGGRP (sent with 10.2 and later) so just skip
\ No newline at end of file

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/protocol.tests
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/protocol.tests?rev=1336268&r1=1336267&r2=1336268&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/protocol.tests
(original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/protocol.tests
Wed May  9 16:11:08 2012
@@ -431,7 +431,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM QTDSQLJVM
 startDdm TYPDEFOVR
 writeScalar2Bytes  CCSIDSBC 1208
@@ -513,7 +513,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 endDdm
 endDss
 flush
@@ -527,7 +527,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM  QTDSQLASC
 endDdm
 endDss
@@ -542,7 +542,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM UNKNOWN
 startDdm TYPDEFOVR
 endDdm
@@ -559,7 +559,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM QTDSQLASC
 startDdm TYPDEFOVR
 writeScalar2Bytes MGRLVLLS 2
@@ -577,7 +577,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM QTDSQLJVM
 startDdm TYPDEFOVR
 startDdm CCSIDSBC
@@ -597,7 +597,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM QTDSQLJVM
 startDdm TYPDEFOVR
 startDdm CCSIDSBC
@@ -619,7 +619,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM QTDSQLJVM
 startDdm TYPDEFOVR
 startDdm CCSIDMBC
@@ -639,7 +639,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM QTDSQLJVM
 startDdm TYPDEFOVR
 startDdm CCSIDMBC
@@ -661,7 +661,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM QTDSQLJVM
 startDdm TYPDEFOVR
 startDdm CCSIDDBC
@@ -681,7 +681,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM QTDSQLJVM
 startDdm TYPDEFOVR
 startDdm CCSIDDBC
@@ -703,7 +703,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM QTDSQLJVM
 startDdm TYPDEFOVR
 writeScalar2Bytes  CCSIDSBC 5
@@ -721,7 +721,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM QTDSQLJVM
 startDdm TYPDEFOVR
 writeScalar2Bytes  CCSIDMBC 5
@@ -742,7 +742,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM QTDSQLJVM
 startDdm TYPDEFOVR
 writeScalar2Bytes  CCSIDDBC 5
@@ -763,7 +763,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM QTDSQLJVM
 startDdm TYPDEFOVR
 writeScalar2Bytes  CCSIDSBC 1208
@@ -826,7 +826,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM QTDSQLJVM
 startDdm TYPDEFOVR
 writeScalar2Bytes  CCSIDSBC 1208
@@ -852,7 +852,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM QTDSQLJVM
 startDdm TYPDEFOVR
 writeScalar2Bytes  CCSIDSBC 1208
@@ -870,7 +870,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000toobig"
+writeScalarString PRDID "DNC01000toobig"
 endDdm
 endDss
 flush
@@ -884,7 +884,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000toobig"
+writeScalarString PRDID "DNC01000toobig"
 writeScalarString TYPDEFNAM "testttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttt"
 endDdm
 endDss
@@ -899,7 +899,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000toobig"
+writeScalarString PRDID "DNC01000toobig"
 writeScalarString TYPDEFNAM "THISISNOTRIGHT"
 endDdm
 endDss
@@ -914,7 +914,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM "QTDSQLASC"
 startDdm TYPDEFOVR
 writeScalar2Bytes CCSIDSBC	1208
@@ -933,7 +933,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM "QTDSQLASC"
 startDdm TYPDEFOVR
 writeScalar2Bytes CCSIDSBC	1208
@@ -952,7 +952,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM "QTDSQLASC"
 startDdm TYPDEFOVR
 writeScalar2Bytes CCSIDSBC	1208
@@ -972,7 +972,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM "QTDSQLASC"
 startDdm TYPDEFOVR
 writeScalar2Bytes CCSIDSBC	1208
@@ -992,7 +992,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM "QTDSQLASC"
 startDdm TYPDEFOVR
 writeScalar2Bytes CCSIDSBC	1208
@@ -1038,6 +1038,7 @@ endTest
 //
 //
 DISPLAY "Test for bad RDBNAM in PKGNAMCSN"
+// Requires newer client to test  DERBY-1434 fix
 include connect.inc
 createDssRequest
 startDdm EXCSQLIMM
@@ -1076,7 +1077,8 @@ writeShort 8
 writePaddedString "rdbcolid" 8
 writeShort 5
 writePaddedString "pkgid"  5
-writeBytes "0x0101010101010101"
+//DERBY-5565 Need to make sure PRDID starts with DNC (hex)
+writeBytes "0x444E430101010101"
 writeShort 1
 endDdm
 endDdm
@@ -3316,7 +3318,7 @@ startDdm PKGNAMCSN
 writePaddedString "wombat" 18
 writePaddedString "rdbcolid" 18
 writePaddedString "pkgid"  18
-writeBytes "0x0101010101010101"
+writeBytes "0x444E430101010101"
 writeShort 1
 endDdm
 endDdm
@@ -3566,7 +3568,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM "QTDSQLASC"
 startDdm TYPDEFOVR
 writeScalar2Bytes CCSIDSBC	1208
@@ -3615,7 +3617,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM "QTDSQLASC"
 startDdm TYPDEFOVR
 writeScalar2Bytes CCSIDSBC	1208
@@ -3662,7 +3664,7 @@ createDssRequest
 startDdm ACCRDB
 writeScalar2Bytes RDBACCCL SQLAM
 writeScalarBytes CRRTKN "0xd5c6f0f0f0f0f0f14bc7c3c2f600ec774aa60e"
-writeScalarString PRDID "TST01000"
+writeScalarString PRDID "DNC01000"
 writeScalarString TYPDEFNAM "QTDSQLASC"
 startDdm TYPDEFOVR
 writeScalar2Bytes CCSIDSBC	1208



Mime
View raw message