Skip to main content
Notice removed Draw attention by johnramsden
Bounty Ended with Chris Davies's answer chosen by johnramsden
Add more information about what is being attempted
Source Link
johnramsden
  • 572
  • 5
  • 15

I'm trying to block only outbound connections to specific IP addresses, however I want to allow inbound connections from the same IP addresses.

From what I understand about blocking outbound connections, they shouldn't block if an inbound connection has been made successfully.

I basically set up rules like this:

--append OUTPUT --jump DROP --destination x.x.x.x

And to allow established connections:

--append INPUT --in-interface eth0 --match state --state RELATED,ESTABLISHED --jump ACCEPT

I want connections to be allowed when this IP address attempts to connect to the server, but when my server tries to make an outbound connection, it shouldn't be able to make it.

I would like to block complete access for the server to make outbound connections to x.x.x.x. However when a user from that IP wishes to access the server they should be able to visit sites on certain ports.

I'm trying to block only outbound connections to specific IP addresses, however I want to allow inbound connections from the same IP addresses.

From what I understand about blocking outbound connections, they shouldn't block if an inbound connection has been made successfully.

I basically set up rules like this:

--append OUTPUT --jump DROP --destination x.x.x.x

And to allow established connections:

--append INPUT --in-interface eth0 --match state --state RELATED,ESTABLISHED --jump ACCEPT

I want connections to be allowed when this IP address attempts to connect to the server, but when my server tries to make an outbound connection, it shouldn't be able to make it.

I'm trying to block only outbound connections to specific IP addresses, however I want to allow inbound connections from the same IP addresses.

From what I understand about blocking outbound connections, they shouldn't block if an inbound connection has been made successfully.

I basically set up rules like this:

--append OUTPUT --jump DROP --destination x.x.x.x

And to allow established connections:

--append INPUT --in-interface eth0 --match state --state RELATED,ESTABLISHED --jump ACCEPT

I want connections to be allowed when this IP address attempts to connect to the server, but when my server tries to make an outbound connection, it shouldn't be able to make it.

I would like to block complete access for the server to make outbound connections to x.x.x.x. However when a user from that IP wishes to access the server they should be able to visit sites on certain ports.

Notice added Draw attention by johnramsden
Bounty Started worth 50 reputation by johnramsden
Make note about established connections
Source Link
johnramsden
  • 572
  • 5
  • 15

I'm trying to block only outbound connections to specific IP addresses, however I want to allow inbound connections from the same IP addresses.

From what I understand about blocking outbound connections, they shouldn't block if an inbound connection has been made successfully.

I basically set up rules like this:

--append OUTPUT --jump DROP --destination x.x.x.x

And to allow established connections:

--append INPUT --in-interface eth0 --match state --state RELATED,ESTABLISHED --jump ACCEPT

I want connections to be allowed when this IP address attempts to connect to the server, but when my server tries to make an outbound connection, it shouldn't be able to make it.

I'm trying to block only outbound connections to specific IP addresses, however I want to allow inbound connections from the same IP addresses.

From what I understand about blocking outbound connections, they shouldn't block if an inbound connection has been made successfully.

I basically set up rules like this:

--append OUTPUT --jump DROP --destination x.x.x.x

I want connections to be allowed when this IP address attempts to connect to the server, but when my server tries to make an outbound connection, it shouldn't be able to make it.

I'm trying to block only outbound connections to specific IP addresses, however I want to allow inbound connections from the same IP addresses.

From what I understand about blocking outbound connections, they shouldn't block if an inbound connection has been made successfully.

I basically set up rules like this:

--append OUTPUT --jump DROP --destination x.x.x.x

And to allow established connections:

--append INPUT --in-interface eth0 --match state --state RELATED,ESTABLISHED --jump ACCEPT

I want connections to be allowed when this IP address attempts to connect to the server, but when my server tries to make an outbound connection, it shouldn't be able to make it.

Source Link
johnramsden
  • 572
  • 5
  • 15

Iptables outbound block denies inbound

I'm trying to block only outbound connections to specific IP addresses, however I want to allow inbound connections from the same IP addresses.

From what I understand about blocking outbound connections, they shouldn't block if an inbound connection has been made successfully.

I basically set up rules like this:

--append OUTPUT --jump DROP --destination x.x.x.x

I want connections to be allowed when this IP address attempts to connect to the server, but when my server tries to make an outbound connection, it shouldn't be able to make it.