LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 10-26-2009, 02:25 AM   #1
vinaytp
Member
 
Registered: Apr 2009
Location: Bengaluru, India
Distribution: RHEL 5.4, 6.0, Ubuntu 10.04
Posts: 704

Rep: Reputation: 55
iptable rule


Hi all..

Can anyone please tell me in the below rule
Code:
-A INPUT -m state --state NEW -m tcp -p tcp --dport 22 -j ACCEPT
-m state --state NEW -m tcp

part stands for ?? confused....I understood remaining stuff

Thanks in advance....
 
Old 10-26-2009, 02:39 AM   #2
btmiller
Senior Member
 
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,275

Rep: Reputation: 370Reputation: 370Reputation: 370Reputation: 370
Check the iptables man page. Essentially -m state tells iptables to use the state matching module (likewise -m tcp tells it to use the TCP module). The --state NEW is an argument to the state matching module, which tells it to match NEW packets (i.e. SYN packets which are not part of an established connection -- I think this will only match SYN packets and not SYN/ACK packets). Essentially, this rule tells iptables to allow incoming new connections to port 22.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
what is an iptable? & how to seperate the network on the basis of iptable vinod.wagh Linux - Networking 1 09-11-2008 02:28 AM
Same Iptable rule to be avoided? Santoshkb Linux - Networking 2 12-21-2007 06:55 AM
complex iptable rule help farhan Linux - Security 2 08-31-2005 10:58 PM
iptable rule for rmi bijuhpd Linux - Newbie 2 04-27-2005 01:42 AM
Help me write iptable rule to LOG gpagedar Linux - Security 1 10-01-2003 07:47 AM


All times are GMT -5. The time now is 08:54 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration