LinuxQuestions.org
Help answer threads with 0 replies.
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 07-19-2006, 08:31 AM   #1
Ammad
Member
 
Registered: Apr 2004
Distribution: redhat 9.0, fc4, redhat as 4
Posts: 522

Rep: Reputation: 31
iptables and samba


Problem starts when i use default policy to block like below.

#iptables -P INPUT DROP
#iptables -A INPUT -i lo -j ACCEPT
#iptables -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
#iptables -A INPUT -p tcp --dport 137:139 -j ACCEPT
#iptables -A INPUT -p udp --dport 137:139 -j ACCEPT
#iptables -A INPUT -p tcp --dport 445 -j ACCEPT
#iptables -A INPUT -p udp --dport 445 -j ACCEPT

#iptables -P OUTPUT ACCEPT


but when i browse it from windows using \\a.b.c.d\share

unable to browse it, as i change default policy of input to accept, it works,
what can be problem.
 
Old 07-20-2006, 01:08 AM   #2
prozac
Member
 
Registered: Oct 2005
Location: Australia
Distribution: slackware 12.1
Posts: 753

Rep: Reputation: 32
maybe you should use the --source/-s or --destination/-d options too.
 
Old 07-20-2006, 05:26 AM   #3
Ammad
Member
 
Registered: Apr 2004
Distribution: redhat 9.0, fc4, redhat as 4
Posts: 522

Original Poster
Rep: Reputation: 31
this isn't required, , its optional
 
Old 07-25-2006, 01:48 AM   #4
win32sux
LQ Guru
 
Registered: Jul 2003
Location: Los Angeles
Distribution: Ubuntu
Posts: 9,870

Rep: Reputation: 380Reputation: 380Reputation: 380Reputation: 380
Quote:
Originally Posted by Ammad
as i change default policy of input to accept, it works,
what can be problem.
if that's the case, then all you need to do is add a LOG rule to the end of the chain and then monitor the logfile when you try to connect and it doesn't work...
Code:
iptables -A INPUT -j LOG --log-prefix "INPUT DROP: "
 
  


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 and Samba MrBiggZ Linux - Security 1 10-08-2005 02:20 PM
iptables and samba sohail_de Linux - Networking 1 08-20-2003 12:38 AM
using iptables to allow samba robertmarkbram Linux - Networking 3 08-17-2003 03:08 AM
iptables and Samba frkstein Linux - Networking 2 09-19-2002 09:00 PM
Samba and iptables Zvezda Linux - Networking 3 02-17-2002 11:22 PM

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

All times are GMT -5. The time now is 09:02 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
Open Source Consulting | Domain Registration