Return-Path: Delivered-To: apmail-geronimo-user-archive@www.apache.org Received: (qmail 27558 invoked from network); 8 Dec 2005 01:19:03 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 8 Dec 2005 01:19:03 -0000 Received: (qmail 60515 invoked by uid 500); 8 Dec 2005 01:19:00 -0000 Delivered-To: apmail-geronimo-user-archive@geronimo.apache.org Received: (qmail 60471 invoked by uid 500); 8 Dec 2005 01:19:00 -0000 Mailing-List: contact user-help@geronimo.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: user@geronimo.apache.org List-Id: Delivered-To: mailing list user@geronimo.apache.org Received: (qmail 60459 invoked by uid 99); 8 Dec 2005 01:18:59 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 07 Dec 2005 17:18:59 -0800 X-ASF-Spam-Status: No, hits=1.4 required=10.0 tests=DNS_FROM_RFC_POST X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [62.118.80.130] (HELO petasus.ims.intel.com) (62.118.80.130) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 07 Dec 2005 17:18:59 -0800 Received: from MSSMSXVS01.ccr.corp.intel.com (MSSMSXVS01.ccr.corp.intel.com [10.125.2.23]) by petasus.ims.intel.com (8.12.9-20030918-01/8.12.10/d: small-solo.mc,v 1.2 2004/09/17 18:05:04 root Exp $) with SMTP id jB81VFQG018053 for ; Thu, 8 Dec 2005 01:31:15 GMT Received: from mssmsx331.ccr.corp.intel.com ([10.125.2.16]) by MSSMSXVS01.ccr.corp.intel.com (SAVSMTP 3.1.7.47) with SMTP id M2005120804183306635 for ; Thu, 08 Dec 2005 04:18:33 +0300 Received: from mssmsx402.ccr.corp.intel.com ([10.125.2.12]) by mssmsx331.ccr.corp.intel.com with Microsoft SMTPSVC(6.0.3790.211); Thu, 8 Dec 2005 04:18:33 +0300 X-MimeOLE: Produced By Microsoft Exchange V6.5.7226.0 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Subject: RE: JNDI remote authentication problem Date: Thu, 8 Dec 2005 04:18:32 +0300 Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: JNDI remote authentication problem Thread-Index: AcXwKLwnLSEQ0UTYRYiS7yredyrC+QAgX8mA From: "Zakharov, Vasily M" To: X-OriginalArrivalTime: 08 Dec 2005 01:18:33.0734 (UTC) FILETIME=[4E99FA60:01C5FB95] X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N John, Thank you very much for your answer! > Let me know what happens. Well, I tried correcting j2ee-server-plan.xml and config.xml, and I also tried to provide the proper value for allowHosts in GUI installer - it all didn't help. What really helped is correcting modules/assembly/maven.xml file and specifying the IP address of the client in line 247 (specifying host name or 255.255.255.255 mask also didn't help): "/> and then rebuilding Geronimo. However, it didn't helped much. I made additional investigation for the problem location and here's what I've found: The problem occurs in file org/openejb/client/Client.java: http://cvs.codehaus.org/viewrep/openejb/openejb/modules/core/src/java/or g/openejb/client/Client.java?r=3D1.5 Previously the problem occured at line 171 (see code, the exceptions are wrapped badly there): javax.naming.AuthenticationException: Cannot deternmine server protocol version: Received null/0.0; nested exception is:=20 java.io.IOException: Unable to read protocol version. Reached the end of the stream. at org.openejb.client.JNDIContext.authenticate(JNDIContext.java:196) at org.openejb.client.JNDIContext.getInitialContext(JNDIContext.java:181) at javax.naming.spi.NamingManager.getInitialContext(Unknown Source) at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source) at javax.naming.InitialContext.init(Unknown Source) at javax.naming.InitialContext.(Unknown Source) And after the fix to maven.xml and rebuilding Geronimo another error occurs a bit later, at line 192: javax.naming.AuthenticationException: Cannot read the response from the server (OEJP/2.0) : null; nested exception is:=20 java.io.EOFException at org.openejb.client.JNDIContext.authenticate(JNDIContext.java:196) at org.openejb.client.JNDIContext.getInitialContext(JNDIContext.java:181) at javax.naming.spi.NamingManager.getInitialContext(Unknown Source) at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source) at javax.naming.InitialContext.init(Unknown Source) at javax.naming.InitialContext.(Unknown Source) Previous problem was clearly a configuration issue, that was at last resolved, but I have completely no idea on what to do with this new problem. :( Can it be that Geronimo/OpenEJB does not accept remote JNDI connections at all?? With best regards, Vasily Zakharov, Intel Managed Runtime Division -----Original Message----- From: John Sisson [mailto:jrsisson@gmail.com]=20 Sent: Wednesday, November 23, 2005 3:23 PM To: user@geronimo.apache.org Subject: Re: JNDI remote authentication problem Hi Vasily, In the j2ee-server-plan.xml file it configures the IP addresses that the (OpenEJB) EJB daemon will accept connections from in the "allowHosts"=20 attribute. For example: EJB ${PlanOpenEJBPort} ${PlanServerHostname} ${PlanClientAddresses} HOST,NAME,THREADID,USERID HOST,NAME DefaultThreadPool openejb:type=3DServer,name=3DEJB= The In the geronimo\var\config.xml file (where you can specify attribute values that can override the values in the deployed plan) you should see the following section: 0.0.0.0 4201 In theory, you should be able to edit the config.xml file and specify=20 the allowable remote host by doing something like: 0.0.0.0 4201 myhostname *** But I have a bug currently open where the port number in the=20 config.xml file as shown in the example above is not actually used and I have a feeling the same problem will happen for allowHosts (see=20 http://issues.apache.org/jira/browse/GERONIMO-1151 ). I haven't had a=20 chance to debug this yet. Let me know what happens. I think most of the testing so far has been done on the localhost with=20 the default port. Regards, John Zakharov, Vasily M wrote: > Hello, all. > > =20 > > I'm trying to run an application that should access the beans=20 > (deployed in a Geronimo server running on other machine) with a JNDI=20 > request. > > =20 > > However, I get the following exception immediately at "new=20 > InitialContext()" statement: > > =20 > > javax.naming.AuthenticationException: Cannot deternmine server=20 > protocol version: Received null/0.0; nested exception=20 > is: =20 > > java.io.IOException: Unable to read protocol version. Reached > the end of the stream. =20 > > =20 > > The Geronimo console states the following at that moment: > > =20 > > 15:31:20,132 ERROR [EJB] Host is not authorized to access=20 > this service. > > java.lang.SecurityException: Host is not authorized to=20 > access this service. > > at=20 > org.activeio.xnet.hba.ServiceAccessController.checkHostsAuthorization(Se rviceAccessController.java:78) > > at=20 > org.activeio.xnet.hba.ServiceAccessController.service(ServiceAccessContr oller.java:51) > > at org.activeio.xnet.ServiceLogger.service(ServiceLogger.java:74) > > at=20 > org.activeio.xnet.ServiceDaemon$SocketListener.run(ServiceDaemon.java:15 1) > > at java.lang.Thread.run(Unknown Source) > > =20 > > (here replaces the IP address of the machine where I run my > application) > > =20 > > I'm using a default installation of Geronimo 1.0 M5, and Windows XP=20 > SP2 and Sun's JRE 1.4.2_08 on both machines. > > =20 > > The client application's system properties include: > > java.naming.factory.initial=3Dorg.openejb.client.RemoteInitialContextFact= o ry > > java.naming.provider.url=3D:4201 > > java.naming.security.principal=3Dsystem > > java.naming.security.credentials=3Dmanager > > =20 > > (here replaces the name of the machine where Geronimo=20 > is running and principal/credentials are the same I use to login to=20 > Geronimo console) > > =20 > > Also, I've put a local copy of openejb-core-2.0-G1M5.jar to the=20 > application's classpath for context factory to be found. > > =20 > > Could somebody please point me at what I'm doing wrong and how can I=20 > tune Geronimo to accept JNDI connections from the remote machine? > > =20 > > Thanks in advance, > > =20 > > Vasily Zakharov, Intel Managed Runtime Division >