Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 17209 invoked from network); 19 Apr 2006 11:23:30 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 19 Apr 2006 11:23:30 -0000 Received: (qmail 80039 invoked by uid 500); 19 Apr 2006 11:23:29 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 79994 invoked by uid 500); 19 Apr 2006 11:23:29 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 79973 invoked by uid 99); 19 Apr 2006 11:23:29 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 19 Apr 2006 04:23:28 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=UNPARSEABLE_RELAY X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [192.18.98.36] (HELO brmea-mail-4.sun.com) (192.18.98.36) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 19 Apr 2006 04:23:27 -0700 Received: from phys-epost-1 ([129.159.136.14]) by brmea-mail-4.sun.com (8.12.10/8.12.9) with ESMTP id k3JBN6Ze014605 for ; Wed, 19 Apr 2006 05:23:06 -0600 (MDT) Received: from conversion-daemon.epost-mail1.sweden.sun.com by epost-mail1.sweden.sun.com (iPlanet Messaging Server 5.2 HotFix 1.24 (built Dec 19 2003)) id <0IXY00H01V0VKB@epost-mail1.sweden.sun.com> (original mail from Vemund.Ostgaard@Sun.COM) for derby-dev@db.apache.org; Wed, 19 Apr 2006 13:23:05 +0200 (MEST) Received: from [129.159.112.244] (khepri32.Norway.Sun.COM [129.159.112.244]) by epost-mail1.sweden.sun.com (iPlanet Messaging Server 5.2 HotFix 1.24 (built Dec 19 2003)) with ESMTPA id <0IXY00L7TVMAWB@epost-mail1.sweden.sun.com> for derby-dev@db.apache.org; Wed, 19 Apr 2006 13:23:05 +0200 (MEST) Date: Wed, 19 Apr 2006 13:22:58 +0200 From: Vemund Ostgaard Subject: Re: java.lang.RuntimePermission getProtectionDomain in derbynet/sysinfo.java In-reply-to: <443DB300.4060308@amberpoint.com> To: derby-dev@db.apache.org Message-id: <44461D92.8010608@sun.com> MIME-version: 1.0 Content-type: text/plain; charset=ISO-8859-1; format=flowed Content-transfer-encoding: QUOTED-PRINTABLE X-Accept-Language: en-us, en User-Agent: Mozilla/5.0 (X11; U; SunOS i86pc; en-US; rv:1.7.12) Gecko/20050927 References: <443CEC05.3090802@sun.com> <443DB300.4060308@amberpoint.com> X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Bryan Pendleton wrote: > Vemund Ostgaard wrote: > >> After quite a bit of reading and testing it seems to me that the= =20 >> tests fail when db2jcc.jar is located in the same directory as the= =20 >> derby*.jar=20 > > Thanks for taking an interest in this Brian, I've been away on vacati= on=20 but now I've had a look at this again. > I have not succeeded in reproducing this, unfortunately. Here's wha= t I=20 > did: > > 1) copied db2jcc*.jar to trunk/jars/sane, where my other derby jars= are > 2) Set my classpath to point to the jars in trunk/jars/sane, includ= ing > db2jcc.jar and db2jcc_license_c.jar > 3) java -Dframework=3DDerbyNetClient=20 > org.apache.derbyTesting.functionTests.harness.RunTest=20 > derbynet/sysinfo.java > > And for me, the test still passed. > > Can you: > a) check my steps to see how they might be different from yours? Well, I've not built the jars myself, I just got them from our nightl= y=20 builds. Basically that means I just have a directory with all the jar= s=20 in, and no class files or any other files from the derby repository. > b) post your exact classpath that you're using > c) using that classpath, run > - java org.apache.derby.tools.sysinfo > - java org.apache.derby.tools.sysinfo -cp > and post the results that you get from those two runs? Here follows the relevant output: --- vo136787@khepri32:~/tmp/test> env |grep CLAS=20 CLASSPATH=3D/home/vo136787/derby/tmp/testbuild/lib/derby.jar:/home/vo= 136787/derby/tmp/testbuild/lib/derbyTesting.jar:/home/vo136787/derby/= tmp/testbuild/lib/derbytools.jar:/home/vo136787/derby/tmp/testbuild/l= ib/derbynet.jar:/home/vo136787/derby/tmp/testbuild/lib/derbyclient.ja= r:/home/vo136787/derby/tmp/testbuild/lib/derbyrun.jar:/home/vo136787/= derby/tmp/testbuild/lib/junit.jar:/home/vo136787/derby/tmp/testbuild/= lib/db2jcc.jar:/home/vo136787/derby/tmp/testbuild/lib/db2jcc_license_= c.jar:/home/vo136787/derby/tmp/testbuild/lib/jakarta-oro-2.0.8.jar:/h= ome/vo136787/derby/tmp/testbuild/lib/derbyLocale_de_DE.jar:/home/vo13= 6787/derby/tmp/testbuild/lib/derbyLocale_es.jar:/home/vo136787/derby/= tmp/testbuild/lib/derbyLocale_fr.jar:/home/vo136787/derby/tmp/testbui= ld/lib/derbyLocale_it.jar:/home/vo136787/derby/tmp/testbuild/lib/derb= yLocale_ja_JP.jar:/home/vo136787/derby/tmp/testbuild/lib/derbyLocale_= ko_KR.jar:/home/vo136787/derby/tmp/testbuild/lib/derbyLocale_pt_BR.ja= r:/home/vo136787/derby/tmp/testbuild/lib/derbyLocale_zh_CN.jar:/home/= vo136787/derby/tmp/testbuild/lib/derbyLocale_zh_TW.jar vo136787@khepri32:~/tmp/test> java -Dframework=3DDerbyNetClient=20 org.apache.derbyTesting.functionTests.harness.RunTest derbynet/sysinf= o.java *** Start: sysinfo jdk1.5.0_06 DerbyNetClient 2006-04-19 13:00:33 *** Initialize for framework: DerbyNetClient java -Dderby.system.home=3D/home/vo136787/tmp/test/DerbyNetClient/sys= info=20 -Djava.security.manager=20 -Djava.security.policy=3D/home/vo136787/tmp/test/derby_tests.policy= =20 -DderbyTesting.codejar=3Dfile:/home/vo136787/derby/tmp/testbuild/lib/= =20 -DderbyTesting.codedir=3D/home/vo136787/derby/tmp/testbuild/lib=20 -DderbyTesting.serverhost=3Dlocalhost -DderbyTesting.clienthost=3Dloc= alhost=20 -DderbyTesting.codeclasses=3Dfile://unused/=20 org.apache.derby.drda.NetworkServerControl start -- SecurityManager not installed -- Attempt to shutdown framework: DerbyNetClient 14a15 > [Unable to access Protection Domain or Code Source for class class= =20 com.ibm.db2.jcc.DB2Driver: access denied (java.lang.RuntimePermission= =20 getProtectionDomain)] 2.4 - (17) 41a43 > [Unable to access Protection Domain or Code Source for class class= =20 com.ibm.db2.jcc.DB2Driver: access denied (java.lang.RuntimePermission= =20 getProtectionDomain)] 2.4 - (17) 69a72 > [Unable to access Protection Domain or Code Source for class class= =20 com.ibm.db2.jcc.DB2Driver: access denied (java.lang.RuntimePermission= =20 getProtectionDomain)] 2.4 - (17) Test Failed. *** End: sysinfo jdk1.5.0_06 DerbyNetClient 2006-04-19 13:00:40 *** vo136787@khepri32:~/tmp/test> java org.apache.derby.tools.sysinfo ------------------ Java Information ------------------ Java Version: 1.5.0_06 Java Vendor: Sun Microsystems Inc. Java home: /usr/jdk/instances/jdk1.5.0/jre Java classpath: =20 /home/vo136787/derby/tmp/testbuild/lib/derby.jar:/home/vo136787/derby= /tmp/testbuild/lib/derbyTesting.jar:/home/vo136787/derby/tmp/testbuil= d/lib/derbytools.jar:/home/vo136787/derby/tmp/testbuild/lib/derbynet.= jar:/home/vo136787/derby/tmp/testbuild/lib/derbyclient.jar:/home/vo13= 6787/derby/tmp/testbuild/lib/derbyrun.jar:/home/vo136787/derby/tmp/te= stbuild/lib/junit.jar:/home/vo136787/derby/tmp/testbuild/lib/db2jcc.j= ar:/home/vo136787/derby/tmp/testbuild/lib/db2jcc_license_c.jar:/home/= vo136787/derby/tmp/testbuild/lib/jakarta-oro-2.0.8.jar:/home/vo136787= /derby/tmp/testbuild/lib/derbyLocale_de_DE.jar:/home/vo136787/derby/t= mp/testbuild/lib/derbyLocale_es.jar:/home/vo136787/derby/tmp/testbuil= d/lib/derbyLocale_fr.jar:/home/vo136787/derby/tmp/testbuild/lib/derby= Locale_it.jar:/home/vo136787/derby/tmp/testbuild/lib/derbyLocale_ja_J= P.jar:/home/vo136787/derby/tmp/testbuild/lib/derbyLocale_ko_KR.jar:/h= ome/vo136787/derby/tmp/testbuild/lib/derbyLocale_pt_BR.jar:/home/vo13= 6787/derby/tmp/testbuild/lib/derbyLocale_zh_CN.jar:/home/vo136787/der= by/tmp/testbuild/lib/derbyLocale_zh_TW.jar OS name: SunOS OS architecture: x86 OS version: 5.10 Java user name: vo136787 Java user home: /home/vo136787 Java user dir: /home/vo136787/tmp/test java.specification.name: Java Platform API Specification java.specification.version: 1.5 --------- Derby Information -------- JRE - JDBC: J2SE 5.0 - JDBC 3.0 [/home/vo136787/derby/tmp/testbuild/lib/derby.jar] 10.2.0.0 alpha - (= 394991) [/home/vo136787/derby/tmp/testbuild/lib/derbytools.jar] 10.2.0.0 alph= a -=20 (394991) [/home/vo136787/derby/tmp/testbuild/lib/derbynet.jar] 10.2.0.0 alpha = -=20 (394991) [/home/vo136787/derby/tmp/testbuild/lib/derbyclient.jar] 10.2.0.0 alp= ha=20 - (394991) [/home/vo136787/derby/tmp/testbuild/lib/db2jcc.jar] 2.4 - (17) [/home/vo136787/derby/tmp/testbuild/lib/db2jcc_license_c.jar] 2.4 - (= 17) ------------------------------------------------------ ----------------- Locale Information ----------------- Current Locale : [English/United States [en_US]] Found support for locale: [de_DE] version: 10.2.0.0 alpha - (394991) Found support for locale: [es] version: 10.2.0.0 alpha - (394991) Found support for locale: [fr] version: 10.2.0.0 alpha - (394991) Found support for locale: [it] version: 10.2.0.0 alpha - (394991) Found support for locale: [ja_JP] version: 10.2.0.0 alpha - (394991) Found support for locale: [ko_KR] version: 10.2.0.0 alpha - (394991) Found support for locale: [pt_BR] version: 10.2.0.0 alpha - (394991) Found support for locale: [zh_CN] version: 10.2.0.0 alpha - (394991) Found support for locale: [zh_TW] version: 10.2.0.0 alpha - (394991) ------------------------------------------------------ vo136787@khepri32:~/tmp/test> java org.apache.derby.tools.sysinfo -cp Testing for presence of all Derby-related libraries; typically, only= =20 some are needed. For a list of possible arguments, type java=20 org.apache.derby.tools.sysinfo -cp args FOUND IN CLASS PATH: Derby embedded engine library (derby.jar) /home/vo136787/derby/tmp/testbuild/lib/derby.jar Derby embedded engine library (derby.jar) /home/vo136787/derby/tmp/testbuild/lib/derby.jar Derby Network Server library (derbynet.jar) /home/vo136787/derby/tmp/testbuild/lib/derbynet.jar Derby Client libraries (db2jcc.jar) /home/vo136787/derby/tmp/testbuild/lib/db2jcc.jar Derby Client libraries (derbyclient.jar) /home/vo136787/derby/tmp/testbuild/lib/derbyclient.jar NOT FOUND IN CLASS PATH: Derby tools library (derbytools.jar) (org.apache.derby.tools.ij not found.) --- No idea why it doesn't find derbytools.jar when using -cp....it is th= ere=20 in the classpath. Vemund