LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 01-30-2002, 04:52 PM   #1
ForumKid
Member
 
Registered: Dec 2001
Posts: 195

Rep: Reputation: 30
iptables question on INPUT DROP


If i start out as:
$IPT -P INPUT DROP
$IPT -A INPUT -s 0/0 -p tcp -d 192.168.2.2 --dport 80 -j ACCEPT

This will only accept port 80 stuff. everything else gets dropped including icmp/etc.
Is this a true statement?

Thanks
 
Old 01-31-2002, 09:36 AM   #2
raz
Member
 
Registered: Apr 2001
Location: London
Posts: 408

Rep: Reputation: 31
Re: iptables question on INPUT DROP

Quote:
Originally posted by ForumKid
If i start out as:
$IPT -P INPUT DROP
$IPT -A INPUT -s 0/0 -p tcp -d 192.168.2.2 --dport 80 -j ACCEPT

This will only accept port 80 stuff. everything else gets dropped including icmp/etc.
Is this a true statement?

Thanks
No the correct statement would be.
This will only accept incoming destination port 80 connections, to internal the ip address from any source with any source port, and only TCP type 6 protocol.

/Raz
 
Old 01-31-2002, 11:29 AM   #3
ForumKid
Member
 
Registered: Dec 2001
Posts: 195

Original Poster
Rep: Reputation: 30
Thanks...but would this make it more secure????
$IPT -A INPUT -s 0/0 --sport 80 -p tcp -d 192.168.2.2 --dport 80 -j ACCEPT

SHouldnt all connections coming to my webserver on port 80 be coming from port 80?
Thanks again
 
Old 02-12-2002, 09:21 AM   #4
raz
Member
 
Registered: Apr 2001
Location: London
Posts: 408

Rep: Reputation: 31
No..
Client connect to a privileged port. 1-1024 "i.e httpd 80"
Client connects from a unprivileged port. 1024-65535

Sorry I would have replied quicker but my harddisk caught fire.
/Raz
 
  


Reply



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
Iptables question? What is this? :RH-Firewall-1-INPUT - [0:0] abcampa Linux - Security 3 05-09-2005 12:44 PM
Newbie iptables INPUT question new@linux Linux - Security 6 03-08-2005 10:42 AM
iptables - drop all -> allow needed OR allow all -> drop specific lucastic Linux - Security 5 12-21-2004 02:07 AM
iptables -P INPUT DROP question yvesg Linux - Networking 2 06-21-2004 05:18 PM
iptables DROP command mm_jth Linux - Security 5 11-07-2003 11:22 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 06:29 PM.

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
Open Source Consulting | Domain Registration