Rmi/iiop with clients behind firewall?

I have a client app (standalone/applet) that will be running behind a firewall and I'm trying to connect it to S1AS7 through rmi/iiop. I keep getting some connection exceptions on the server when it tries to connect back to the client. Is there anyway to find out which port the server tries to connect to the client so I can open up that port with the firewall? Is there any other workarounds?

Check out the below document. This is a document for the earlier version of the appserver, but I guess this part should still hold good in S1AS 7 :
http://docs.sun.com/source/816-5777-10/jpgrichc.htm#24425
Basically, during the RMI-IIOP communication, the ports are assigned dynamically and hence we cannot exactly say which ports will be used for the response.
As a general rule of thumb, the response will be going through the ephemeral ports. (Ephemeral ports are temporary ports assigned by a machine's IP stack, and are assigned from a designated range of ports for this purpose. When the connection terminates, the ephemeral port is available for reuse, although most IP stacks won't reuse that port number until the entire pool of ephemeral ports have been used. So, if the client program reconnects, it will be assigned a different ephemeral port number for its side of the new connection.)
So, it is advisable to open the the entire ephemeral port range in the firewall.
On Solaris, the ephemeral port range can be determined using the below command :
# /usr/sbin/ndd /dev/tcp tcp_smallest_anon_port tcp_largest_anon_port
These values could also be altered using the below commands :
# /usr/sbin/ndd -set /dev/tcp tcp_smallest_anon_port 49152
# /usr/sbin/ndd -set /dev/tcp tcp_largest_anon_port 61000
Hope that helps...
Cheers,
VM

Similar Messages

  • RMI Clients behind firewall

    When the RMI client behind firewall tries to access the server the following error is thrown up:
    java.rmi.ConnectIOException: Exception creating connection to: 10.130.12.128; ne
    sted exception is:
    java.net.NoRouteToHostException: Operation timed out: no further informa
    tion
    java.net.NoRouteToHostException: Operation timed out: no further information
    at java.net.PlainSocketImpl.socketConnect(Native Method)
    at java.net.PlainSocketImpl.doConnect(Unknown Source)
    at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
    at java.net.PlainSocketImpl.connect(Unknown Source)
    at java.net.Socket.<init>(Unknown Source)
    at java.net.Socket.<init>(Unknown Source)
    at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(Unknown S
    ource)
    at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(Unknown S
    ource)
    at sun.rmi.transport.tcp.TCPEndpoint.newSocket(Unknown Source)
    at sun.rmi.transport.tcp.TCPChannel.createConnection(Unknown Source)
    at sun.rmi.transport.tcp.TCPChannel.newConnection(Unknown Source)
    at sun.rmi.server.UnicastRef.invoke(Unknown Source)
    at RMIFaxServer_Stub.getResult(Unknown Source)
    at FaxTest.main(FaxTest.java:51)

    your client is behind the firewall but the server you're trying to access has an address 10.x.x.x which says that it too is behind a firewall and not on the Internet, or is the server in a DMZ. It sounds more like a networking issue than a java problem at this point. If the server is on some side of a firewall, you may need a some sort of "permit established" config setting added to the firewall. Just a thought.

  • How to configure OC4J using RMI/IIOP with SSL

    Any help?
    I just mange configure the OC4J using RMI/IIOP but base on
    But when I follow further to use RMI/IIOP with SSL I face the problem with: javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?
    p/s: I use self generate keystore which should be ok as I can use it for https connection.
    Any one can help?
    Below is the OC4J log:
    D:\oc4j\j2ee\home>java -Djavax.net.debug=all -DGenerateIIOP=true -Diiop.runtime.debug=true -jar oc4j.jar
    05/02/23 16:43:16 ================ IIOPServerExtensionProvider.preInitApplicationServer
    05/02/23 16:43:38 ================= IIOPServerExtensionProvider.postInitApplicationServer
    05/02/23 16:43:38 ================== config = {SEPS={IIOP={ssl-port=5556, port=5555, ssl=true, trusted-clients=*, ssl-client-server-auth-port=5557, keystore=D:\\oc4j\\j2ee\\home\\server.keystore, keystore-password=123456, truststore=D:\\oc4j\\j2ee\\home\\server.keystore, truststore-password=123456, ClassName=com.oracle.iiop.server.IIOPServerExtensionProvider, host=localhost}}}
    05/02/23 16:43:38 ================== server.getAttributes() = {threadPool=com.evermind.server.ApplicationServerThreadPool@968fda}
    05/02/23 16:43:38 ================== pool: null
    05/02/23 16:43:38 ====================== In startServer ...
    05/02/23 16:43:38 ==================== Creating an IIOPServer ...
    05/02/23 16:43:38 ========= IIOP server being initialized
    05/02/23 16:43:38 SSL port: 5556
    05/02/23 16:43:38 SSL port 2: 5557
    05/02/23 16:43:43 com.sun.corba.ee.internal.iiop.GIOPImpl(Thread[Orion Launcher,5,main]): getEndpoint(IIOP_CLEAR_TEXT, 5555, null)
    05/02/23 16:43:43 com.sun.corba.ee.internal.iiop.GIOPImpl(Thread[Orion Launcher,5,main]): createListener( socketType = IIOP_CLEAR_TEXT port = 5555 )
    05/02/23 16:43:44 com.sun.corba.ee.internal.iiop.GIOPImpl(Thread[Orion Launcher,5,main]): getEndpoint(SSL, 5556, null)
    05/02/23 16:43:44 com.sun.corba.ee.internal.iiop.GIOPImpl(Thread[Orion Launcher,5,main]): createListener( socketType = SSL port = 5556 )
    05/02/23 16:43:45 ***
    05/02/23 16:43:45 found key for : mykey
    05/02/23 16:43:45 chain [0] = [
    Version: V1
    Subject: CN=Server, OU=Bar, O=Foo, L=Some, ST=Where, C=UN
    Signature Algorithm: MD5withRSA, OID = 1.2.840.113549.1.1.4
    Key: SunJSSE RSA public key:
    public exponent:
    010001
    modulus:
    b1239fff 2ae5d31d b01a0cfb 1186bae0 bbc7ac41 94f24464 e92a7e33 6a5b0844
    109e30fb d24ad770 99b3ff86 bd96c705 56bf2e7a b3bb9d03 40fdcc0a c9bea9a1
    c21395a4 37d8b2ce ff00eb64 e22a6dd6 97578f92 29627229 462ebfee 061c99a4
    1c69b3a0 aea6a95b 7ed3fd89 f829f17e a9362efe ccf8034a 0910989a a8573305
    Validity: [From: Wed Feb 23 15:57:28 SGT 2005,
                   To: Tue May 24 15:57:28 SGT 2005]
    Issuer: CN=Server, OU=Bar, O=Foo, L=Some, ST=Where, C=UN
    SerialNumber: [    421c3768]
    Algorithm: [MD5withRSA]
    Signature:
    0000: 34 F4 FA D4 6F 23 7B 84 30 42 F3 5C 4B 5E 18 17 4...o#..0B.\K^..
    0010: 73 69 73 A6 BF 9A 5D C0 67 8D C3 56 DF A9 4A AC sis...].g..V..J.
    0020: 88 AF 24 28 C9 39 16 22 29 81 01 93 86 AA 1A 5D ..$(.9.")......]
    0030: 07 89 26 22 91 F0 8F DE E1 4A CF 17 9A 02 51 7D ..&".....J....Q.
    0040: 92 D3 6D 9B EF 5E C1 C6 66 F9 11 D4 EB 13 8F 17 ..m..^..f.......
    0050: E7 66 58 9F 6C B0 60 7C 39 B4 E0 B7 04 A7 7F A6 .fX.l.`.9.......
    0060: 4D A5 89 E7 F4 8A DC 59 B4 E7 A5 D4 0A 35 9A F1 M......Y.....5..
    0070: A2 CD 3A 04 D6 8F 16 B1 9E 6F 34 40 E8 C0 47 03 ..:[email protected].
    05/02/23 16:43:45 ***
    05/02/23 16:43:45 adding as trusted cert:
    05/02/23 16:43:45 Subject: CN=Client, OU=Bar, O=Foo, L=Some, ST=Where, C=UN
    05/02/23 16:43:45 Issuer: CN=Client, OU=Bar, O=Foo, L=Some, ST=Where, C=UN
    05/02/23 16:43:45 Algorithm: RSA; Serial number: 0x421c3779
    05/02/23 16:43:45 Valid from Wed Feb 23 15:57:45 SGT 2005 until Tue May 24 15:57:45 SGT 2005
    05/02/23 16:43:45 adding as trusted cert:
    05/02/23 16:43:45 Subject: CN=Server, OU=Bar, O=Foo, L=Some, ST=Where, C=UN
    05/02/23 16:43:45 Issuer: CN=Server, OU=Bar, O=Foo, L=Some, ST=Where, C=UN
    05/02/23 16:43:45 Algorithm: RSA; Serial number: 0x421c3768
    05/02/23 16:43:45 Valid from Wed Feb 23 15:57:28 SGT 2005 until Tue May 24 15:57:28 SGT 2005
    05/02/23 16:43:45 trigger seeding of SecureRandom
    05/02/23 16:43:45 done seeding SecureRandom
    05/02/23 16:43:45 com.sun.corba.ee.internal.iiop.GIOPImpl(Thread[Orion Launcher,5,main]): getEndpoint(SSL_MUTUALAUTH, 5557, null)
    05/02/23 16:43:45 com.sun.corba.ee.internal.iiop.GIOPImpl(Thread[Orion Launcher,5,main]): createListener( socketType = SSL_MUTUALAUTH port = 5557 )
    05/02/23 16:43:45 matching alias: mykey
    matching alias: mykey
    05/02/23 16:43:46 ORB created ..com.oracle.iiop.server.OC4JORB@65b738
    05/02/23 16:43:47 com.sun.corba.ee.internal.corba.ClientDelegate(Thread[Orion Launcher,5,main]): invoke(ClientRequest) called
    05/02/23 16:43:47 com.oracle.iiop.server.OC4JORB(Thread[Orion Launcher,5,main]): process: dispatching to scid 2
    05/02/23 16:43:47 com.oracle.iiop.server.OC4JORB(Thread[Orion Launcher,5,main]): dispatching to sc [email protected]7
    05/02/23 16:43:48 com.sun.corba.ee.internal.corba.ClientDelegate(Thread[Orion Launcher,5,main]): invoke(ClientRequest) called
    05/02/23 16:43:48 com.oracle.iiop.server.OC4JORB(Thread[Orion Launcher,5,main]): process: dispatching to scid 2
    05/02/23 16:43:48 com.oracle.iiop.server.OC4JORB(Thread[Orion Launcher,5,main]): dispatching to sc com.sun.corba.ee.internal.corba.ServerDelegate@9300cc
    05/02/23 16:43:48 com.sun.corba.ee.internal.corba.ServerDelegate(Thread[Orion Launcher,5,main]): Entering dispatch method
    05/02/23 16:43:48 com.sun.corba.ee.internal.corba.ServerDelegate(Thread[Orion Launcher,5,main]): Consuming service contexts, GIOP version: 1.2
    05/02/23 16:43:48 com.sun.corba.ee.internal.corba.ServerDelegate(Thread[Orion Launcher,5,main]): Has code set context? false
    05/02/23 16:43:48 com.sun.corba.ee.internal.corba.ServerDelegate(Thread[Orion Launcher,5,main]): Dispatching to servant
    05/02/23 16:43:48 com.sun.corba.ee.internal.corba.ServerDelegate(Thread[Orion Launcher,5,main]): Handling invoke handler type servant
    05/02/23 16:43:48 NS service created and started ..org.omg.CosNaming._NamingContextExtStub:IOR:000000000000002b49444c3a6f6d672e6f72672f436f734e616d696e672f4e616d696e67436f6e746578744578743a312e30000000000001000000000000007c000102000000000c31302e312e3231342e31310015b3000000000031afabcb0000000020d309e06a0000000100000000000000010000000c4e616d65536572766963650000000004000000000a0000000000000100000001000000200000000000010001000000020501000100010020000101090000000100010100
    05/02/23 16:43:48 NS ior = ..IOR:000000000000002b49444c3a6f6d672e6f72672f436f734e616d696e672f4e616d696e67436f6e746578744578743a312e30000000000001000000000000007c000102000000000c31302e312e3231342e31310015b3000000000031afabcb0000000020d309e06a0000000100000000000000010000000c4e616d65536572766963650000000004000000000a0000000000000100000001000000200000000000010001000000020501000100010020000101090000000100010100
    05/02/23 16:43:48 Oracle Application Server Containers for J2EE 10g (9.0.4.0.0) initialized
    05/02/23 16:45:14 com.sun.corba.ee.internal.iiop.ConnectionTable(Thread[JavaIDL Listener,5,main]): Server getConnection(119e583[Unknown 0x0:0x0: Socket[addr=/127.0.0.1,port=1281,localport=5556]], SSL)
    05/02/23 16:45:14 com.sun.corba.ee.internal.iiop.ConnectionTable(Thread[JavaIDL Listener,5,main]): host = 127.0.0.1 port = 1281
    05/02/23 16:45:14 com.sun.corba.ee.internal.iiop.ConnectionTable(Thread[JavaIDL Listener,5,main]): Created connection Connection[type=SSL remote_host=127.0.0.1 remote_port=1281 state=ESTABLISHED]
    com.sun.corba.ee.internal.iiop.MessageMediator(Thread[JavaIDL Reader for 127.0.0.1:1281,5,main]): Creating message from stream
    05/02/23 16:45:14 JavaIDL Reader for 127.0.0.1:1281, handling exception: javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?
    05/02/23 16:45:14 JavaIDL Reader for 127.0.0.1:1281, SEND TLSv1 ALERT: fatal, description = unexpected_message
    05/02/23 16:45:14 JavaIDL Reader for 127.0.0.1:1281, WRITE: TLSv1 Alert, length = 2
    05/02/23 16:45:14 JavaIDL Reader for 127.0.0.1:1281, called closeSocket()
    05/02/23 16:45:14 com.sun.corba.ee.internal.iiop.ReaderThread(Thread[JavaIDL Reader for 127.0.0.1:1281,5,main]): IOException in createInputStream: javax.net.ssl.SSLException: Connection has been shutdown: javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?
    05/02/23 16:45:14 javax.net.ssl.SSLException: Connection has been shutdown: javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?
    05/02/23 16:45:14 at com.sun.net.ssl.internal.ssl.SSLSocketImpl.d(DashoA12275)
    05/02/23 16:45:14 at com.sun.net.ssl.internal.ssl.AppInputStream.read(DashoA12275)
    05/02/23 16:45:14 at com.sun.corba.ee.internal.iiop.messages.MessageBase.readFully(MessageBase.java:520)
    05/02/23 16:45:14 at com.sun.corba.ee.internal.iiop.messages.MessageBase.createFromStream(MessageBase.java:58)
    05/02/23 16:45:14 at com.sun.corba.ee.internal.iiop.MessageMediator.processRequest(MessageMediator.java:110)
    05/02/23 16:45:14 at com.sun.corba.ee.internal.iiop.IIOPConnection.processInput(IIOPConnection.java:339)
    05/02/23 16:45:14 at com.sun.corba.ee.internal.iiop.ReaderThread.run(ReaderThread.java:63)
    05/02/23 16:45:14 Caused by: javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?
    05/02/23 16:45:14 at com.sun.net.ssl.internal.ssl.InputRecord.b(DashoA12275)
    05/02/23 16:45:14 at com.sun.net.ssl.internal.ssl.InputRecord.read(DashoA12275)
    05/02/23 16:45:14 at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA12275)
    05/02/23 16:45:14 at com.sun.net.ssl.internal.ssl.SSLSocketImpl.j(DashoA12275)
    05/02/23 16:45:14 at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA12275)
    05/02/23 16:45:14 ... 6 more
    05/02/23 16:45:14 com.sun.corba.ee.internal.iiop.IIOPConnection(Thread[JavaIDL Reader for 127.0.0.1:1281,5,main]): purge_calls: starting: code = 1398079696 die = true
    05/02/23 16:45:14 JavaIDL Reader for 127.0.0.1:1281, called close()
    05/02/23 16:45:14 JavaIDL Reader for 127.0.0.1:1281, called closeInternal(true)
    05/02/23 16:45:14 JavaIDL Reader for 127.0.0.1:1281, called close()
    05/02/23 16:45:14 JavaIDL Reader for 127.0.0.1:1281, called closeInternal(true)
    05/02/23 16:45:14 JavaIDL Reader for 127.0.0.1:1281, called close()
    05/02/23 16:45:14 JavaIDL Reader for 127.0.0.1:1281, called closeInternal(true)
    05/02/23 16:45:14 com.sun.corba.ee.internal.iiop.ConnectionTable(Thread[JavaIDL Reader for 127.0.0.1:1281,5,main]): DeleteConn called: host = 127.0.0.1 port = 1281

    Good point, I do belive what you are referring to is this:
    Any client, whether running inside a server or not, has EJB security properties. Table 15-2 lists the EJB client security properties controlled by the ejb_sec.properties file. By default, OC4J searches for this file in the current directory when running as a client, or in ORACLE_HOME/j2ee/home/config when running in the server. You can specify the location of this file explicitly with the system property setting -Dejb_sec_properties_location=pathname.
    Table 15-2 EJB Client Security Properties
    Property Meaning
    # oc4j.iiop.keyStoreLoc
    The path and name of the keystore. An absolute path is recommended.
    # oc4j.iiop.keyStorePass
    The password for the keystore.
    # oc4j.iiop.trustStoreLoc
    The path name and name of the truststore. An absolute path is recommended.
    # oc4j.iiop.trustStorePass
    The password for the truststore.
    # oc4j.iiop.enable.clientauth
    Whether the client supports client-side authentication. If this property is set to true, you must specify a keystore location and password.
    # oc4j.iiop.ciphersuites
    Which cipher suites are to be enabled. The valid cipher suites are:
    TLS_RSA_WITH_RC4_128_MD5
    SSL_RSA_WITH_RC4_128_MD5
    TLS_DHE_DSS_WITH_3DES_EDE_CBC_SHA
    SSL_DHE_DSS_WITH_3DES_EDE_CBC_SHA
    TLS_RSA_EXPORT_WITH_RC4_40_MD5
    SSL_RSA_EXPORT_WITH_RC4_40_MD5
    TLS_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA
    SSL_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA
    nameservice.useSSL
    Whether to use SSL when making the initial connection to the server.
    client.sendpassword
    Whether to send user name and password in clear form (unencrypted) in the service context when not using SSL. If this property is set to true, the user name and password are sent only to servers listed in the trustedServer list.
    oc4j.iiop.trustedServers
    A list of servers that can be trusted to receive passwords sent in clear form. This has no effect if client.sendpassword is set to false. The list is comma-delimited. Each entry in the list can be an IP address, a host name, a host name pattern (for example, *.example.com), or * (where "*" alone means that all servers are trusted.

  • Use RMI-IIOP with wls 5.1 or 6.0 ???

    Morning,
    I was wondering if is was possible to use RMI-IIOP with
    WebLogic Server 5.1 or 6.0 and if possible with which version
    of the RMI-IIOP specification ???
    I've not seen any information about that in the documentation ; if anybody could
    help, I would appreciate !
    Thanks a lot.
    Pierre-Yves FOURMOND
    Axway Software. a Sopra Group Company
    Direction Edition de Progiciels
    EAI - R&D XTalk
    Puteaux 2 - Bureau n°204
    [email protected]
    01 47 17 22 55

    "Pierre-Yves Fourmond" <[email protected]> writes:
    I was wondering if is was possible to use RMI-IIOP with
    WebLogic Server 5.1 or 6.0 and if possible with which version
    of the RMI-IIOP specification ???WLS 5.1SP11 has the same RMI-IIOP runtime as WLS6.1SP2. 6.0 contains
    the old runtime, at the moment it seems most customers are happy to
    upgrade to 6.1 from 6.0
    andy
    >
    I've not seen any information about that in the documentation ; if anybody could
    help, I would appreciate !
    Thanks a lot.
    Pierre-Yves FOURMOND
    Axway Software. a Sopra Group Company
    Direction Edition de Progiciels
    EAI - R&D XTalk
    Puteaux 2 - Bureau n°204
    [email protected]
    01 47 17 22 55--
    " .sigs are like your face - rarely seen by you and uglier than you think"
    mail: [email protected]

  • Multiple ichat clients behind firewall?

    IS it possible to have multiple ichat clients behind a firewall? I've just bought a macbook pro and would like to purchase two more for ichat functionality. Two of these will be behind one firewall, the other across the country. I can't find any documentation other than how to configure a single ichat client.
    Is it possible? It's ok if we have to purchase an xserve and run some kind of server our end - I just want it to work.
    Message was edited by: paulgami

    Hi paulgami,
    iChat will work behind a firewall or routing device.
    With routing device the easiest method is UPnP which allows the Apps to open the ports and allows multiple computers to use the same ports.
    A device that has Port Triggering can also allow multiple computers to use the same ports.
    If you mean that you want the Bonjour side or even the Jabber side (in the iChat Server in OS X serve) to be in the same Network you will have to look to setting up VPNs (virtual Private Networks) to cover the distances you are talking about.
    It may be just semantics but it helps if we know which bit of iChat you are talking about.
    Tiger 10.4.x OS X Serve has an Jabber Server that can be used with the Jabber side of iChat (iChat 3.x)
    Each computer already has the iChat Client.
    There are also Public Jabber servers including Googletalk to use with the Jabber side of iChat.
    The Main Buddy list obviously uses the AIM service and again this can be world wide.
    iChat also has the Bonjour side. This can find any other Mac on the same network. It uses the user's Address Book to broadcast a Screen Name for the other iChat clients (separate buddy List)
    Possibly start here
    http://www.ralphjohnsuk.dsl.pipex.com/index.html
    Just getting started ?
    http://www.siriusaddict.com/ichat.html
    Collaboration Services Forum in OS XServer
    http://discussions.apple.com/forum.jspa?forumID=700
    8:44 PM Monday; August 13, 2007

  • RMI security with client authentication

    Hy,
    I'm trying to set a secure RMI application using JSSE and SSL.
    I have succeeded in writing an application with client and server authentication using both an RMISSLServerSocketFactory and RMISSLClientSocketFactory and passing those factories to the server while exporting the remote object.
    The problem is I had to set both server public and private keys and client public and private keys in the custom Socket Factories. This implies that those keys are on the server disk which is problematic for the client private key.
    Is there a way of giving the client private key only when the Client want to contact the server and not when exporting the remote object?
    (I tried to do that using -Djava.net.ssl.keyStore and -Djava.net.ssl.trustStore properties but it doesn't seem to work).
    Thank you for your help

    Even when I haven't wrote RMI over SSL code, I've done that using standard SSL client authentication between a client and a server.
    In that context, I got the SSLSocketFactory by using a SSLContext initialized with the proper TrustManager and KeyManager classes.
    But I guess you can start by specifying from the command line the system properties related to keystores and truststores:
    -Djavax.net.ssl.keyStore=<your keystore pathname>
    -Djavax.net.ssl.keyStorePassword=<your keystore password>
    -Djavax.net.ssl.trustStore=<your truststore pathname>
    -Djavax.net.ssl.trustStorePassword=<your truststore password>
    You can also see the RMISSLClientSocketFactory and RMISSLServerSocketFactory provided in the /samples/rmi folder of the JSSE 1.0.3_01 distribution.
    The client factory version uses the default socket factory provided by JSSE, so it can be configured from the properties above.
    Hope this helps.

  • Callback cannot be done if client behind firewall. But WHY?

    I've read a lot of threads regarding callback is not achievable if client is behind firewall. But i couldn't find the DETAILED reason for that. Can anyone explain that?
    Thank,
    Jax

    In order for a server to asynchronously callback a client, it must create an inbound socket connection to the client, to send the message. This is precisely the type of thing a firewall is designed to prevent.
    To receive callbacks, the firewall would have to open a specific port for inbound connections to the client, and the server would have to be aware of this port as well.

  • Java Rmi Client behind firewall

    What port should be opened to let rmi traffic passing through firewall to weblogic app server?

    Dahan <[email protected]> writes:
    What port should be opened to let rmi traffic passing through firewall to weblogic app server?The port the server is listening on?
    andy

  • Rmi/iiop with jndi naming  service

    C:\JBuilderX\jdk1.4\bin\javaw -classpath "C:\HelloRMIIIOP\HelloRMIIIOP\classes;C:\JBuilderX\lib\cx.jar;C:\JBuilderX\jdk1 .4\demo\jfc\Java2D\Java2Demo.jar;C:\JBuilderX\jdk1.4\demo\plugin\jfc\Java2D\Java 2Demo.jar;C:\JBuilderX\jdk1.4\jre\javaws\javaws.jar;C:\JBuilderX\jdk1.4\jre\lib\ applet\WMPNS.jar;C:\JBuilderX\jdk1.4\jre\lib\charsets.jar;C:\JBuilderX\jdk1.4\jr e\lib\ext\cosnaming.jar;C:\JBuilderX\jdk1.4\jre\lib\ext\dnsns.jar;C:\JBuilderX\j dk1.4\jre\lib\ext\ldapsec.jar;C:\JBuilderX\jdk1.4\jre\lib\ext\localedata.jar;C:\ JBuilderX\jdk1.4\jre\lib\ext\providerutil.jar;C:\JBuilderX\jdk1.4\jre\lib\ext\su njce_provider.jar;C:\JBuilderX\jdk1.4\jre\lib\im\indicim.jar;C:\JBuilderX\jdk1.4 \jre\lib\im\thaiim.jar;C:\JBuilderX\jdk1.4\jre\lib\jce.jar;C:\JBuilderX\jdk1.4\j re\lib\jsse.jar;C:\JBuilderX\jdk1.4\jre\lib\plugin.jar;C:\JBuilderX\jdk1.4\jre\l ib\rt.jar;C:\JBuilderX\jdk1.4\jre\lib\sunrsasign.jar;C:\JBuilderX\jdk1.4\lib\dt. jar;C:\JBuilderX\jdk1.4\lib\htmlconverter.jar;r" HelloServer
    javax.naming.NoInitialContextException: Cannot instantiate class: com.sun.jndi.cosnaming.CNCtxFactory [Root exception is java.lang.ClassNotFoundException: com/sun/jndi/cosnaming/CNCtxFactory ]
    at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:652)
    at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:243)
    at javax.naming.InitialContext.init(InitialContext.java:219)Trouble: javax.naming.NoInitialContextException: Cannot instantiate class: com.sun.jndi.cosnaming.CNCtxFactory [Root exception is java.lang.ClassNotFoundException: com/sun/jndi/cosnaming/CNCtxFactory ]
    at javax.naming.InitialContext.<init>(InitialContext.java:175)
    at HelloServer.main(HelloServer.java:13)
    Caused by: java.lang.ClassNotFoundException: com/sun/jndi/cosnaming/CNCtxFactory
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:219)
    at com.sun.naming.internal.VersionHelper12.loadClass(VersionHelper12.java:42)
    at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:649)
    ... 4 more
    please help!!!i its driving me nuts!!!
    soem will say i need to download jndi jar file i ll tell u did that butt i still have the error.moerover i think in jdk 1.4 jndi is already there. i checked the class path and double checked the cosnaming.jar file and i still have the problem
    pleas him i am stuck with this for months.
    i read in books its a classpath problem but i did check the classpath!!!!!!

    C:\JBuilderX\jdk1.4\bin\javaw -classpath "C:\HelloRMIIIOP\HelloRMIIIOP\classes;C:\JBuilderX\lib\cx.jar;C:\JBuilderX\jdk1 .4\demo\jfc\Java2D\Java2Demo.jar;C:\JBuilderX\jdk1.4\demo\plugin\jfc\Java2D\Java 2Demo.jar;C:\JBuilderX\jdk1.4\jre\javaws\javaws.jar;C:\JBuilderX\jdk1.4\jre\lib\ applet\WMPNS.jar;C:\JBuilderX\jdk1.4\jre\lib\charsets.jar;C:\JBuilderX\jdk1.4\jr e\lib\ext\cosnaming.jar;C:\JBuilderX\jdk1.4\jre\lib\ext\dnsns.jar;C:\JBuilderX\j dk1.4\jre\lib\ext\ldapsec.jar;C:\JBuilderX\jdk1.4\jre\lib\ext\localedata.jar;C:\ JBuilderX\jdk1.4\jre\lib\ext\providerutil.jar;C:\JBuilderX\jdk1.4\jre\lib\ext\su njce_provider.jar;C:\JBuilderX\jdk1.4\jre\lib\im\indicim.jar;C:\JBuilderX\jdk1.4 \jre\lib\im\thaiim.jar;C:\JBuilderX\jdk1.4\jre\lib\jce.jar;C:\JBuilderX\jdk1.4\j re\lib\jsse.jar;C:\JBuilderX\jdk1.4\jre\lib\plugin.jar;C:\JBuilderX\jdk1.4\jre\l ib\rt.jar;C:\JBuilderX\jdk1.4\jre\lib\sunrsasign.jar;C:\JBuilderX\jdk1.4\lib\dt. jar;C:\JBuilderX\jdk1.4\lib\htmlconverter.jar;r" HelloServer
    javax.naming.NoInitialContextException: Cannot instantiate class: com.sun.jndi.cosnaming.CNCtxFactory [Root exception is java.lang.ClassNotFoundException: com/sun/jndi/cosnaming/CNCtxFactory ]
    at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:652)
    at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:243)
    at javax.naming.InitialContext.init(InitialContext.java:219)Trouble: javax.naming.NoInitialContextException: Cannot instantiate class: com.sun.jndi.cosnaming.CNCtxFactory [Root exception is java.lang.ClassNotFoundException: com/sun/jndi/cosnaming/CNCtxFactory ]
    at javax.naming.InitialContext.<init>(InitialContext.java:175)
    at HelloServer.main(HelloServer.java:13)
    Caused by: java.lang.ClassNotFoundException: com/sun/jndi/cosnaming/CNCtxFactory
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:219)
    at com.sun.naming.internal.VersionHelper12.loadClass(VersionHelper12.java:42)
    at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:649)
    ... 4 more
    please help!!!i its driving me nuts!!!
    soem will say i need to download jndi jar file i ll tell u did that butt i still have the error.moerover i think in jdk 1.4 jndi is already there. i checked the class path and double checked the cosnaming.jar file and i still have the problem
    pleas him i am stuck with this for months.
    i read in books its a classpath problem but i did check the classpath!!!!!!

  • RMI-IIOP JNDI lookup returns com.sun.corba.se.internal.iiop.CDRInputStream

    I have two different RMI-IIOP java clients, one is working fine and the other is not. Both are using weblogic.jndi.WLInitialContextFactory from wlclient.jar in WLS 8.1sp5 and JDK 1.4.2_6.
    One java client is a straight-forward java main. JNDI lookup is returning EJBHome_Stub correctly loaded by sun.rmi.server.LoaderHandler$Loader
    The other java client is a complex java program with multiple threads and many jars. A thread does the same JNDI lookup as the simple java client, but the object returned is of type com.sun.corba.se.internal.iiop.CDRInputStream_1_0$1 which has NULL classloader (bootstrap classloader).
    What condition triggered the WebLogic InitialContext to default to com.sun.corba.se.internal.iiop.CDRInputStream?

    Kevin Fung <> writes:
    This is usally symptomatic of an IOR without the corresponding stub
    being loaded, usually because the correct security manager is not
    set. However the client jar bypasses the security manager to try and
    avoid this problem, so I am confused as to why you are seeing this. Do
    you know which object it is accessing? Can you try putting IIOP stubs
    for it in the client?
    andy
    I have two different RMI-IIOP java clients, one is working fine and the other is not. Both are using weblogic.jndi.WLInitialContextFactory from wlclient.jar in WLS 8.1sp5 and JDK 1.4.2_6.
    One java client is a straight-forward java main. JNDI lookup is returning EJBHome_Stub correctly loaded by sun.rmi.server.LoaderHandler$Loader
    The other java client is a complex java program with multiple threads and many jars. A thread does the same JNDI lookup as the simple java client, but the object returned is of type com.sun.corba.se.internal.iiop.CDRInputStream_1_0$1 which has NULL classloader (bootstrap classloader).
    What condition triggered the WebLogic InitialContext to default to com.sun.corba.se.internal.iiop.CDRInputStream?

  • RMI-IIOP client - CORBA Server

    I already have a CORBA server in C++ which has already been written. I am trying to develop an RMI-IIOP client which would talk to this CORBA Server.
    The CORBA server has several interfaces that I would like to use with my RMI-IIOP client. How do I proceed?? Can somebody give me an example of an RMI-IIOP client? Basically my question is: how do I take the IDL and build an RMI-IIOP client with it???

    Hello
    I already have a CORBA server in C++ which has already
    been written. I am trying to develop an RMI-IIOP
    client which would talk to this CORBA Server.
    The CORBA server has several interfaces that I would
    like to use with my RMI-IIOP client. How do I
    proceed?? Can somebody give me an example of an
    RMI-IIOP client? Basically my question is: how do I
    take the IDL and build an RMI-IIOP client with it???The steps to do are the following:
    * Creating the Remote interface
    * Using the rmic compiler to genarate the IDL and the client stub.
    * Generating stub and skeleton of the C++ server using that IDL (the one you already made is no longer compatible)
    * Bulding up the new C++ server
    * Using a nameservice (tnameserver for example) and binding your server to that.
    * Writing the RMI-IIOP client
    I proceeded like this (using Visibroker 4.5 on the server side) and I was able to do it... but as you can see from my last post, I wasn't able to pass Strings from the client to the server.
    Bye

  • How write rmi-iiop over ssl with weblogic server 6.1 - No server found

    //New
    Hello,
    I have written an appication like this:
    - An EJB server running on Weblogic server 6.1
    (named: BankServerHome)
    -A java client calling the BankServer.
    Platform: windows 2000 - jdk1.3
    Now I want to secure the communication with SSL protocol.
    I have done this:
    -generate a key peer with weblogic service named certificate.
    -send the CSR to a CA and place the answer into the weblogic
    server certificate directory.
    -update path for ServerCertificateChainFileName,
    ServerCertificateFileName, ServerKeyFileName into config.xml.
    -launch weblogicServer
         -> server certificate is recognized
         -> listening port 7001 and 7002.
    (-stop weblogicServer!)
    At now, all is all right, errors come hereafter:
    Then I follow the guideline "Programming weblogic Security" (version of 30/07/2001).
    "To use RMI over IIOP over SSL with a Java client, do the following:
    2. Extend the java.rmi.server.RMISocketFactory class to handle SSL socket
    connections. Be sure to specify the port on which WebLogic Server listens for
    SSL connections. For an example of a class that extends the
    java.rmi.server.RMISocketFactory class, see Listing 4-22.
    3. Run the ejbc compiler with the -d option.
    4. Add your extension of the java.rmi.server.RMISocketFactory class to the
    CLASSPATH of the Java client.
    5. Use the following command options when starting the Java client:
    -xbootclasspath/a:%CLASSPATH%
    -Dorg.omg.CORBA.ORBSocketFactoryClass=implementation of java.rmi.server.RMISocketFactory
    -Dssl.certs=directory location of digital certificate for Java client
    -Dssl.key=directory location of private key for Java client"
    At step 3. I found into documentation that -d is linked to a directory name.
    When I run ejbc with this option -d I have the message:
    "ERROR: You must specify an output directory or jar with the -d option to weblogic.ejbc."
    % So what option can I use to run ejbc for secure usage?
    At step 5. Whatever I write for -Dorg.omg.CORBA.ORBSocketFactoryClass,
    this pointed class is not instanciated.
    Then I can not create a socket with my client.
    The folowing exception is raised:
    javax.naming.CommunicationException [Root exception is java.net.ConnectException:
    No server found at T3S://localhost:7002]
    So, my questions are:
    % Why -Dorg.omg.CORBA.ORBSocketFactoryClass must be known by the client and not
    the server?
    My java client part, managing connection is:
    -------------------BEGIN OF CONNECTION MANAGER-------------------
    Properties env = new Properties ();
    // Shouldn't have to do this, but for now you must
    if ( factory.equals ("weblogic.jndi.WLInitialContextFactory") ) {
    env.put ("java.naming.provider.url", "t3s://localhost:7002");
    InitialContext context = new InitialContext (env);
    BankSessionServerHome bssh = (BankServerHome) context.lookup("BankServerHome");
    BankServer = bssh.create();
    -------------------END OF CONNECTION MANAGER-------------------
    I have also try
    env.put ("java.naming.provider.url", "corbaloc:iiop://localhost:7002");
    but it throws the following error
    javax.naming.InvalidNameException: url does not conatin !!!
    % What is the code for the java client allowing connection with the ejb?
    % And better, can I have a sample example for rmi-iiop over ssl?
    (...wlserver6.1\samples\examples\iiop\ejb\stateless\rmiclient\client.java do not
    speak ssl!)
    Any help will be appreciate from you...
    Best Regards.
    Oliver

    "oliver" <[email protected]> writes:
    The SSL support is poorly doc'd right now. We have fixed this and
    updated the way you do things in SP2. Please either wait for SP2 or
    contact support.
    andy
    I have written an appication like this:
    - An EJB server running on Weblogic server 6.1
    (named: BankServerHome)
    -A java client calling the BankServer.
    Platform: windows 2000 - jdk1.3
    Now I want to secure the communication with SSL protocol.
    I have done this:
    -generate a key peer with weblogic service named certificate.
    -send the CSR to a CA and place the answer into the weblogic
    server certificate directory.
    -update path for ServerCertificateChainFileName,
    ServerCertificateFileName, ServerKeyFileName into config.xml.
    -launch weblogicServer
         -> server certificate is recognized
         -> listening port 7001 and 7002.
    (-stop weblogicServer!)
    At now, all is all right, errors come hereafter:
    Then I follow the guideline "Programming weblogic Security" (version of 30/07/2001).
    "To use RMI over IIOP over SSL with a Java client, do the following:
    2. Extend the java.rmi.server.RMISocketFactory class to handle SSL socket
    connections. Be sure to specify the port on which WebLogic Server listens for
    SSL connections. For an example of a class that extends the
    java.rmi.server.RMISocketFactory class, see Listing 4-22.
    3. Run the ejbc compiler with the -d option.
    4. Add your extension of the java.rmi.server.RMISocketFactory class to the
    CLASSPATH of the Java client.
    5. Use the following command options when starting the Java client:
    -xbootclasspath/a:%CLASSPATH%
    -Dorg.omg.CORBA.ORBSocketFactoryClass=implementation of java.rmi.server.RMISocketFactory
    -Dssl.certs=directory location of digital certificate for Java client
    -Dssl.key=directory location of private key for Java client"
    At step 3. I found into documentation that -d is linked to a directory name.
    When I run ejbc with this option -d I have the message:
    "ERROR: You must specify an output directory or jar with the -d option to weblogic.ejbc."
    % So what option can I use to run ejbc for secure usage?
    At step 5. Whatever I write for -Dorg.omg.CORBA.ORBSocketFactoryClass,
    this pointed class is not instanciated.
    Then I can not create a socket with my client.
    The folowing exception is raised:
    javax.naming.CommunicationException [Root exception is java.net.ConnectException:
    No server found at T3S://localhost:7002]
    So, my questions are:
    % Why -Dorg.omg.CORBA.ORBSocketFactoryClass must be known by the client and not
    the server?
    My java client part, managing connection is:
    -------------------BEGIN OF CONNECTION MANAGER-------------------
    Properties env = new Properties ();
    // Shouldn't have to do this, but for now you must
    if ( factory.equals ("weblogic.jndi.WLInitialContextFactory") ) {
    env.put ("java.naming.provider.url", "t3s://localhost:7002");
    InitialContext context = new InitialContext (env);
    BankSessionServerHome bssh = (BankServerHome) context.lookup("BankServerHome");
    BankServer = bssh.create();
    -------------------END OF CONNECTION MANAGER-------------------
    I have also try
    env.put ("java.naming.provider.url", "corbaloc:iiop://localhost:7002");
    but it throws the following error
    javax.naming.InvalidNameException: url does not conatin !!!
    % What is the code for the java client allowing connection with the ejb?
    % And better, can I have a sample example for rmi-iiop over ssl?
    (...wlserver6.1\samples\examples\iiop\ejb\stateless\rmiclient\client.java do not
    speak ssl!)
    Any help will be appreciate from you...
    Best Regards.
    Oliver

  • How write rmi-iiop over ssl with weblogic server 6.1?

    Hello,
    I have written an appication like this:
    - An EJB server running on Weblogic server 6.1
    (named: BankServerHome)
    -A java client calling the BankServer.
    Platform: windows 2000 - jdk1.4
    Now I want to secure the communication with SSL protocol.
    I have done this:
    -generate a key peer with weblogic service named certificate.
    -send the CSR to a CA and place the answer into the weblogic
    server certificate directory.
    -update path for ServerCertificateChainFileName,
    ServerCertificateFileName, ServerKeyFileName into config.xml.
    -launch weblogicServer
         -> server certificate is recognized
         -> listening port 7001 and 7002.
    (-stop weblogicServer!)
    At now, all is all right, errors come hereafter:
    Then I follow the guideline "Programming weblogic Security" (version of 30/07/2001).
    "To use RMI over IIOP over SSL with a Java client, do the following:
    2. Extend the java.rmi.server.RMISocketFactory class to handle SSL socket
    connections. Be sure to specify the port on which WebLogic Server listens for
    SSL connections. For an example of a class that extends the
    java.rmi.server.RMISocketFactory class, see Listing 4-22.
    3. Run the ejbc compiler with the -d option.
    4. Add your extension of the java.rmi.server.RMISocketFactory class to the
    CLASSPATH of the Java client.
    5. Use the following command options when starting the Java client:
    -xbootclasspath/a:%CLASSPATH%
    -Dorg.omg.CORBA.ORBSocketFactoryClass=implementation of java.rmi.server.RMISocketFactory
    -Dssl.certs=directory location of digital certificate for Java client
    -Dssl.key=directory location of private key for Java client"
    At step 3. I found into documentation that -d is linked to a directory name.
    When I run ejbc with this option -d I have the message:
    "ERROR: You must specify an output directory or jar with the -d option to weblogic.ejbc."
    % So what option can I use to run ejbc for secure usage?
    At step 5. Whatever I write for -Dorg.omg.CORBA.ORBSocketFactoryClass,
    this pointed class is not instanciated.
    Then I can not create a socket with my client.
    The folowing exception is raised:
    javax.naming.CommunicationException [Root exception is java.net.ConnectException:
    No server found at T3S://localhost:7002]
    So, my questions are:
    % Why -Dorg.omg.CORBA.ORBSocketFactoryClass must be known by the client and not
    the server?
    My java client part, managing connection is:
    -------------------BEGIN OF CONNECTION MANAGER-------------------
    Properties env = new Properties ();
    // Shouldn't have to do this, but for now you must
    if ( factory.equals ("weblogic.jndi.WLInitialContextFactory") ) {
    env.put ("java.naming.provider.url", "t3s://localhost:7002");
    } else {
    env.put ("java.naming.provider.url", "rmi://localhost:7002");
    InitialContext context = new InitialContext (env);
    BankSessionServerHome bssh = (BankServerHome) context.lookup("BankServerHome");
    BankServer = bssh.create();
    -------------------END OF CONNECTION MANAGER-------------------
    % What is the code for the java client allowing connection with the ejb?
    % And better, can I have a sample example for rmi-iiop over ssl?
    (...wlserver6.1\samples\examples\iiop\ejb\stateless\rmiclient\client.java do not
    speak ssl!)
    Any help will be appreciate from you...
    Best Regards.
    Oliver

    "oliver" <[email protected]> writes:
    First off 1.4 isn't supported as yet. That is probably part of the problem.
    You also must use a corba URL from the client in order for this to work for instance:
    If you are using WLInitialContextFactory:
    corbaloc:iiop:localhost:7001/NameService
    If you are using CNCtxFactory:
    iiop://localhost:7001
    Using rmi: is the wrong thing to do - that will use jrmp or t3.
    However, I suggest that you raise a call with support since there is
    some other trickiness with getting SSL working. We hope to have this
    much improved in SP2.
    andy
    Hello,
    I have written an appication like this:
    - An EJB server running on Weblogic server 6.1
    (named: BankServerHome)
    -A java client calling the BankServer.
    Platform: windows 2000 - jdk1.4
    Now I want to secure the communication with SSL protocol.
    I have done this:
    -generate a key peer with weblogic service named certificate.
    -send the CSR to a CA and place the answer into the weblogic
    server certificate directory.
    -update path for ServerCertificateChainFileName,
    ServerCertificateFileName, ServerKeyFileName into config.xml.
    -launch weblogicServer
         -> server certificate is recognized
         -> listening port 7001 and 7002.
    (-stop weblogicServer!)
    At now, all is all right, errors come hereafter:
    Then I follow the guideline "Programming weblogic Security" (version of 30/07/2001).
    "To use RMI over IIOP over SSL with a Java client, do the following:
    2. Extend the java.rmi.server.RMISocketFactory class to handle SSL socket
    connections. Be sure to specify the port on which WebLogic Server listens for
    SSL connections. For an example of a class that extends the
    java.rmi.server.RMISocketFactory class, see Listing 4-22.
    3. Run the ejbc compiler with the -d option.
    4. Add your extension of the java.rmi.server.RMISocketFactory class to the
    CLASSPATH of the Java client.
    5. Use the following command options when starting the Java client:
    -xbootclasspath/a:%CLASSPATH%
    -Dorg.omg.CORBA.ORBSocketFactoryClass=implementation of java.rmi.server.RMISocketFactory
    -Dssl.certs=directory location of digital certificate for Java client
    -Dssl.key=directory location of private key for Java client"
    At step 3. I found into documentation that -d is linked to a directory name.
    When I run ejbc with this option -d I have the message:
    "ERROR: You must specify an output directory or jar with the -d option to weblogic.ejbc."
    % So what option can I use to run ejbc for secure usage?
    At step 5. Whatever I write for -Dorg.omg.CORBA.ORBSocketFactoryClass,
    this pointed class is not instanciated.
    Then I can not create a socket with my client.
    The folowing exception is raised:
    javax.naming.CommunicationException [Root exception is java.net.ConnectException:
    No server found at T3S://localhost:7002]
    So, my questions are:
    % Why -Dorg.omg.CORBA.ORBSocketFactoryClass must be known by the client and not
    the server?
    My java client part, managing connection is:
    -------------------BEGIN OF CONNECTION MANAGER-------------------
    Properties env = new Properties ();
    // Shouldn't have to do this, but for now you must
    if ( factory.equals ("weblogic.jndi.WLInitialContextFactory") ) {
    env.put ("java.naming.provider.url", "t3s://localhost:7002");
    } else {
    env.put ("java.naming.provider.url", "rmi://localhost:7002");
    InitialContext context = new InitialContext (env);
    BankSessionServerHome bssh = (BankServerHome) context.lookup("BankServerHome");
    BankServer = bssh.create();
    -------------------END OF CONNECTION MANAGER-------------------
    % What is the code for the java client allowing connection with the ejb?
    % And better, can I have a sample example for rmi-iiop over ssl?
    (...wlserver6.1\samples\examples\iiop\ejb\stateless\rmiclient\client.java do not
    speak ssl!)
    Any help will be appreciate from you...
    Best Regards.
    Oliver

  • Classcastexception with rmi-iiop

    Hi,
    I try the rmi-iiop example in examples/rmi_iiop/hello using Sun's JDK 1.3rc1 on Linux. I use weblogic.rmic to generate an IDL file from HelloImpl.class. Next, I use idlj (comes with the JDK) to generate those help .java files from IDL. Then, I compile these files and HelloClient.java. I start Weblogic(SP6) and launch HelloClient using the command,
    java examples.rmi_iiop.hello.HelloClient {long IOR number string}
    Weblogic server throws this exception when the client make a contact,
    Sun Dec 17 16:52:33 GMT+08:00 2000:<I> <WebLogicServer> WebLogic Server started
    Sun Dec 17 16:52:40 GMT+08:00 2000:<I> <ListenThread> Adding address: localhost/127.0.0.1 to licensed client list
    Sun Dec 17 16:52:40 GMT+08:00 2000:<E> <Adapter> Exception thrown by rmi server: [-8596339638698095515S127.0.0.1:[7001,7001,7002,7002,7001,-1]/8]
    java.lang.ClassCastException: examples.rmi_iiop.hello.HelloImpl
         at weblogic.cos.naming.NamingContextImpl.resolve(NamingContextImpl.java:138)
         at weblogic.cos.naming.NamingContext_WLSkel.invoke(NamingContext_WLSkel.java:53)
         at weblogic.rmi.extensions.BasicServerObjectAdapter.invoke(BasicServerObjectAdapter.java:347)
         at weblogic.rmi.extensions.BasicRequestHandler.handleRequest(BasicRequestHandler.java:69)
         at weblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest.java:15)
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:135)
    Why there is a ClassCastException? If there a compatiblity problem with idlj that comes with the JDK? Please advise.

    Generally, this is a classpath problem. You must ensure that the classes that are produced by jidl are not in the WLS classpath; similarly, the RMI interfaces must not be visible to the java CORBA client.
    IMO, a java CORBA client is not a viable development platform.
    TH Lim wrote:
    Hi,
    I try the rmi-iiop example in examples/rmi_iiop/hello using Sun's JDK 1.3rc1 on Linux. I use weblogic.rmic to generate an IDL file from HelloImpl.class. Next, I use idlj (comes with the JDK) to generate those help .java files from IDL. Then, I compile these files and HelloClient.java. I start Weblogic(SP6) and launch HelloClient using the command,
    java examples.rmi_iiop.hello.HelloClient {long IOR number string}
    Weblogic server throws this exception when the client make a contact,
    Sun Dec 17 16:52:33 GMT+08:00 2000:<I> <WebLogicServer> WebLogic Server started
    Sun Dec 17 16:52:40 GMT+08:00 2000:<I> <ListenThread> Adding address: localhost/127.0.0.1 to licensed client list
    Sun Dec 17 16:52:40 GMT+08:00 2000:<E> <Adapter> Exception thrown by rmi server: [-8596339638698095515S127.0.0.1:[7001,7001,7002,7002,7001,-1]/8]
    java.lang.ClassCastException: examples.rmi_iiop.hello.HelloImpl
    at weblogic.cos.naming.NamingContextImpl.resolve(NamingContextImpl.java:138)
    at weblogic.cos.naming.NamingContext_WLSkel.invoke(NamingContext_WLSkel.java:53)
    at weblogic.rmi.extensions.BasicServerObjectAdapter.invoke(BasicServerObjectAdapter.java:347)
    at weblogic.rmi.extensions.BasicRequestHandler.handleRequest(BasicRequestHandler.java:69)
    at weblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest.java:15)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:135)
    Why there is a ClassCastException? If there a compatiblity problem with idlj that comes with the JDK? Please advise.

  • Distributed transactions across RMI-IIOP client to RMI-IIOP server do not work

    Hi,
              Based on the links below:
              http://e-docs.bea.com/wls/docs61/jta/trxrmi.html#1018506
              http://e-docs.bea.com/wls/docs61/jta/gstrx.html#1067532
              It appears that is possible to have distributed transactions across RMI-IIOP
              clients and RMI-IIOP applications (servers).
              I followed up the "Transactions Sample RMI Code" section but it appears that
              the transaction context is not propagated from client to server. I am also
              surprised by the note:
              Note: These code fragments do not derive from any of the sample applications
              that ship with WebLogic Server. They merely illustrate the use of the
              UserTransaction object within an RMI application.
              The above note suggests that there is no sample code available.
              Is there anyone who successfully had RMI-IIOP applications (servers)
              participating in distributed transactions?
              Is there any sample code that illustrates RMI-IIOP applications (servers)
              participating in distributed transactions?
              If anyone thinks that this should work I will post my code that does not
              work.
              Regards,
              Dan Cimpoesu
              

    But if you look to the diagram:
    http://e-docs.bea.com/wls/docs61/jta/gstrx.html#1040200
    it suggests that transactional context is passed from clients to RMI-IIOP
    servers.
    Am I wrong?
    Dan
    "Andy Piper" <[email protected]> wrote in message
    news:[email protected]..
    "Dan Cimpoesu" <[email protected]> writes:
    Transactions over IIOP are not supported or implemented in WLS 6.1 or
    previous. This is a feature of WLS 7.0. In 7.0 we implement OTS.
    andy
    Hi,
    Based on the links below:
    http://e-docs.bea.com/wls/docs61/jta/trxrmi.html#1018506
    http://e-docs.bea.com/wls/docs61/jta/gstrx.html#1067532
    It appears that is possible to have distributed transactions across
    RMI-IIOP
    clients and RMI-IIOP applications (servers).
    I followed up the "Transactions Sample RMI Code" section but it appearsthat
    the transaction context is not propagated from client to server. I amalso
    surprised by the note:
    Note: These code fragments do not derive from any of the sampleapplications
    that ship with WebLogic Server. They merely illustrate the use of the
    UserTransaction object within an RMI application.
    The above note suggests that there is no sample code available.
    Is there anyone who successfully had RMI-IIOP applications (servers)
    participating in distributed transactions?
    Is there any sample code that illustrates RMI-IIOP applications(servers)
    participating in distributed transactions?
    If anyone thinks that this should work I will post my code that does not
    work.
    Regards,
    Dan Cimpoesu

Maybe you are looking for

  • Recent Windows 7 update causing monitor sleep problems/W​indows loop in some HP desktops?

    After perusing this forum, I wonder if there was a recent Windows 7 update that has been causing problems for some HP desktops and displays. My office has a 3500 Microtower desktop running Windows 7 Pro. While Windows 7 Pro is running and in use (as

  • Client_host cmd problem

    Hello. I want to open excel file on client. File is on another computer. I open the file with clien_host and cmd. The problem is, that cmd window stays opened. I open file like: CLIENT_HOST('cmd /c ' || LC$Target); LC$Target is like //Linux_comp/dir/

  • Sync via network?

    I've had the "The required disc cannot be found" error and other associated errors since I got this iPod, and I have tried absolutely EVERYTHING I can find on the Apple site and other various forums to overcome it. Nothing works, nothing at all.. I c

  • Excise Invoices are shown as Reversed - J1IP

    Dear Friends, Tcode: J1IP -The status of few Excise Invoices are shown as Reversed, but when checked the table display J_1IEXCHDR against CEIV ETT, these excise invoices are not listed and also checked the document flow which shows these excise invoi

  • How to reduce size of time machine partition?

    I have a hard drive which is rapidly filling up with TM backups going back 3 years.  I would like to reduce the allowable size of the partition without losing the latest backup.  How do I do that. Thanks Henry