Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > RMI client behind a firewall, server behind a firewall too

Reply
Thread Tools

RMI client behind a firewall, server behind a firewall too

 
 
Robert Dodier
Guest
Posts: n/a
 
      09-13-2004
Hello,

Browsing the web & newsgroups, it looks like this problem doesn't
have any kind of easy solution, but let's see if someone knows different.

I want to have a RMI client behind a firewall and a RMI server
behind another firewall. I don't have any control over the firewalls.
I know port 80 will be open for http traffic, but that's it.
The web server on either side isn't the same as the machine running
the RMI client or server.

I want the client to be able to call methods on server objects
and also to enable callbacks from the server to the client.

What can be done in this case? I've read the RMI docs at Sun,
browsed through a few dozen webpages & news messages, and the
situation looks pretty dark, actually. Maybe someone has cause
for optimism here. Thanks for any information.

Robert Dodier
 
Reply With Quote
 
 
 
 
Alexander Ames
Guest
Posts: n/a
 
      09-13-2004
On 13 Sep 2004 12:50:21 -0700, http://www.velocityreviews.com/forums/(E-Mail Removed) (Robert Dodier)
wrote:

>Hello,
>
>Browsing the web & newsgroups, it looks like this problem doesn't
>have any kind of easy solution, but let's see if someone knows different.
>
>I want to have a RMI client behind a firewall and a RMI server
>behind another firewall. I don't have any control over the firewalls.
>I know port 80 will be open for http traffic, but that's it.
>The web server on either side isn't the same as the machine running
>the RMI client or server.
>
>I want the client to be able to call methods on server objects
>and also to enable callbacks from the server to the client.
>
>What can be done in this case? I've read the RMI docs at Sun,
>browsed through a few dozen webpages & news messages, and the
>situation looks pretty dark, actually. Maybe someone has cause
>for optimism here. Thanks for any information.
>
>Robert Dodier


I believe it can be done through HTTP tunnelling. Do a web search on
that. You need a servlet to forward the requests. (Can you run
servlets in your web server?) I think Sun provides one but you might
need to change it if the RMI server is on a different machine from the
web server.

 
Reply With Quote
 
 
 
 
Matthias Kraft
Guest
Posts: n/a
 
      09-14-2004
You can define sockets for the stub and the skeleton (Class
RMISocketFactory).
---schnipp---
public class HelloImpl implements Hello{
public HelloImpl() throws RemoteException{
UnicastRemoteObject.export(this, 80, new MyClientFactory(), new
MyServerFactory());
}
---schnapp---
If you need a complete example, write me.
RMI is written for use in an Intranet. A better way is to use Webservices
to solve your problem (e.g. AXIS).

Andres

On 13 Sep 2004 12:50:21 -0700, Robert Dodier <(E-Mail Removed)>
wrote:

> Hello,
>
> Browsing the web & newsgroups, it looks like this problem doesn't
> have any kind of easy solution, but let's see if someone knows different.
>
> I want to have a RMI client behind a firewall and a RMI server
> behind another firewall. I don't have any control over the firewalls.
> I know port 80 will be open for http traffic, but that's it.
> The web server on either side isn't the same as the machine running
> the RMI client or server.
>
> I want the client to be able to call methods on server objects
> and also to enable callbacks from the server to the client.
>
> What can be done in this case? I've read the RMI docs at Sun,
> browsed through a few dozen webpages & news messages, and the
> situation looks pretty dark, actually. Maybe someone has cause
> for optimism here. Thanks for any information.
>
> Robert Dodier




--
Using Opera's revolutionary e-mail client: http://www.opera.com/m2/
 
Reply With Quote
 
Sudsy
Guest
Posts: n/a
 
      09-14-2004
Matthias Kraft wrote:
> You can define sockets for the stub and the skeleton (Class
> RMISocketFactory).
> ---schnipp---
> public class HelloImpl implements Hello{
> public HelloImpl() throws RemoteException{
> UnicastRemoteObject.export(this, 80, new MyClientFactory(), new
> MyServerFactory());
> }
> ---schnapp---
> If you need a complete example, write me.
> RMI is written for use in an Intranet. A better way is to use
> Webservices to solve your problem (e.g. AXIS).


To the OP: You've had two good replies here. I must admit that I was
thinking Web Services simply because of portability issues. But the
proxy approach is mature and enjoys wide support.
IOW, you'd be well served by either solution.
Good luck!

 
Reply With Quote
 
Alex Molochnikov
Guest
Posts: n/a
 
      09-14-2004
If you have no control over the firewalls at all, then there is no solution.
However, if you can negotiate opening of a few ports with the admin, then
the solution does exist. If the latter is the case, let me know and I will
walk you through the setup.

Alex Molochnikov
Gestalt Corporation
www.gestalt.com

"Robert Dodier" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed) om...
> Hello,
>
> Browsing the web & newsgroups, it looks like this problem doesn't
> have any kind of easy solution, but let's see if someone knows different.
>
> I want to have a RMI client behind a firewall and a RMI server
> behind another firewall. I don't have any control over the firewalls.
> I know port 80 will be open for http traffic, but that's it.
> The web server on either side isn't the same as the machine running
> the RMI client or server.
>
> I want the client to be able to call methods on server objects
> and also to enable callbacks from the server to the client.
>
> What can be done in this case? I've read the RMI docs at Sun,
> browsed through a few dozen webpages & news messages, and the
> situation looks pretty dark, actually. Maybe someone has cause
> for optimism here. Thanks for any information.
>
> Robert Dodier



 
Reply With Quote
 
heidi
Guest
Posts: n/a
 
      09-14-2004
"Alexander Ames" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> I believe it can be done through HTTP tunnelling.


The OP wanted to do callbacks to the client. The HTTP tunnelling will not
allow that.


 
Reply With Quote
 
Matthias Kraft
Guest
Posts: n/a
 
      09-14-2004
On Tue, 14 Sep 2004 00:10:04 -0400, Sudsy <(E-Mail Removed)> wrote:

> Matthias Kraft wrote:
>> You can define sockets for the stub and the skeleton (Class
>> RMISocketFactory).
>> ---schnipp---
>> public class HelloImpl implements Hello{
>> public HelloImpl() throws RemoteException{
>> UnicastRemoteObject.export(this, 80, new MyClientFactory(),
>> new MyServerFactory());
>> }
>> ---schnapp---
>> If you need a complete example, write me.
>> RMI is written for use in an Intranet. A better way is to use
>> Webservices to solve your problem (e.g. AXIS).

>
> To the OP: You've had two good replies here. I must admit that I was
> thinking Web Services simply because of portability issues. But the
> proxy approach is mature and enjoys wide support.
> IOW, you'd be well served by either solution.
> Good luck!
>


Thanks. I will try to keep this quality and improve my english.



--
Using Opera's revolutionary e-mail client: http://www.opera.com/m2/
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: VPN Client to PIX1 from home OK - VPN Client to PIX1 Fails from behind PIX2 firewall D K Cisco 4 12-04-2006 02:00 PM
RMI app behind NAT firewall tobias.weih Java 1 01-30-2006 11:50 AM
RMI Vs RMI over IIOP JScoobyCed Java 1 01-28-2005 09:54 AM
RMI, JINI or RMI/IIOP Buu Nguyen Java 1 08-25-2004 11:28 AM
RMI Callback; reusing established client to server connection (workaround firewall / NAT) Jo Voordeckers Java 2 09-15-2003 08:21 AM



Advertisments