LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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 03-04-2002, 03:22 AM   #1
nutshell
Member
 
Registered: Feb 2002
Distribution: Slackware 8.1
Posts: 244

Rep: Reputation: 30
How to tell if you need firewall or not?


Hi,

How do you tell if you have been attacked or someone have attempted to attack my machine? LIke reading logs and similar things? How do you do that? Any software that has this function? I want to know if someone have attemoted to hack my machine. Becasuse i don't really want to install a firewall for no reason. Yes i know some of you will say that you wiill be hacked 9 times out of 10, but still, i want to know how do you know if you've been scanned or attacked or similar things.


thnx
 
Old 03-04-2002, 05:36 AM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
you shouldn't wait until you get attacked before you put up a firewall. generally it should be part of a general secure system.
 
Old 03-04-2002, 05:44 AM   #3
nutshell
Member
 
Registered: Feb 2002
Distribution: Slackware 8.1
Posts: 244

Original Poster
Rep: Reputation: 30
But how do u tell if you've been attacked or not?
 
Old 03-04-2002, 05:47 AM   #4
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
well, yeah check logs. unless you've put in place a general port logger, you won't be able to tell other than people attemplting to connect to specific services such a samba, or apache in which case it'd be in their logs, as you'd expect, like /var/log/samba/"hostname"
 
Old 03-07-2002, 04:51 PM   #5
BillRice
LQ Newbie
 
Registered: Jan 2002
Distribution: SuSE
Posts: 16

Rep: Reputation: 0
How to tell if you've been compromised...

Quote:
Originally posted by nutshell
But how do u tell if you've been attacked or not?
The security faq at comp.os.linux.security has some good info on this. Section 5 of that document covers intrusion detection.
 
Old 03-07-2002, 05:40 PM   #6
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 269Reputation: 269Reputation: 269
another good place for info is at http://www.linuxsecurity.com/

-trickykid
 
Old 03-07-2002, 10:34 PM   #7
JimKyle
Member
 
Registered: Dec 2001
Location: Oklahoma City, OK, USA
Distribution: Xubuntu 16.04 LTS
Posts: 214
Blog Entries: 1

Rep: Reputation: 39
Re: How to tell if you need firewall or not?

Quote:
Originally posted by nutshell
Hi,

How do you tell if you have been attacked or someone have attempted to attack my machine? ... i don't really want to install a firewall for no reason. Yes i know some of you will say that you wiill be hacked 9 times out of 10, but still, i want to know how do you know if you've been scanned or attacked or similar things.
You don't say what distribution you're running; use Google to search for "linux portsentry" and download the appropriate binary package for it. That will tell you all the port scans that come into your system. Many distributions already have the portsentry files on their CDs; it was there on my Mandrake 8.1 for example.

My rule of thumb is quite simple: if you connect to the Internet, you need a firewall. In order to use portsentry, I have to leave a couple of openings in my firewall so that the scanners can get through as far as portsentry, but it then locks them out so they don't get any further. After you run it for a month or so I think you'll agree on the need. I get about 3 hits a day, on average, and I'm locked down pretty tightly!
 
Old 03-08-2002, 01:32 AM   #8
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
Ppl better install Snort instead of Portsentry if they want IDS capabilities.

The reason is simple, and I've posted this before, Portsentry only will tell you someone tries to connect in some way to a port, while Snort will report that too and it can examine the packets for known malicious payload as well, so if there are known exploits used you'll see it in the logging/reports.

Portsentry has got it's own blocking capabilities by route, by adding the IP to the fw script, or by using some custom script. Snort relies on 3rd party apps to do blocking (compile --with-flexresp).

The real difference is Portsentry may be misguided by sending custom "offending" packets to known blocked ports, using spoofed IP addresses; it will block those addresses off. Snort will only initiate blocking action if the packets payload matches criteria for malicious content.

Just my 2 cents
 
Old 03-08-2002, 06:58 AM   #9
JimKyle
Member
 
Registered: Dec 2001
Location: Oklahoma City, OK, USA
Distribution: Xubuntu 16.04 LTS
Posts: 214
Blog Entries: 1

Rep: Reputation: 39
unSpawn has a good point; however I suspect that any intrustion detection system is better than none at all. I've also heard very good things about AIDE, but since it's based on the same strategy that portsentry uses it would be subject to the same objections...
 
Old 03-08-2002, 10:42 AM   #10
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
Snort you could call something like a host or network based intrusion detection system (IDS), you would use it to detect anomalies in network traffic by filtering it against signatures taken from know (malicious) code or plain text.

Aide is, like Samhain or Tripwire, a system integrity checker, you would use it to detect anomalies in the files on your disks, by "diffing" signatures from the database against the current checksum. Aide luckily enuff has nothing in common with Portsentry :-]

Hope this clears it up a bit.
 
  


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
BSD Firewall vs Linux Firewall ? rootlinux Linux - Security 5 08-29-2007 07:38 AM
Firewall lets ips which are not in the firewall ... why ? sys7em Linux - Networking 2 06-30-2005 12:50 PM
Firewall with features of a Sidewinder firewall? abcampa Linux - Security 4 04-22-2005 04:24 PM
slackware's /etc/rc.d/rc.firewall equivalent ||| firewall script startup win32sux Debian 1 03-06-2004 09:15 PM
Firewall Builder sample firewall policy file ? (.xml) nuwanguy Linux - Networking 0 09-13-2003 12:32 PM

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

All times are GMT -5. The time now is 08:40 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