All of lore.kernel.org
 help / color / mirror / Atom feed
From: John Sasso <jsassojr@nycap.rr.com>
To: netfilter@lists.netfilter.org
Subject: Problem w/ iptables on FC3
Date: Mon, 04 Jul 2005 10:25:14 -0400	[thread overview]
Message-ID: <1120487114.7207.10.camel@localhost.localdomain> (raw)

I am desperately trying to get the version of iptables that comes
default on Fedora Core 3 to work, even with a simple configuration.  The
version of iptables is 1.2.11.

The simple script is shown below, followed by the 'iptables -L' output
and interface configuration.  My system is single-homed, and starting
off simple I am trying to allow outgoing pings.  After running the
script, when I try to ping anything I get:

ping: sendmsg: Operation not permitted

What is going on here?  I've followed closely the guidelines given in
several books on iptables and a variety of online docs, but to no avail.
Is this a bug?

--john

--------------------------------------------
# Initialize all the chains by removing all the rules tied to them
iptables --flush
iptables -t nat --flush
iptables -t mangle --flush

# Now that the chains have been initialized, remove the user-defined
# chains.  We will recreate them afterwards
iptables --delete-chain
iptables -t nat --delete-chain
iptables -t mangle --delete-chain

# If a packet does not match any of the built-in chains, then the policy
# should be to drop it.
# If the firewall has only one interface, the FORWARD policy is not
necessary.
# However, defining a FORWARD policy is a precaution for future use.
iptables --policy INPUT    DROP
iptables --policy OUTPUT   DROP
iptables --policy FORWARD  DROP

iptables -A INPUT  -i lo -j ACCEPT
iptables -A OUTPUT -o lo -j ACCEPT

iptables -A OUTPUT -o eth0 -s 192.168.50.100 -p icmp --icmp-type echo-
request -j ACCEPT
iptables -A INPUT -i eth0 -d 192.168.50.100 -p icmp --icmp-type echo-
reply -j ACCEPT
--------------------------------------------


--------------------------------------------
# iptables -L
Chain INPUT (policy DROP)
target     prot opt source               destination
ACCEPT     all  --  anywhere             anywhere
ACCEPT     icmp --  anywhere             192.168.50.100      icmp echo-
reply

Chain FORWARD (policy DROP)
target     prot opt source               destination

Chain OUTPUT (policy DROP)
target     prot opt source               destination
ACCEPT     all  --  anywhere             anywhere
ACCEPT     icmp --  192.168.50.100       anywhere            icmp echo-
request
--------------------------------------------


# ifconfig -a
eth0      Link encap:Ethernet  HWaddr 00:20:78:07:BE:45
          inet addr:192.168.50.100  Bcast:192.168.50.255
Mask:255.255.255.0
          inet6 addr: fe80::220:78ff:fe07:be45/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:160 errors:0 dropped:0 overruns:0 frame:0
          TX packets:144 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:25140 (24.5 KiB)  TX bytes:14039 (13.7 KiB)
          Interrupt:11 Base address:0x2000




             reply	other threads:[~2005-07-04 14:25 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-04 14:25 John Sasso [this message]
2005-07-04 14:49 ` Problem w/ iptables on FC3 /dev/rob0
2005-07-04 18:36   ` John Sasso Jr
2005-07-04 19:32     ` /dev/rob0

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1120487114.7207.10.camel@localhost.localdomain \
    --to=jsassojr@nycap.rr.com \
    --cc=netfilter@lists.netfilter.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.