Linux Netfilter discussions
 help / color / mirror / Atom feed
From: "Bo Jacobsen" <subs@systemhouse.dk>
To: netfilter@lists.netfilter.org
Subject: Re: Problem seperating FTP & ms-streaming traffic
Date: Mon, 15 Mar 2004 01:57:20 +0100	[thread overview]
Message-ID: <004801c40a28$7a8a2560$de0aa8c0@comp> (raw)
In-Reply-To: 200403142221.55622.Antony@Soft-Solutions.co.uk

> > I have a problem allowing forwarding of passive internal ftp traffic and,
> > at the same time disallowing ms-streaming (port 1755).
> >
> > Whenever I allow the passive ftp, it also allows ms-streaming going
> > through.
> >
> > My rules are:
> >
> > iptables -A FORWARD -m state --state NEW,ESTABLISHED -s local_lan --sport
> > highports --dport ftp -j ACCEPT
> > iptables -A FORWARD -m state --state ESTABLISHED,RELATED -s local_lan
> > --sport highports --dport highports -j ACCEPT
> 
> Those cannot be all of your rules.
> 
> Show us the rest of the rules and we might be able to suggest something.
> 
> Antony.
> 

You are right, of course, there are a lot more rules, but those are the ones 
that opens up ms-streaming traffic. Well, the complete set of rules I use 
for passive ftp is actually:

# Accept port 21 out
iptables -A FORWARD -p tcp -m state --state NEW,ESTABLISHED -s local_lan 
--sport highports -d all_hosts --dport ftp -j ACCEPT -i eth1    # eth1 = Internal nic

#Accept reply on port 21 in
iptables -A FORWARD -p tcp -m state --state ESTABLISHED -d local_lan 
--dport highports -s all_hosts --sport ftp -j ACCEPT -i eth0    # eth0 = External nic


# Accept high-port to high-port out
iptables -A FORWARD -p tcp -m state --state ESTABLISHED,RELATED -s local_lan
--sport highports -d all_hosts --dport highports -j ACCEPT -i eth1

# Accept high-port to high-port reply in
iptables -A FORWARD -p tcp -m state --state ESTABLISHED -d local_lan
--dport highports -s all_hosts --sport highports -j ACCEPT -i eth0


When I uncomment these four iptables commands, ms-streaming passes 
through. When commented out, it does not.

I have looked at the iptables -L output, and there is no other rules that has both
source-ports and dest-ports set to highports (1024:65535).


Bo



  reply	other threads:[~2004-03-15  0:57 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-03-14 21:49 Problem seperating FTP & ms-streaming traffic Bo Jacobsen
2004-03-14 22:21 ` Antony Stone
2004-03-15  0:57   ` Bo Jacobsen [this message]
2004-03-15  1:05     ` forum
2004-03-15  7:26     ` Antony Stone

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='004801c40a28$7a8a2560$de0aa8c0@comp' \
    --to=subs@systemhouse.dk \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox