Re: Limiting RMI to localhost



On Mon, 30 Jun 2008 18:49:01 +0100, Tom Anderson wrote:
On Mon, 30 Jun 2008, Ronny Schuetz wrote:
Can't you setup to RMI server socket to explicitly listen on
localhost:<your port>? This way it shouldn't be accessible from outside.

A server socket bound to localhost will be able to receive
connections from outside.

A ServerSocket bound to a particular address can *only* accept
connections that arrive on the corresponding interface. If that
address is 127.0.0.1 then any remote connection attempts will result
in "connection refused". No firewall is necessary.

/gordon

--
.



Relevant Pages

  • Re: Always allow loopbacks ?
    ... snipped) or to the original question that started the thread (which you ... to use localhost while they would block any non-legitimate connections. ... specifying the port of the server). ...
    (comp.security.firewalls)
  • Re: C# Reflection - Nasty bug??
    ... still get the prompt although I cannot connect to the server with my client. ... > Can you telnet into localhost to the port your server is running and get ... >> "is it possible for you to indicate that all connections in your program ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Q: high-port tcp connections from localhost to localhost in HP-UX 11.31
    ... Rick Jones writes: ... localhost to localhost using high port numbers. ... connections are in state TIME_WAIT. ... I also found a server listening on UDP localhost port ...
    (comp.sys.hp.hpux)
  • Re: Tomcat connecting to MySQL - Ubuntu 8.10 Server
    ... attempts to telnet to localhost on port 3306. ... close the port immediately if you don't send a proper packet. ... case it did _open_ the port, so it's there and accepting connections. ...
    (Ubuntu)
  • Re: Limiting RMI to localhost
    ... A server socket bound to localhost will be able to receive connections from outside. ... >Unless you mean that <your port> would also be firewalled? ...
    (comp.lang.java.programmer)