* whois
@ 2002-09-27 1:37 Roger
2002-09-27 5:56 ` whois Rasmus Bøg Hansen
0 siblings, 1 reply; 2+ messages in thread
From: Roger @ 2002-09-27 1:37 UTC (permalink / raw)
To: netfilter
I'm having problems setting a rule to allow 'whois' queries.
With the following:
iptables -A OUTPUT -o eth+ -p tcp --dport 43 -m state --state
NEW,ESTABLISHED -j ACCEPT
iptables -A INPUT -i eth+ -p tcp --sport 43 -m state --state ESTABLISHED
-j ACCEPT
with any unmatching being logged, there is a log entry for inbound tcp to
port 43
I was under the impression that since I'm originating the request, then
the input should come through since it is an established connection. If I
modify the INPUT rule to allow NEW,ESTABLISHED then it works.
other services that I have set up in a similar fashion seem to work.
Any idea what's going on?
tia.
Roger
--
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: whois
2002-09-27 1:37 whois Roger
@ 2002-09-27 5:56 ` Rasmus Bøg Hansen
0 siblings, 0 replies; 2+ messages in thread
From: Rasmus Bøg Hansen @ 2002-09-27 5:56 UTC (permalink / raw)
To: Roger; +Cc: netfilter
On Thu, 26 Sep 2002, Roger wrote:
>
> I'm having problems setting a rule to allow 'whois' queries.
> With the following:
> iptables -A OUTPUT -o eth+ -p tcp --dport 43 -m state --state
> NEW,ESTABLISHED -j ACCEPT
>
> iptables -A INPUT -i eth+ -p tcp --sport 43 -m state --state ESTABLISHED
> -j ACCEPT
>
> with any unmatching being logged, there is a log entry for inbound tcp to
> port 43
Yes, because you do not allow incoming return packets with source port
43. I would do:
iptables -A OUTPUT -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A INPUT -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A OUTPUT -p tcp --dport 43 --syn -j ACCEPT
All of this assuming that you are running whois from the firewall itself
(else you would have to put the rules in FORWARD).
/Rasmus
--
-- [ Rasmus "Møffe" Bøg Hansen ] ---------------------------------------
To alcohol!
The cause of - and solution to - all of life's problems!
-- Homer Simpson
----------------------------------[ moffe at amagerkollegiet dot dk ] --
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2002-09-27 5:56 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-09-27 1:37 whois Roger
2002-09-27 5:56 ` whois Rasmus Bøg Hansen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox