3 Replies Latest reply on Feb 19, 2003 9:22 AM by Zoltan Imreh

    OIL and Firewall

    Zoltan Imreh Newbie

      Hi

      I'm using jboss 3.0.0 behind a firewall. I have made the following setting:

      - set free the 1099,1098,4444,8888 ports
      (8888 is the which I set for OIL to use)
      - set java.rmi.server.homename = my external address

      Everything goes fine till I'm not working with the OIL. I've checked the inkoming addresses and when I'm using the 1099, 1098, 4444, I'm getting the right external address, which was set, by java.rmi.server.hostname. When I want to connect to the JbossMQ I'm getting the localaddress. Can somebody tell me what I'm doing wrong?

      Regards,

      Zoli

        • 1. Re: OIL and Firewall
          Adrian Brock Master

          OIL won't work through a firewall, it opens a socket
          on the client for use by the server.
          You should use UIL.

          Neither uses RMI, so you will need to set the
          attribute "BindAddress" along with the port
          in jbossmq-service.xml

          It sounds like your /etc/hosts has your host name
          mapped to 127.0.0.1?

          Regards,
          Adrian

          • 2. Re: OIL and Firewall
            Zoltan Imreh Newbie

            Hi,

            I've tryd to use the UIL with the following properties

            1. BindAddress local ip address
            2. Port 8091

            , and I've made the following changes in the host file:

            I have commented the line 127.0.0.1 localhost
            A new line with my internal IP "external domainname"

            But the in the client I'm still getting the local IP address instead of the firewall's address. What am I doing wrong?

            Regards,
            Zoli

            • 3. Re: OIL and Firewall
              Zoltan Imreh Newbie

              Hi there,

              finally I've figured out, how can jboss messaging be used through a firewall. Here is the complete recepy:

              1. In hosts you have to map your internal IP-Address in your external domain name
              2. You should use UIL for messaging
              3. Set up UIL with BindAdress = your external domain name
              and ServerBindPort = arbitary port that is free in the firewall
              4. You must decompile the class org.jboss.mq.il.uil.UILServerIL.class and rewrite the createConnection() method as follows:
              4.a. from the InetAdress variable wich initializes the socket that is created. Make another InetAdress with the hostname from the original InetAdress then initialize the socket with the second InetAddress. Compile the class and copy back to its place.
              4.b. There are actually two classes one of them in the client/jbossmq-client.jar and one server/your_configuration/lib/jbossmq.jar

              Both have to be replaced!!!

              You can also download my attached version of this class.

              Regards,
              Zoli