Public requests sent to Private IP

I have a few linodes which have both public and private IPs. I can access linode A from linode B using its private IP and visa-versa.

I have a webserver listening to the private IP, yet I can still access it from the public IP:

"curl http://public-ip/" from my local machine works as does "curl http://private-ip/" from a different linode.

My linodes are all running Ubuntu 10.04 and I followed the steps as outlined in http://library.linode.com/networking/co … nterfaces/">http://library.linode.com/networking/configuring-static-ip-interfaces/ in order to setup my private IPs.

What do I need to do so that a service listening on a private IP is not accessible through the linode's public IP?

Thanks

2 Replies

Are you sure you've configured the server to only listen on the private IP?

netstat -l would be a good place to start to double check that.

~JW

Doh. Yeah, I guess my server was telling me it was binding to my private IP, but is in-fact binding to 0.0.0.0 anyway.

For future reference: This problem arose with Rails 2.3.2/WEBrick 1.3.1 I started the server by running:

$ruby script/server --port=10000 --binding=192.168.XXX.XXX
=> Booting WEBrick
=> Rails 2.3.2 application starting on http://192.168.XXX.XXX:10000

Thanks

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct